Showing results for 
Search instead for 
Did you mean: 

Alteryx designer Discussions

Find answers, ask questions, and share expertise about Alteryx Designer.
Community v19.6

Looks aren't everything... But the latest Community refresh looks darn good!

Learn More

Joining databases


 I just signed up for alteryx and I have a couple questions on my first workflow.

I am joining 2 databeses and I need to add a column to identify each database.


Anybody have any ideas?



ACE Emeritus
ACE Emeritus

Hey Jonathan,

Use a formula tool immediately after each of your inputs from you DBs to add that column. I usually do this and create a column named SOURCE that way as I blend and create things, i know where it came from. In the formula tool, your expression would be literal: "Database Name 1" or whatever you want to name it.


Hope that helps!


Use a formula tool to create a new field after each input with a database name field. Have attached a simple demo of this with a Union and a Join tool.


If you are reading from flat files you can make the input tool add the filename as field.



ACE Emeritus
ACE Emeritus

You can also use the "Output File Name as Field" option in the Input Data tool -- that way you can get either the file name or the full path.


Have fun with the File function set in the Formula tool to parse the file name/path!


Good luck.