Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Printing every Monday from 1998 to today

Status
Not open for further replies.

erixire

Technical User
Jun 4, 2002
72
CA
Hi,

Is it possible with Oracle to print every monday from a certain date (1 january 1998) to today in a kind of list like this:

01-01-1998
08-01-1998
15-01-1998
...


Thanks a lot,
 
Something like the following should work.

declare list_monday date := '01-jan-1998';
begin
while list_monday <= sysdate
loop
dbms_output.put_line(list_monday);
list_monday := next_day(list_monday,'Monday');
end loop;
end;
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top