This is an extension of another thread but as it is more specific I think will be better by itself.
I have a report that needs a Previous and Next date, recurring every 3 months. The starting date can be any, including the last day of the month.
If the starting date is 1/31/07, and today's date is 2/23/09, then I would need to show 1/31/09 and the previous and 4/30/09 as then Next. The data I have to work with is starting date and day of the month - if the day of the month is 31, then it is always the last day. Data would look like this
Based on currentdate=2/23/09
Startdate Day Previous Next
1/31/07 31 1/31/09 4/30/09
6/15/08 15 12/15/08 3/15/09
8/21/06 21 2/21/09 5/21/09
I don't know datevar or how to create date groups ????
I'm thinking I would need to set some variable to say
if the month is 1,4,7,10 then Group1
if the month is 2,5,8,11 then Group2
????
Then determine where the current date falls in the group, and set the next and previous accordingly.
Any ideas on how to do this?
I have a report that needs a Previous and Next date, recurring every 3 months. The starting date can be any, including the last day of the month.
If the starting date is 1/31/07, and today's date is 2/23/09, then I would need to show 1/31/09 and the previous and 4/30/09 as then Next. The data I have to work with is starting date and day of the month - if the day of the month is 31, then it is always the last day. Data would look like this
Based on currentdate=2/23/09
Startdate Day Previous Next
1/31/07 31 1/31/09 4/30/09
6/15/08 15 12/15/08 3/15/09
8/21/06 21 2/21/09 5/21/09
I don't know datevar or how to create date groups ????
I'm thinking I would need to set some variable to say
if the month is 1,4,7,10 then Group1
if the month is 2,5,8,11 then Group2
????
Then determine where the current date falls in the group, and set the next and previous accordingly.
Any ideas on how to do this?