Hi,
I'm trying to find a simple way to select between two input files in my workflow. The two files are identical except for time period. One is "current" and the other is "month-end previous month." I'd like to use the same workflow on each. Sometimes I want the outputs based on today, and sometimes based on last month. The file names and paths will be static. Ideally, I'd just like to have a menu to select between the two inputs. I'm sure this is possible, but I'm very new to Alteryx so I'd appreciate any suggestions.
Thanks.
Eric
Solved! Go to Solution.
There are a number of ways to achieve this, including User constants, Apps etc.
It sounds like your workflow would be well suited to an app that provides a dropdown to select the correct file for this run. I'll send an example when I get back to the office.
That sounds good! I look forward to seeing the example. thx
See attached for example. You can run this by hitting the wand symbol next to the run button. If you want to see the output from the browse you need to set the option in the Interface
Designer. This version is using the option to manually select the file names. There are many other approaches like File Browse, take input from Text etc. I hope it helps.
@eric-l What are the conditions in which you decide which file to use? If it's predictible then a directory input / dynamic input tool combination may work based on your usage. ie.
In the middle of a month run "current" unless the date is the beginning of the month, else run month-end previous month, etc.
I'm curious what your use cases are and if you really want to have a drop down every time you run the workflow, or if you want the workflow to choose for you based on the date.
Ok. I replicated your suggestion in my workflow, but when I click the wand and hit finish, it returns "there were no output files." I know you said, "If you want to see the output from the browse you need to set the option in the Interface," but I'm not certain what that means. Also, do I need to save my workflow as an app or can I use this procedure in a workflow file?
Under View menu Select Interface designer
In Interface Designer click the setting icon (wrench), select Browse tool
It's set up to run as an app or as a standard workflow. If you click the Run button it will run using the filename preset in the Input Tool. If you run as an App via the Wand icon it will ask the question
It now runs without error as an app, but nothing happens in the workflow. The tools all still use the default file from the Input tool. I think I might be too much of a novice, and I may have asked a question I can't understand the answer to. I haven't used / created apps. I'm still just running everything as a basic workflow. All I'm trying to do is make it easier to run the same workflow for two different identical files with different names/paths.
It's random - depends on whether the person asking for a report wants today's info or as of month (or year) end. I am the user who will choose.
I don't know why it's not working for you.
When I run as an app via the wand select Current and then Finish
I'll get a pop up with the results of the browse in the workflow against the chosen file - current
Similarly if I choose Previous
and press finish, i'll see results from that file
What do you see?