2006 Feb 09 10:07 PM
Hi,
I am implementing a Parallel processing program, which submits a main SAP program parallely. For that I want to understand what SUBMIT, Using selection-set keywords are?.
If anybody knows provide some help on this.
Thanks,
Raj.
2006 Feb 09 10:10 PM
You can pass the values to the input fields of the program which are using in Submit command.
sample code:
DATA: t_seltab TYPE TABLE OF rsparams,
wa_seltab LIKE LINE OF t_seltab.
*-- vendor Code
Change from s_vendor to s_lifnr for SIR 1543
LOOP AT s_lifnr.
MOVE: 'LIFNR' TO wa_seltab-selname,
'S' TO wa_seltab-kind, " SELECT-OPTION
'I' TO wa_seltab-sign.
IF s_lifnr-high IS INITIAL AND NOT s_lifnr-low IS INITIAL.
MOVE'EQ' TO wa_seltab-option.
ENDIF.
IF NOT s_lifnr-high IS INITIAL AND NOT s_lifnr-low IS INITIAL.
MOVE 'BT' TO wa_seltab-option.
ENDIF.
MOVE: s_lifnr-low TO wa_seltab-low,
s_lifnr-high TO wa_seltab-high.
APPEND wa_seltab TO t_seltab.
CLEAR wa_seltab.
ENDLOOP.
*-- Source Company Code
MOVE: 'BUKRS' TO wa_seltab-selname,
'P' TO wa_seltab-kind, " SELECT-OPTION
'I' TO wa_seltab-sign,
'EQ' TO wa_seltab-option,
p_bukrs TO wa_seltab-low.
APPEND wa_seltab TO t_seltab.
CLEAR wa_seltab.
*-- From Change Date
MOVE: 'DATUM' TO wa_seltab-selname,
'P' TO wa_seltab-kind, " SELECT-OPTION
'I' TO wa_seltab-sign,
'EQ' TO wa_seltab-option,
p_datum TO wa_seltab-low.
APPEND wa_seltab TO t_seltab.
CLEAR wa_seltab.
*-- Calling the standard program of fk15 transaction
SUBMIT rfbikr10 WITH SELECTION-TABLE t_seltab and
return.
Thanks,
Rajesh
Message was edited by: Rajesh Mandalapu
2006 Feb 09 10:10 PM
Report ZZ.
data: session(1) type c.
data: ccdetail type bapi0002_2.
start-of-selection.
Call the transaction in another session...control will be stop
in calling program and will wait for response from other session
call function 'BAPI_COMPANYCODE_GETDETAIL'
starting new task 'TEST' destination 'NONE'
performing set_session_done on end of task
exporting
companycodeid = '0010'
IMPORTING
COMPANYCODE_DETAIL = ccdetails
COMPANYCODE_ADDRESS =
RETURN =
.
wait here till the other session is done
wait until session = 'X'.
write:/ ccdetail.
************************************************************************
FORM SET_session_DONE
************************************************************************
form set_session_done using taskname.
Receive results into messtab from function.......
this will also close the session
receive results from function 'BAPI_COMPANYCODE_GETDETAIL'
importing
companycode_detail = ccdetail.
Set session as done.
session = 'X'.
endform.
2006 Feb 10 6:44 PM
tHANKS FOR the help so far. I am getting error HR MSG 836 when I execute the program. How do I mention server group name from RZ12 transaction. Is it the instance name or group name?.
Here is how I am calling.
CALL FUNCTION 'Z_DKG_XYZ' "Function module to perform
"in parallel
STARTING NEW TASK TASKNAME "Name for identifying this
"RFC call
DESTINATION IN GROUP 'PARAJOBGROUP'
Please let me know if there are any mistakes?.
Thanks,
Raj.