TOGREG=Yaa(s) - converts to a gregorian date with separators (for |example, C'2009.09.21').
|
WEEKDAY=CHAR3 - converts to a 3 character day of the week (for |example, C'WED' for Wednesday).
says how to use TOGREG and WEEKDAY similar keywords,
Joined: 07 Dec 2007 Posts: 2205 Location: San Jose
vasanthz wrote:
However SUBDAYS with WEEKDAY
Code:
21:81,8,Y4T,SUBDAYS,+3,WEEKDAY=CHAR3
gives a syntax error.
Well WEEKDAY and SUBDAYS are two different functions and syntax wise they are on the same level. Essentially when you are adding/subtracting days from a given date, the result should also be a date and not day of the week.
if you want the weekday function after arithmetic, then you can use the following
Is it just a personal choice or it is less CPU consuming?
Thanks & Regards,
well you are comparing apples to oranges. OVERLAY=(84,4,C'-',88,2,C'-',90,2)) is creating the date with separators where as OVERLAY=(84,8,Y4T,2X)) will create the date as CCYYMMDD and padding 2 spaces at the end.
If you need the formatting done automatically you need to specify it differently ex:
Code:
OVERLAY=(84,8,Y4T(-))
I just showed the date formatting manually. Just one of "n" ways to get the results. There will be no difference in CPU for this formatting.