‎2006 Jun 04 11:51 AM
Hi all,
i have a Date field in flat file as YYDDMM format.
i have to read it into internal table and according to that i have to fetch some data.
how can i convert the YY field into YYYY.
my system date format is YYYYMMDD.
‎2006 Jun 04 12:13 PM
Rupa
As its YY format its difficult to know whether it is 19XX or 20XX, so based on assumptions you need to concatenate with 19 or 20 to YY.
Regds
Manohar
‎2006 Jun 04 12:18 PM
Hi Roopa,
follow this code ..
data: date like sy-datum.
data: date1 like sy-datum.
data: date2(10) type c.
date = 050102 (as your format).
move: date to date_8.
write date1 to date2.
write: date2.here the date2 will have the 10 digit date format which will have your SAP System format .. whatever the format you have in the System this DATE2 will also have the same format ..
please close the thread if this answers the question
Thanks
Sudheer