17.08.2013 Views

Data Interfaces

Data Interfaces

Data Interfaces

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Example: Transfer Program 2<br />

© SAP AG<br />

START-OF-SELECTION.<br />

OPEN DATASET: OLDFILE FOR INPUT IN TEXT MODE,<br />

SAPFILE FOR OUTPUT IN TEXT MODE,<br />

ERRFILE FOR OUTPUT IN TEXT MODE.<br />

*E Open session:<br />

MOVE: '0' TO BGR00-STYPE,<br />

SESSION TO BGR00-GROUP,<br />

SY-MANDT TO BGR00-MANDT,<br />

SY-UNAME TO BGR00-USNAM,<br />

NODATA TO BGR00-NODATA.<br />

TRANSFER BGR00 TO SAPFILE.<br />

*E Initialize record layout:<br />

DO.<br />

ADD 1 TO N.<br />

ASSIGN COMPONENT N OF STRUCTURE AUXREC TO .<br />

IF SY-SUBRC NE 0. EXIT. ENDIF.<br />

MOVE BGR00-NODATA TO .<br />

ENDDO.<br />

MOVE AUXREC TO BLFA1.<br />

Session data (such as session name, client, user name and the special character for ‘no batch input for<br />

this field’) is passed in table structure BGR00.<br />

The structure BLFA1 is initialized using the ASSIGN statement. Some applications (e.g.MM) also<br />

provide special initialization routines (e.g. INIT_STRUKTUREN_ERZEUGEN in program<br />

RMMMBIMI). For more details, refer to the online documentation for the particular batch input<br />

program.

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!