‎2008 Jul 11 12:16 PM
I have to creaet a program to run in batch mode to update anln1 and anln2.
selection screen : company and cost center.
I have to read z table
update anln1 and anln2 ( from table anla )
Can anybody help me how to write a program in batch mode and update....
‎2008 Jul 11 12:51 PM
Schedule the program using a variant to run in background from transaction SM36.
Regards,
Joy.
‎2008 Jul 11 12:36 PM
Hi
SY-BATCH
X if the ABAP program is running in the background, otherwise space
Batch Input
SY-BINPT
X while a batch input session is running and when an ABAP program is called using
CALL TRANSACTION USING, otherwise space.
OPTIONS FROM in the CALL TRANSACTION USING statement can set SY-BINPT to space either for
the entire duration of the program, or at the end of the BDC data.
SY-BINPT is always space during a CATT procedure.
Regards
Divya
‎2008 Jul 11 12:51 PM
Schedule the program using a variant to run in background from transaction SM36.
Regards,
Joy.
‎2008 Jul 11 1:25 PM
Hi,
Write the entries logic with the condidtion like below.
after selecting the required data,
if sy-batch = 'X'.
Now update the required table.
endif.
Even you can put the select statement also after if condition.
now go to SM36 and define the Job with Program name or any other name.
Under Job condition select the execution mode/time of your program.
As you have mentioned the sy-batch condition , your program will work only for Back ground mode.
Hope it helps you.
Kind Regards,
Ravi Sankar.Z