1974maiden
MIS
Hello,
I trying to join 2 tables, I know in some programs SQL the Transform/Pivot works but I'm no too sure how to do it in DB2, any help is appreciated.
Table1
LID Lot Date
1 100 01012004
Table2
PID LID Job Value
1 1 JobA 1.5
2 1 JobB 3.5
3 1 JobC 5.0
4 1 JobD 5.5
5 1 JobE 2.0
I'm looking to produce the following output ....
LID Lot Date JobA JobB JobC JobD JobE
1 100 01012004 1.5 3.5 5.0 5.5 2.0
Thankyou,
Jimmy
I trying to join 2 tables, I know in some programs SQL the Transform/Pivot works but I'm no too sure how to do it in DB2, any help is appreciated.
Table1
LID Lot Date
1 100 01012004
Table2
PID LID Job Value
1 1 JobA 1.5
2 1 JobB 3.5
3 1 JobC 5.0
4 1 JobD 5.5
5 1 JobE 2.0
I'm looking to produce the following output ....
LID Lot Date JobA JobB JobC JobD JobE
1 100 01012004 1.5 3.5 5.0 5.5 2.0
Thankyou,
Jimmy