Skip to Content
0
Former Member
Jan 02, 2006 at 09:36 AM

bdc using call transaction

15 Views

FORM validate_doj .

if it_emp-doj = 00000000 or it_emp-doj >= sy-datum or it_emp-doj = ' ' OR IT_EMP-DOJ CA '/'.

error_flag = 1.

it_errorrecds-it_emp_id = it_emp-e_id.

IT_ERRORRECDS-IT_DESC = 'INVALID DOJ'.

NOTE: INFORMATION IN THE FLAT FILE CONTAINS IN THE FOLLOWING FORMAT .21/12/2006 I.E. MM/DD/YYYY.

ABOVE CODE I AM USING FOR VALIDATING THE DATE.

BUT IT IS NOT TRAPPING THE ERROR,WHEN MONTH IS GREATER THAN 12.

FORMAT Of THE DATE WHICH I AM USING IS MM/DD/YYYY.

AND THE FOLLOWING IS THE RUN TIME ERROR WHICH I AM GETTING WHEN I EXECUTE MY TRANSACTION is :

" THE PROGRAM ATTEMPTED TO INTERPRET THE VAUE " 21/11/2005" AS A NUMBER ,BUT SINCE THE VALUE

CONTRAVENES THE RULES FOR CORRECT NUMBER FORMATS,THIS WAS NOT POSSIBLE.

well it is not trapping the error in my validations.

PLEASE PROVIDE ME WITH THE PROPER SOLUTION WHERE I CAN TRAP THIS ERROR IN MY VALIDATIONS.