‎2007 Mar 28 9:24 AM
Hi All,
I want to display only DATE and MONTH of a particular date.What ever be the date format stored in TABLE I need to display it as 22.03 ( DD.MM ).( display only date and month )
Ex- 20070322 or any format , i need to display as 2203( DD.MM ).
Please help me out in this
Regards
Avi.........
‎2007 Mar 28 9:27 AM
hi avi,
do this way ...
data : v_date like sy-datum value '20070327',
v_date1(10) type c.
v_date = sy-datum.
v_date1 = v_date.
concatenate v_date1+4(2) '.' v_date1+6(2) into v_date1.
write : v_date1.Regards,
Santosh
‎2007 Mar 28 9:27 AM
‎2007 Mar 28 9:27 AM
data : day(2),
mon(2).
data : dates like sy-datum value '20070322'.
data : daymon(4).
day = dates+6(2).
mon = dates+4(2).
concatenate day mon into daymon.
write : / daymon
regards
shiba dutta
Message was edited by:
SHIBA DUTTA
‎2007 Mar 28 9:27 AM
hi avi,
do this way ...
data : v_date like sy-datum value '20070327',
v_date1(10) type c.
v_date = sy-datum.
v_date1 = v_date.
concatenate v_date1+4(2) '.' v_date1+6(2) into v_date1.
write : v_date1.Regards,
Santosh
‎2007 Mar 28 9:28 AM
Take a Character FIeld of 4 length and use that
DATA: DATE(4).
DATE = sy-datum+4(4).
WRITE: DATE.
‎2007 Mar 28 9:30 AM
Hi Avi,
Use this function module <b>HR_IN_GET_DATE_COMPONENTS</b>.
It will return you Day and Month of the date.
Thanks & Regards,
Siri.
‎2007 Mar 28 9:37 AM
CONVERT_DATE_FORMAT
try this data v_date type d. v_date = '20071001'. data v_format type char4. write v_date to v_format using no edit mask. write v_format use WRITE TO <d> statement
write sy-datum to ZIE02-DATSL DDMM
reward all helpfull answers
Message was edited by:
sunil kumar
Message was edited by:
sunil kumar
‎2007 Mar 28 9:41 AM
Day = sy-datum+4(2).
month = sy-datum+6(2).
write: \ day month or month day.
regards,
‎2007 Mar 28 9:39 AM
Hey Avi,
Let it be any format for display but date format in which it is available in a variable with data type as Date is always in YYYYMMDD.
Day = date+4(2).
month = date+6(2).
write: / day, month.
So you can extract the date and month from this variable and then go ahead with display..it will display date and month properly....
Regards,
Kunjal