conversion of date field format from char to dats
one issue with Date field.
in my internal table i have a date field with type char(10).
But when I upload the data to database through upload program, there I have a date field with type "DATS".
how do I convert and store it in "DATS " format in database.
Try this use CONVERT_DATE_TO_INTERNAl
CALL FUNCTION 'CONVERT_DATE_TO_INTERNAL'
date_external = "ur date from file
DATE_INTERNAL = "( date in dats format )
DATE_EXTERNAL_IS_INVALID = 1
OTHERS = 2
IF sy-subrc <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.