Hello!
I am trying to create an Analytic app that prompts the user to choose 4 files, and for each file, decide which of the fields will be the ID field.
Right now, I have the actions to select the data and select the field from the data, but how can I change the "ID" field to be whatever field is chosen?
Originally, I wanted to use the mapping functionality on the data input, but I couldn't figure out how to only map 1 column and just pull in the rest. I want the output of this specific file to have all of the columns and to either rename their specified ID field to be ID OR to have all of the columns and an extra ID column called ID with their specified column populated. Do you think this would have been a better way of doing it/if so, how would you go about it?
Could someone please assist?
Thanks so much in advance!
Solved! Go to Solution.
Hi @lailas you could use the action tool to update a filter with the ID so from that point forward the data would only by the ID chosen.
@JosephSerpis Thanks! But do you mind sending me a quick example? I don't follow. It seems like that's sort of what I am trying to do (except with a formula)
Hi @lailas I've attached a example.
I can't see it 😞 I have an older version of Alteryx. Do you know how I can open it up on an older version?
Hi @lailas this link will show you how to open the file. The file attached was a packed workflow when you clicked it on it would create a folder and download the app. That is what you need to open and change the version to match yours.
I also attached a macro version of my example and back versioned to 2018.1
Thanks! For some reason, it came all garbled when I tried opening with Notepad++ but I could see your macro perfectly!
However, I don't think that solved it unfortunately. To rephrase my use case a bit- I will be getting in a datasource with a bunch of columns
Datasource1
Column A\ Column B\ Column C
Company 1 \ 12345\ abc
I won't know the column headers beforehand, but I want to user to decide which will be considered the ID field.
I'd like my app interphase to look like this:
Choose Datasource: Datasource1
Choose ID Column: Column B
I'd like my output to then look like this:
ID \ Column A\ Column C
12345\ Company 1 \ abc
Does that make sense? Does your macro do that and I am just not understanding?
Thanks a million for your continued support and quick replying!
Hi @lailas I think I understand your problem you want to depending on the file parse the column headers into the dropdown. I don't think it will exactly as you want with using a static file as the workflow will need to run essentially first to push the column headers into the dropdown. You could do this two ways one use a chained app so bring in your file first output a file with the header names the second app would use that. Another option is to a command line to generate the file to be used in the dropdown. An alternative is you just a text input and get the user to specify the ID column.
Yes, makes sense! So if I did a text input for them to specify the ID column, how can I insert that into the name of the field? I think it would be with a formula tool, but I can't figure that out. Right now, I have a formula tool that has an update value, but it is updating it with text. I want to update it with the field name,
Hi @lailas I mocked up and example.