cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

SUBMIT AND RETURN USER VIA JOB with different user name other than sy-uname

kjyothiraditya
Participant
0 Kudos
3,138

Hi Experts,

I am enclosing SUBMIT z-report WITH SELECTION-TABLE AND RETURN USER VIA JOB in between JOB_OPEN and JOB_CLOSE where in for USER parameter, i am giving a different user name. But it is always taking the SY-UNAME. I have checked some blogs wherein SELECTION SET was used and also was suggested to use BJ_JOB_MODIFY. But i am not using variant and passing the parameters on the fly as above.

So can u let me know how to make the program to consider the user provided as part of the SUBMIT command.

CALL FUNCTION 'JOB_OPEN'.

SUBMIT z-report WITH SELECTION-TABLE lt_params

TO SAP-SPOOL SPOOL PARAMETERS ls_pri_params

WITHOUT SPOOL DYNPRO

USER 'BATCH_XXX'

VIA JOB lv_name NUMBER lv_number

AND RETURN.

CALL FUNCTION 'JOB_CLOSE'.

SAP component version: SAP_AP - SAPKNA7025

SAP_BASIS - SAPKB70210

Regards,

Aditya

Accepted Solutions (0)

Answers (0)