‎2008 Mar 19 12:08 PM
Hi folks,
Is there any possibility in call transaction that error records can have the report program( in the same bdc program) and provided as a list. if it scheduled at background.
Is there any specific number for records that the user should choose the foreground or background when he run the program.i.e for ex. if it is 50 records you can execute immediately say if it is 1000 records go for background scheduling the program.
<REMOVED BY MODERATOR>
Thanks in advance,
poorna.
Edited by: Alvaro Tejada Galindo on Mar 19, 2008 6:36 PM
‎2008 Mar 20 1:55 AM
Hi Purna,
It would be better if you store the log messages inside a custom table and then roll it out in a report form.
The other way is to pass them in another spool form.
Regards,
Abhishek Raj.
‎2008 Mar 20 1:55 AM
Hi Purna,
It would be better if you store the log messages inside a custom table and then roll it out in a report form.
The other way is to pass them in another spool form.
Regards,
Abhishek Raj.
‎2008 Mar 20 2:41 AM
Hi,
1. After CALL TRANSACTION statement in BDC check sy-subrc.
Declare internal table(i_errors) having the fields which required to show in error records file.
DATA : BEGIN OF i_RECORDS OCCRS 0,
REC(500),
END OF i_RECORDS.
LOOP AT ITAB
CALL TARASACTION ..........
IF sy-subrc NE 0.
MOVE : ITAB records into i_errors.
APPEND.
ENDIF.
IF SY-BATCH EQ 'X'.
OPEN DATA SET filename.
LOOP AT i_errors.
TRANSFER i_errors TO filename.
ENDLOOP.
CLOSE DATASET filename.
ENDIF.
ENDLOOP.
ENDIF.
Here all eroor records will store in Application server file.You can view by tcode AL11.
2. question.
DESCRIBE TABLE itab LINE v_lines.
IF v_lines > 50.
use FM JOB_OPEN , JOB_SUBMIT ,JOB_CLOSE. to run in background.
ELSE.
LOOP AT ITAB.
BDC code here.
ENDLOOP.
ENDIF.