Joined: 07 Dec 2007 Posts: 2205 Location: San Jose
madishpa wrote:
Hi,
Thank you very much for the reply.
Please could you help advise as what would needs to be done if the date is as follows:
2012-08-12 2012-08-12 2012-08-12 2012-08-11
The expected o/p is as follows:
2012-08-13 2012-08-13 2012-08-13 2012-08-11
As the 2012-08-12 being a Sunday, the day has been incremented.
Appreciate your kind help.
Thanks
Madishpa.
Madishpa,
Can you tell me the trick of storing 4 date fields in CCYY-MM-DD format into a 20 byte FB file?
Why can't you tell us the actual requirement when you cannot modify the control cards supplied to you? You are just wasting not only your time as well as anyone who is trying to help you.
Knickraj,
I am sure you just got a glimpse of the actual number of date fields. It might be a month worth of data that needs to modify and in such cases it is better to go with weekday function to return the day of week in numeric format so that we can reduce the length of the expanded record.
We we receive these 4 dates from a different application, for which we do not have control as they send these dates to different applications.
As our application alone does not run on a Sunday, we will have to consider incrementing the day by 1 which will be used down the line in the job.