‎2009 Jun 04 9:22 AM
Hi,
I have one program which creates variant.The variant date created by the program is wrong 1//20/05/2.
What would be the issue?
As per my knowledge, we get this error because we pass date to an internal table in MM/DD/YYYY format instead of YYYYMMDD. Usually programs take YYYYMMDD format and displays the output in MM/DD/YYYY. But i am not finding any such case here in the program to solve the issue.
‎2009 Jun 04 9:39 AM
Hi,
Check the date format in the internal table while creating the variant. The format would be MM/DD/YYYY and you are passing this value to another date field in which only first eight char will be moved.
So convert the MM/DD/YYYY to YYYYMMDD and move this to value in the variant.
‎2009 Jun 04 9:40 AM
*convert date yyyymmdd to mm/dd/yyyy
concatenate itab-process_date+4(2)
itab-process_date+6(2)
itab-process_date(4)
into it_fin-doc_dt separated by '/'.
hope this will help u
regards,
PP
‎2009 Jun 04 9:43 AM
Hi,
Please check the type for the date fields. It should be DATUM.
This will help.
Regards,
Prashant
‎2009 Jun 04 9:59 AM
‎2009 Jun 04 9:47 AM
Hello Raju,
Please once have a look at FM below :
CONVERT_DATE_TO_EXTERNAL
CONVERT_DATE_TO_INTERNAL.
User This to convert your date format according to your need.
may this will solve your problem.
Regards,
Sujeet
‎2009 Jun 04 9:52 AM
Hi,
use FM RSEC_DATE_CONVERT to convert date into internal format.
Regards,
Raju.
‎2009 Jun 04 9:57 AM
Hi,
concatenate jtab-process_date+4(2)
jtab-process_date+6(2)
jtab-process_date(4)
into it_fin-doc_dt separated by '/'.
write 😕 it_fin_dt.
regards,
munibabu.K