My input table looks like this
ColumnA | ColumnB | ColumnC | ColumnD | ColumnE |
HeadingA | [Null] | [Null] | [Null] | [Null] |
SubheadingA | [Null] | [Null] | [Null] | [Null] |
Value A1 | Value B1 | Value C1 | Value D1 | Value E1 |
Value A2 | Value B2 | Value C2 | Value D2 | Value E2 |
HeadingB | [Null] | [Null] | [Null] | [Null] |
Value A3 | Value B3 | Value C3 | Value D3 | Value E3 |
So sometimes there's only 1 main heading, sometimes there's both a heading and a subheading. I would like to create 2 separate columns for headings and subheading, as shown below:
Heading | Subheading | ColumnA | ColumnB | ColumnC | ColumnD | ColumnE |
HeadingA | [Null] | [Null] | [Null] | [Null] | [Null] | [Null] |
HeadingA | SubheadingA | [Null] | [Null] | [Null] | [Null] | [Null] |
HeadingA | SubheadingA | Value A1 | Value B1 | Value C1 | Value D1 | Value E1 |
HeadingA | SubheadingA | Value A2 | Value B2 | Value C2 | Value D2 | Value E2 |
HeadingB | [Null] | [Null] | [Null] | [Null] | [Null] | [Null] |
HeadingB | [Null] | Value A3 | Value B3 | Value C3 | Value D3 | Value E3 |
There is a large number of headings/subheadings with data following them. Any ideas how to achieve the above transformation? I feel like it is simple but can't quite point my finger to it without some complex multi-row formulas.
Solved! Go to Solution.
Hi @AkisM,
I believe this is what you're trying to achieve?
If this solves your issue please mark the answer as correct, if not let me know! I've attached my workflow for you to download if needed.
Regards,
Jonathan
@Jonathan-Sherman Hi, not quite. Value A is lost in the workflow above. All values must be kept intact, as shown in Table 2 in my original post.
Hi @AkisM,
In that case i've made a small change, I think this is now what you're trying to achieve?
If this solves your issue please mark the answer as correct, if not let me know! I've attached an updated workflow for you to download if needed.
Regards,
Jonathan
Hi @Jonathan-Sherman , not exactly, because the headings/subheadings can be any word, not those words specifically. So using those words as flags won't work. But I get the point of the workflow now, I will just use isNull on the value columns as the flag and it should work fine. Thanks for your help.