Good afternoon.
I work with parts application data for automobiles. Typically the data I work with will have the info listed individually by year. Sometimes I need to consolidate years using a query. Sometimes there will be year gaps and I do not know how to account for that.
Year| Make | Model |PartNo |
2001|Toyota|Corolla|8675309|
2002|Toyota|Corolla|8675309|
2004|Toyota|Corolla|8675309|
2005|Toyota|Corolla|8675309|
There is no 2003. Using the Min and Max functions in a query I would get:
Years | Make | Model |PartNo |
2001-2005|Toyota|Corolla|8675309|
This would not be correct. The correct result would be:
Years | Make | Model |PartNo |
2001-2002|Toyota|Corolla|8675309|
2004-2005|Toyota|Corolla|8675309|
What would be the best way to get the data correctly?