Transpose rows to columns

I have a need to generate labels names out of rows.
I have two columns in my table.
row1 - ‘redOverride’, ‘orange’
row2 - ‘blueOverride’,‘green’
row3 - ‘yellowOverride’,‘amber’

rown - 'lastValue,‘none’

I will use these labels in my master report.
In oracle, I can use pivot by means of following.

select max(case when Attribute=‘redOverride’ then value else ‘red’ end) Label1,
max(case when Attribute=‘blueOverride’ then value else ‘blue’ end) and so on
from TableLabelValues

My universe will have only two objects Attribute and value

I will be using label1, label2 and so on in my master report. If there are no label overrides then I will use my default label, ie, red, blue, yellow etc.

Any ideas will be greatly appreciated.

Thanks


paddy_iyer (BOB member since 2005-09-22)

Welcome to B :mrgreen: B

Did you created table with the required fields??YES, then what is result??

Thanks


BOCP (BOB member since 2007-07-02)

The table is already there with columns Attribute and value. I cannot create a target table with the sql explained. The reason being I can have n number of labels/columns.

Did that help you?


paddy_iyer (BOB member since 2005-09-22)