Hello, I have a workflow that uses two, dynamic inputs for consuming two, different files where several of the column headers (fields) vary. The workflow is set up to where dynamic input #1 reads in the first file saved to a folder and input #2 reads in the second file. But for subsequent instances where these files are saved off, that order could change. Therefore, I'm trying to figure out the best way to dynamically change the field name so that the preferred header prevails. For example, one file may use the field name 'Rate' whereas the other uses 'Basis Pts'. Desired outcome is for the field to be labeled 'Rate' irrespective of which file it reads in. Somewhat of a junior user so prefer a solution that does not involve a macro. Any help is greatly appreciated - thanks!
Solved! Go to Solution.
Hi @Jake5,
You could create a lookup table like the one below with a text input tool. Then, after bringing in both data sets, you can use the dynamic rename tool on each data set. The right input on the tool will be your lookup table. In the configuration window for the dynamic rename tool, select the "Take Field Names from Right Input Rows" option so that the old headers will be replaced with the desired headers, and the desired headers will remain unchanged.
Hope this helps!
Old Header | New Header |
Basis Pts | Rate |
etc |
etc |
Hi @MeganBowers
Thanks for responding. I did give that a try but for some reason it's not yielding the expected results. I've attached an example. You'll notice after it runs, the original input field headers do not update as expected - i.e. Basis Pts should update to Rate (Bps), Avg Daily Balance to Billable Assets. Am I missing a step?
Hi @Jake5 ,
The thing you need to change is the configuration of the dynamic input tool. When you switch it to the configuration below, are you seeing your desired results?
Unfortunately - no. Referencing the workflow I previously attached, I updated the Field Name from Column to = Field1 and New Description from Column = Field2 and it's still not updating. I would expect Basis Pts to be replaced with Rate (Bps) and Avg Daily Balance to be replaced with Billable Assets. Please see below.
Sorry I didn't catch this--the rename mode should be set to "Take field names from right input rows" not "take field descriptions from right input rows"
Thank you! That worked :)