SAP Function SLS_MISC_CONVERT_TO_DATE - convert content of a date field to a date-string according to user default

Parameter Reference Type Length Default Optional Text
P_DATE SLS_RESOVR-EVBEG D 8 Field of type DATS
P_DATE_FORMAT CHAR10 C 10 X Character field length = 10

Parameter Reference Type Length Text
P_DATE_STRING CHAR10 C 10 Character field length = 10

Exception Text
ERROR_SELECTING_USER_DEFAULTS error occured while selecting user defaults

Functionality
This FM converts the date into the user specified date format acceptingthe date and date format as the input parameters. If the date format isnot specified then a default date format DD.MM.YYYY is used to convertthe date.
Following are the date formats are being used:
,,a)DD.MM.YYYY
,,b)MM/DD/YYYY
,,c)MM-DD-YYYY
,,d)YYYY.MM.DD
,,e)YYYY/MM/DD
,,f)YYYY-MM-DD
And if any other format is specified the date is converted to the formatMM/DD/YYYY or DD/MM/YYYY.