No, but it would be pretty simple to write using the 'DJ' (Julian date) conversion code. Simply calculate he 1st Monday of the month, e.g.
0001 today = DATE() 0002 mth = OCONV(today, 'DM') 0003 yr = OCONV(today, 'DY') 0004 first_of_month = ICONV(mth:'-1-':yr, 'D') 0005 day_of_week = OCONV(first_of_month, 'DW') 0006 first_monday = first_of_month + (8-day_of_week) 0007 CRT OCONV(first_monday, 'D'):' is the 1st Monday of this month.' then add 7, 14 and 21 days (to 'first_monday') to get the 2nd, 3rd and 4th Mondays respectively. That being said, rather than do the calculation, it might be better (simpler) to use an external table. On Mon, Jan 7, 2013 at 9:00 AM, MRM <[email protected]> wrote: > Hi, > > Is there a function to calculate e.g 3rd monday of every month. I know of > OCONV but that returns the day. > > Anyone out there kindly help. > > > Regards, > > MRM > > -- > -- > IMPORTANT: T24/Globus posts are no longer accepted on this forum. > > To post, send email to [email protected] > To unsubscribe, send email to [email protected] > For more options, visit this group at > http://groups.google.com/group/jBASE?hl=en > > > > -- -- IMPORTANT: T24/Globus posts are no longer accepted on this forum. To post, send email to [email protected] To unsubscribe, send email to [email protected] For more options, visit this group at http://groups.google.com/group/jBASE?hl=en
