Hi all, does anyone know how to go about placing a specific column under another column? For example placing column D under column B while still keeping the first two columns consistent.
Before
Number | Name | A | B |
1 | John | 1 | 48 |
9 | Barb | 43 | 27 |
1000 | Willy | 60 | 42 |
1001 | Steve | 98 | 94 |
After
Number | Name | A |
1 | John | 1 |
2 | Barb | 43 |
3 | Willy | 60 |
4 | Steve | 98 |
Number | Name | B |
1 | John | 48 |
2 | Barb | 27 |
3 | Willy | 42 |
4 | Steve | 94 |
Thanks
Solved! Go to Solution.
Hi @danielsnook
Have a play with the transpose tool. I think you'll struggle with those repeating field names, but it might be what you need.
Cheers
Kat
Hi @danielsnook!
Try this setup and see if it works for you. In your Input Data tool, make sure to check the box in setting #6 for "First Row Contains Data" as the field names are treated as records to match your desired output.
I'll toss out another possibility, but it will depend on how many columns you have.
First, in your input tool, check the "first row contains data" box.
Use a select tool to pick only Number, Name and A, but change the name of A from F3 to Value
Copy and paste that select tool (connect to your input) and change your selection to Number, Name and B. Again, rename column "B" (F4 or whatever) to Value.
Continue until you have all your columns, then union all.
Now your data is arranged as you've described and you can rename your column headers any way you want.
It appears that your data is structured according to some pre-defined report, but just in case you ever want to use it in Tableau, for instance, there's a better way. I'll whip up an example for you.
Thanks this worked out great! The transpose tool was giving me a little bit of trouble before, much appreciated.
Glad it worked out for you!