Yes, I forgot to mention last step: covert Julian date to the date format you use.
ITschak On Thu, Aug 2, 2018 at 10:56 AM saurabh khandelwal < sourabhkhandelwal...@gmail.com> wrote: > Thanks for reply. But in our rexx automation, we basically need all three > Year , month and date. So, not sure, if I can achieve it from the logic you > suggested before. > > > > On Thu, Aug 2, 2018 at 11:43 AM, ITschak Mugzach <imugz...@gmail.com> > wrote: > > > Try this logic: > > > > - Get the Julian date of today (YYXXX) > > - Deduct 1 from Julian date (xxx) > > - Last 3 digits zero? (xxx) > > - Deduct one from first two chars (year) (YY) > > - Decide the Julian date (365 or 366 based on year/4) (xxx) > > > > ITschak > > > > > > On Thu, Aug 2, 2018 at 10:38 AM saurabh khandelwal < > > sourabhkhandelwal...@gmail.com> wrote: > > > > > Hello Group, > > > > > > In REXX , we have Date function to calculate today's date but do we > have > > > any separate function to calculate yesterday's date. > > > > > > currently, we used > > > > > > TODAY= DATE('S') > > > YESTERDAY = TODAY - 1 > > > > > > this code work whole month but, starting of the month where we have > date > > > > > > ex : > > > > > > TODAY - '20180801' > > > > > > then yesterday will be calculated like > > > > > > TODAY -1 , So yesterday value will be > > > YESTERDAY = '20180800' , which is wrong. > > > > > > Can you please help to overcome this issue. > > > > > > ---------------------------------------------------------------------- > > > For IBM-MAIN subscribe / signoff / archive access instructions, > > > send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN > > > > > > > > > -- > > ITschak Mugzach > > *|** IronSphere Platform* *|* *Information Security Contiguous Monitoring > > for Legacy **| * > > > > ---------------------------------------------------------------------- > > For IBM-MAIN subscribe / signoff / archive access instructions, > > send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN > > > > > > -- > Thanks & Regards > Saurabh Khandelwal > > ---------------------------------------------------------------------- > For IBM-MAIN subscribe / signoff / archive access instructions, > send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN > -- ITschak Mugzach *|** IronSphere Platform* *|* *Information Security Contiguous Monitoring for Legacy **| * ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN