‎2007 Jul 23 2:24 PM
Hi all,
I want to convert date which is in the format MMDDYY to sy-datum format YYYYMMDD.how can i do this?
Thanks,
Rakesh.
‎2007 Jul 23 2:29 PM
‎2007 Jul 23 2:30 PM
‎2007 Jul 23 2:36 PM
CONVERT_DATE_TO_EXTERNAL.
CONVERT_DATE_TO_INTERNAL.
DATE_STRING_CONVERT
Function Modules related to Date and Time Calculations
CALCULATE_DATE : Calculates the future date based on the input .
DATE_TO_DAY : Returns the Day for the entered date.
DATE_COMPUTE_DAY : Returns weekday for a date
DATE_GET_WEEK : Returns week for a date
DAY_ATTRIBUTES_GET : Returns attributes for a range of dates specified
MONTHS_BETWEEN_TWO_DATES : To get the number of months between the two dates.
END_OF_MONTH_DETERMINE_2 : Determines the End of a Month.
HR_HK_DIFF_BT_2_DATES : Find the difference between two dates in years, months and days.
FIMA_DAYS_AND_MONTHS_AND_YEARS : Find the difference between two dates in years, months and days.
MONTH_NAMES_GET : Get the names of the month
WEEK_GET_FIRST_DAY : Get the first day of the week
HRGPBS_HESA_DATE_FORMAT : Format the date in dd/mm/yyyy format
SD_CALC_DURATION_FROM_DATETIME : Find the difference between two date/time and report the difference in hours
L_MC_TIME_DIFFERENCE : Find the time difference between two date/time
HR_99S_INTERVAL_BETWEEN_DATES : Difference between two dates in days, weeks, months
LAST_DAY_OF_MONTHS : Returns the last day of the month
or
simple use:
WRITE date to ext_date MMDDYYYY.
date is in YYYYMMDD for mat type d
and ext_date(8) type c
or
data: l_date(10) type c.
write: sy-datum to date.
write : date.
regards,
srinivas
<b>*rewards for useful answers* </b>
‎2007 Jul 23 4:24 PM
‎2007 Jul 23 4:29 PM
Hi,
Use Function module <b>HRGPBS_HESA_DATE_FORMAT</b>
Regards
Sudheer
‎2007 Jul 23 4:44 PM
Hi,
Use function module
CONVERT_DATE_TO_EXTERNAL.
Pls reward all helpful points.
Regards,
Ameet