1. SUBMIT rep.
2. SUBMIT (name).
1. ...
LINE-SIZE col
2. ...
LINE-COUNT line
3. ... TO SAP-SPOOL
List output to the SAP spool database
4.
... USING SELECTION-SCREEN scr
5.
... VIA SELECTION-SCREEN
6.
... AND RETURN
7. ...
EXPORTING LIST TO MEMORY
8.
... USER user VIA JOB job NUMBER n
9. ...Various
additions for passing parameters to
rep
10. ... USING SELECTION-SETS OF PROGRAM prog
Calls report rep.
The system leaves the active program
and starts the new report rep. In basic form 2, you can
specify the name of the report in the field name. You must specify the name in uppercase, otherwise a runtime error occurs.
... LINE-SIZE col
The list generated by the report has the line width col.
... LINE-COUNT line
The list generated by the report has line lines per page.
... USING SELECTION-SCREEN scr
When you execute the report, the system uses the selection screen number that you specify in the
scr
field. This must be a selection
screen
defined using the SELECT-OPTIONS,
PARAMETERS
and SELECTION-SCREEN
statements.If you omit the addition, the system uses the standard selection screen 1000.
This addition allows you to start the same report in different situations, using a different selection screen each time.
... VIA SELECTION-SCREEN
The selection screen is displayed. In this case, the selection screen is displayed again after the report list has been displayed. The values entered by the user remain displayed.
... AND RETURN
Returns to the calling transaction or program after the called program has been executed.
SUBMIT ... AND RETURN creates a new internal session.
... EXPORTING LIST TO MEMORY
Does not display the output list of the called report, but saves it in ABAP
memory and leaves the called report immediately. Since the calling program can read the list from
memory and process it further, you need to use the addition ... AND
RETURN
. Also, since the called report cannot be requested for printing, the addition
... TO SAP-SPOOL is not allowed here. In addition, you must
not assign a function code to the ENTER key in the current GUI status. The saved list is read from the
SAP memory using the function module 'LIST_FROM_MEMORY'
and can then be saved to the database using
EXPORT, for example. You can process this list further
with the function modules
'WRITE_LIST', 'DISPLAY_LIST' ... of the function group "SLST".
... USER user VIA JOB job NUMBER n
Schedules the specified report in the job specified by the job name job and the job number n. The job runs under the user name user and you can omit the addition USER user. The assignment of the job number occurs via the function module JOB_OPEN (see also the documentation for the function modules JOB_CLOSE and JOB_SUBMIT). This addition can only be used with the addition ...AND RETURN.
When scheduling a report with the SUBMIT ... VIA JOB job NUMBER n
statement, you should always use the addition ...TO SAP-SPOOL
to pass print and/or archive parameters. Otherwise, default values are used to generate the list and this disturbs operations in a production environment.
... USING SELECTION-SETS OF PROGRAM prog
Uses variants of the program prog when executing the program rep.
Important
The programs prog
and
rep must have the same SELECT-OPTIONS
and PARAMETERs. Otherwise, variants of the program prog may be destroyed.
When using this addition, the specified variant vari of
the program
prog is taken in USING
SELECTION-SET vari. On the other hand, all variant-related actions on the selection screen
of rep (Get, Save
as variant, Display, Delete) refer to the variants of prog.
SUBMIT REPORT01
VIA SELECTION-SCREEN
USING SELECTION-SET 'VARIANT1'
USING SELECTION-SETS OF PROGRAM 'REPORT00'
AND RETURN.
Executes the program
REPORT01 with the variant VARIANT1 of the program REPORT00.
Non-Catchable Exceptions
Starting Executable Programs (Reports)