I have a table tracking, say, an organization's participation in a particular program. The relevant columns in this table might look something like:
OrganizationID Year Status
1 1999 Inactive
1 2000 Inactive
1 2001 Active
1 2002 Active
1 2003 Active
1 2004 Inactive
1 2005 Inactive
What I would like to produce is:
OrganizationID Status FromYear ToYear
1 Inactive 1999 2000
1 Active 2001 2003
1 Inactive 2004 2005
Any ideas for accomplishing this would be greatly appreciated.
OrganizationID Year Status
1 1999 Inactive
1 2000 Inactive
1 2001 Active
1 2002 Active
1 2003 Active
1 2004 Inactive
1 2005 Inactive
What I would like to produce is:
OrganizationID Status FromYear ToYear
1 Inactive 1999 2000
1 Active 2001 2003
1 Inactive 2004 2005
Any ideas for accomplishing this would be greatly appreciated.