I have a table similar to the following:
Year | Product | Value
2006 A 10
2006 B 20
2006 C 30
2007 A 40
2007 B 50
2007 C 60
I need a query that will return the following comparison
Product | 2006 Value | 2007 Value
A 10 40
B 20 50
C 30 60
What are the options for this? Can this be done without connections?
I work with DB2, but answers to all types of SQL will be helpful.
source
share