‎2011 Nov 14 1:55 PM
Hello,
I would like to execute the function K_BATCH_REQUEST with another user-name (a batch name) but I do not found any option to execute this function with another user.
Someone can help me ??
<removed by moderator>
thanks a lot in advance for your help.
Daniel
Edited by: Thomas Zloch on Nov 14, 2011 3:02 PM
‎2011 Nov 14 2:04 PM
You can schedule jobs to run under a different user ID (if you have the authorization to do so), so you could create a wrapper program that calls this function module and schedule it as a background job.
Thomas
‎2011 Nov 14 2:16 PM
Hi,
I am new in abap.
If I understand well, if I execute this function in a wrapper program, I can execute this function with another user BUT,
What is a wrapper program ?
How do I execute a function in this program ?
Tx for your help
‎2011 Nov 14 3:14 PM
Suppose the FM signature looks like
FUNCTION ztest.
*"----------------------------------------------------------------------
*"*"Interface locale :
*" IMPORTING
*" REFERENCE(PAR1) TYPE C
*" TABLES
*" TAB1 STRUCTURE MARA
*"----------------------------------------------------------------------A wrapper program could look like
REPORT ztestwrapper.
TYPES tmara TYPE mara OCCURS 10.
* no-display allows much more flexibility here
PARAMETERS: par1 TYPE c NO-DISPLAY,
tab1 TYPE tmara NO-DISPLAY.
CALL FUNCTION 'ZTEST'
EXPORTING
par1 = par1
TABLES
tab1 = tab1.For the scheduling of the job read [Task Overview: Full-Control Job Scheduling|http://help.sap.com/saphelp_470/helpdata/en/fa/096cf2543b11d1898e0000e8322d00/frameset.htm]
Regards,
Raymond