Heres one to change a 6,0 numeric date in MMDDYY form to 7,0 numeric date in CYYMMDD form.
Eval INTERNAL_DATE = %dec(%char(%date(EXTERNAL_DATE:*mdy) :*cymd0):7:0)
INTERAL_DATE is the 7,0 CYYMMDD date.
EXTERNAL_DATE is the 6,0 MMDDYY date.
IBM i, AS400, iSeries, Programming, RPG
October 14, 2008
By NickLitten
Heres one to change a 6,0 numeric date in MMDDYY form to 7,0 numeric date in CYYMMDD form.
Eval INTERNAL_DATE = %dec(%char(%date(EXTERNAL_DATE:*mdy) :*cymd0):7:0)
INTERAL_DATE is the 7,0 CYYMMDD date.
EXTERNAL_DATE is the 6,0 MMDDYY date.
related posts:
I’m always looking for awesome input, feedback and critique!
Session expired
Please log in again. The login page will open in a new tab. After logging in you can close it and return to this page.