Get a month's days and merge with a table
- From: "Nime" <nime@xxxxxx>
- Date: Thu, 14 Aug 2008 18:37:07 +0300
I have a time table:
jobid | dayno | job
1 | 2 | Report finished tasks
2 | 4 | Check all forms
....
I want to create a days list of a month and merge it with my jobs table.
The result should be like this:
dayofmonth | jobid | dayno | job
1 | NULL | NULL | NULL
2 | 1 | 2 | Report finished tasks
3 | NULL | NULL | NULL
4 | 2 | 4 | Check all forms
5 | NULL | NULL | NULL
6 | NULL | NULL | NULL
....
30 | NULL | NULL | NULL
Is it possible to do that wihout a dummy days table of months?
I created a day table of month like below:
dayno
1
2
....
30
31
.
- Follow-Ups:
- RE: Get a month's days and merge with a table
- From: Old Pedant
- Re: Get a month's days and merge with a table
- From: Bob Barrows [MVP]
- RE: Get a month's days and merge with a table
- Prev by Date: Re: ASP and MySQL
- Next by Date: Re: Get a month's days and merge with a table
- Previous by thread: ASP and MySQL
- Next by thread: Re: Get a month's days and merge with a table
- Index(es):
Relevant Pages
|
Loading