Get a month's days and merge with a table



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





.



Relevant Pages

  • RE: Get a months days and merge with a table
    ... Use the UNION scheme that Bob showed you. ... I agree completely with Bob: _WHY_ do you want to avoid the table??? ...
    (microsoft.public.inetserver.asp.db)
  • Re: Get a months days and merge with a table
    ... Can there be more than one job per dayno? ... It depends on the database, but I don't understand the resistance to doing ... This email account is my spam trap so I ...
    (microsoft.public.inetserver.asp.db)

Loading