Making Columns out of rows.

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hello,

Is there a way to take the below query/table :

Name..........Course.........Due Date
Bob.............Math............12-MAR-06
Bob.............English.........01-JAN-07
Bob.............History.........16-DEC-04
Jen.............Math............07-APR-06
Jen.............English.........14-JUN-06
Jen.............History.........08-MAR-06

And turn it into this:

Name.....Math.............English.............History
Bob........12-MAR-06....01-JAN-07........16-DEC-04
Jen.........07-APR-06....14-JUN-06.........08-MAR-06

I know if I were going from the bottom query to the top, I could do it with
a series of queries filtering out each course, and then combine all those
seperate queries with a Union query.

Can I use a union query or something else to make the bottom query out of
the top?

Thanks!

-Senexis.
 
Create a crosstab query that has Name as the Row Heading, Course as the
Column Heading, and Max of Due Date as the Value.
 
Back
Top