Hi Friends,
I have a table which looks like this
CustomerName ALias ProductCode1 ProductCode2
John Jon test1
James Jam Test2
Jack JAc test3
What I now need is a result set in the following way:
Customer ProductCode Indicator
John_Jon_ProductCode1 ProductCOde1 Test1
John_Jon_ProductCode2 ProductCOde2 null
James_Jam_ProductCode1 ProductCOde1 null
James_Jam_ProductCode2 ProductCOde2 Test2
JAck_Jac_ProductCode1 ProductCOde1 Test3
JAck_Jac_ProductCode1 ProductCode2 null
So basically i want to use the productcode columns as row values and each customer will have as many entries as the count of ProductCode columns. How can I achive this?
Thank You