Emmanuel
Master Tech
- Local time
- Today, 14:41
- Joined
- Sep 4, 2002
- Messages
- 88
Good day to all,
I have a very interesting dilema, but hopefully a simple one. I have one table that has the date of the order and the order number. My problem is that I need to show on the results of the query all the dates for a specific month and null values on the dates that don't have any orders. For example:
This is my table as it is now.
Date Order
7/1/2007 123
7/3/2007 142
7/9/2007 851
7/11/2007 552
7/15/2007 225
This is what I would like to see in the results:
Date Order
7/1/2007 123
7/2/2007 Null
7/3/2007 142
7/4/2007 Null
7/5/2007 Null
7/6/2007 Null
7/7/2007 Null
7/8/2007 Null
7/9/2007 851
7/10/2007 Null
7/11/2007 552
7/12/2007 Null
7/13/2007 Null
7/14/2007 Null
7/15/2007 225
I know how to do this with a temp table that has all the dates, but can this be done with a formula? For example a user enters a date range of July 1,2007 to July 15, 2007 and gets the above results.
Thanks in advace for your help.
I have a very interesting dilema, but hopefully a simple one. I have one table that has the date of the order and the order number. My problem is that I need to show on the results of the query all the dates for a specific month and null values on the dates that don't have any orders. For example:
This is my table as it is now.
Date Order
7/1/2007 123
7/3/2007 142
7/9/2007 851
7/11/2007 552
7/15/2007 225
This is what I would like to see in the results:
Date Order
7/1/2007 123
7/2/2007 Null
7/3/2007 142
7/4/2007 Null
7/5/2007 Null
7/6/2007 Null
7/7/2007 Null
7/8/2007 Null
7/9/2007 851
7/10/2007 Null
7/11/2007 552
7/12/2007 Null
7/13/2007 Null
7/14/2007 Null
7/15/2007 225
I know how to do this with a temp table that has all the dates, but can this be done with a formula? For example a user enters a date range of July 1,2007 to July 15, 2007 and gets the above results.
Thanks in advace for your help.