Free Trial

Alteryx Designer Desktop Discussions

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

Concatenate every three rows to create a column name

ebobo
5 - Atom

Hello dear community, I'm attempting to perform some data transformation. I have a lengthy table with multiple columns, and I want to concatenate every three rows to create a column name.

 

Here's an example:

 

 

3 REPLIES 3
DataNath
17 - Castor
17 - Castor

Hey @ebobo, when you say the table is lengthy, does that mean you'll have more rows i.e. 4, 5, 6 which will create yet another header as A456? Or do you just mean you have a lot of columns where the concatenation needs to happen?

ebobo
5 - Atom

I have a lot of columns where the concatenation needs to happen.

DataNath
17 - Castor
17 - Castor

Ok there's a couple ways to go about it but here's one:

1) Transpose to get the original header names into the data alongside the values

2) Make the [Value] field a string so we can concatenate

3) Concatenate the values

4) Combine the original header letter with this concat value

5) Re-Cross Tab to make this new field a header

6) Sample the top N (=0) rows so we're only left with headers

 

 
Labels
Top Solution Authors