cancel
Showing results for 
Search instead for 
Did you mean: 

REPORT_SUBMIT in the Macrobuilder

Former Member
0 Kudos

All -

There is an Operator function available in macrobuilder which is "REPORT_SUBMIT" and it seems like it allows you to execute a report program in the background by clicking a macro. Is anyone aware of the exact syntax of this function on how to specify the program and variant to be executed?

Thanks

Gaurav

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Gaurav,

I have never used this function. But looks like you are right. You can execute a report using this function:

This is what the sap help says

"REPORT_SUBMIT( 'program_name' ; <'job_name'> ; <'job_number'>; <'newmode'>) causes the specified program to be executed. Use the optional arguments, job name and job number, if you wish the program to run in the background. If you set the argument 'newmode', the results are displayed in a new window."

Please refer to this link:

http://help.sap.com/saphelp_scm50/helpdata/en/1d/310eb3d0ee11d4b2e40050da385632/frameset.htm

former_member584840
Participant
0 Kudos

A few years too late, but I got this to work.

Using my favourite program which simply lists the users in the system

I used 3 lines in the macro (3 seperate "operator" lines)

MACRO NAME

STEP (User defined, 1 period, Initial)

ACTION BOX (ie drag in an ACTION BOX and put any description)

REPORT_SUBMIT(

'RSUSR002_ADDRESS' ; 'JOB1234' ; '15453500' ; 'new_mode'

)

So the above 3 lines are 3 "operator/function" boxes

put the program name then an SM36 created job that is visible in SM37 which I have called JOB1234 and which includes the program. then the job number is the ID that you find when you drill into the actual SM37 job and look at DETAILS.

Note - there are SPACES between the dashes and the semi-colons.

former_member584840
Participant
0 Kudos

Further testing it seems that the syntax is actually

PROGRAM, then NAME OF THE JOB AS IT WILL RUN AND THEN BE VISIBLE IN SM37 (so you can call this anything in the macro and that is what it will become)

The Job Number, I am yet to figure out what it is. DOesnt seem to matter what is in here.

(I thought it was the job number of an already created SM37 job, but this is wrong)

Also I cannot get any background jobs to work

ie using program

/SAPAPO/TS_BATCH_RUN

As i cant seem to put any variant that gets through the 2nd variant stage.

error message

Fill in all required entry fields

So, back to the drawing board for what I want.

May try this instead

creating a macro function to trigger an event, which could then be linked to a background job.

This looks like it would work OK.

http://www.sdn.sap.com/irj/scn/index?rid=/library/uuid/20fac120-4382-2910-2ca5-ece311642649

Answers (0)