Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi all, I have a question about this situation:
I have this table :
Key | MeasureA | MeasureB | MeasureC |
AAAAA | 10 | 20 | 30 |
and I want a final table like this:
Key | Measure | Value |
AAA | MeasureA | 10 |
AAA | MeasureB | 20 |
AAA | MeasureC | 30 |
I wrote the static solution:
TMP:
load
Key,
'MeasureA' as Measure,
MeasureA as Value
resident MyTable;
Concatenate
load
Key,
'MeasureB' as Measure,
MeasureB as Value
resident MyTable
.....
I would like to get this dinamyc (maybe in future will have new dimensions), using for each next .. but i'm not having success.
Any help?
Try cross table Annalisa.
crosstable(measure,Value,1)
Load * from <your initial table>;
CrossTable (Measure, Value)
Load
Key,
MeasureA,
MeasureB,
MeasureC
From TableName;