Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.
SOLVED

Keep headers while union

Ilkin
5 - Atom

Hello,
Simply what I need is to keep original headers of the data while using union tool.
Example:

I have:

Input1

carstrucksplanes
4736

Input 2

Shipboatsubmarines
6536

 

I need:

Output

carstrucksplanes
4736
Shipboatsubmarines
6536

 

 

Note: cars,trucks,planes,ship and ect are NOT DATA , but HEADERS

Thanks in advance!

5 REPLIES 5
mbarone
16 - Nebula
16 - Nebula

A union stacks data, not headers.  It's not intended to do what you're asking.  What you could do is in your input tools is check the box "First Row Contains Data".  It will push your headers down into a data row, and your headers will become F1, F2, etc.  You could then union them like that.

atcodedog05
22 - Nova
22 - Nova

Hi @Ilkin 

 

Extending on the @mbarone post. Here is an example

 

1. You need to set the above highlighted option First row contains data so that you get column names also as data.

 

atcodedog05_0-1621338735282.png

 

2. Since we are using First row contains data our column name will be F1,F2... which we do not want on our output. Hence select Skip filed names in output tool like below

 

atcodedog05_2-1621338865307.png

 

Output: (F1,F2 are not outputted)

atcodedog05_3-1621338939931.png

 

Hope this helps 🙂

Ilkin
5 - Atom

Thank you I know this method but the issue is that my data is not on the input stage I have modified it using lots of tools so between input tool and the union tool there are lots of analytics that unfortunately wil not work if I will use method u described. I need something else may be it's not union tool or may be there are other way to modify data before unioning it.

atcodedog05
22 - Nova
22 - Nova

Hi @Ilkin 

 

Since above approach doesnt work for you. There is another way.

 

Workflow:

atcodedog05_0-1621411970222.png

1. Convert them to report table using table tool.

2. Then union them and output it. This way the tables comes one above other without any other header.

 

Output:

atcodedog05_1-1621412247009.png

 

Note : you might have to configure the table tool to get the desired color formatting.

 

Hope this helps 🙂

 

DivRK
5 - Atom

Hi, checking if there is an alternate to table tool to get the output. i need to over write sheets so cant use the render tool.

I tried duplicating the headers, so the main headers gets dropped in the union but the duplicate headers passes through; however, since my 2nd input has extra columns, this does not work well.

Labels