Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> How Do I Get a list of Days for a Given Month?
I am trying to get a list of days for a month, given a specific date.
For example, if I am given the date of '04-OCT-97', I want to get a list as follows:
01-OCT-97 02-OCT-97 03-OCT-97 04-OCT-97 05-OCT-97 06-OCT-97 07-OCT-97 08-OCT-97 09-OCT-97 10-OCT-97 11-OCT-97 12-OCT-97 13-OCT-97 14-OCT-97 15-OCT-97 16-OCT-97 17-OCT-97 18-OCT-97 19-OCT-97 20-OCT-97 21-OCT-97 22-OCT-97 23-OCT-97 24-OCT-97 25-OCT-97 26-OCT-97 27-OCT-97 28-OCT-97 29-OCT-97 30-OCT-97 31-OCT-97
The closest I have come is obtaining the start and end dates for the month:
select
ADD_MONTHS(LAST_DAY('04-OCT-97'),-1)+1 "First of Month"
from dual
union
select
LAST_DAY('04-OCT-97') "Last of Month"
from dual
;
Please Help...
Thanks...
--
Thanks.
Keep on Smiling...
Shonté N. (Tate) Poe - SPOE2 ¦Main Desk: Phone/Fax 313 62-18405
Ford Motor Company ¦Livonia: Phone/Fax 313 26-69686
Web Application Development ¦E-Mail: spoe2_at_ford.com
Received on Fri Oct 23 1998 - 10:47:46 CDT
![]() |
![]() |