I need a script in ksh that when I provide a month and year as input let us say JAN-2009 then it should split the dates into weeks and I need to store them as
WEEK1_START = '2009-01-01-00.00.00'
WEEK1_END = '2009-01-09-00.00.00'
WEEK2_START = '2009-01-09-00.00.00'
WEEK2_END = '2009-01-16-00.00.00'
WEEK3_END = '2009-01-23-00.00.00'
WEEK4_START = '2009-01-23-00.00.00'
WEEK4_END = '2009-02-01-00.00.00'
Let me know how to get this.. I wanted weekly dates in this format since I wanted to use the above values in my db2 script which has datetime as datatype.. Thanks!!