Sunday 28 December 2014

qRFC with Outbound Queue & Inbound Queue between two different SAP systems - One LUW per mixed part of the Queues

---------------------------------------------------------------------------------------------------------------------------------------
Step1. If  one queue contains two RFC FM calls and we have two such Queues, then some part of Each Queue can be put into a single LUW. Execute the program. 
--------------------------------------------------------------------------------------------------------------------------------
DATA ls TYPE scarr.
*** first luw multiple queue  *****
CALL FUNCTION 'TRFC_SET_QIN_PROPERTIES'
  EXPORTING
    qout_name = 'OUT_QUEUE1'
    qin_name  = 'INN_QUEUE1'.
clear ls.
ls-carrid = 'XX'.
CALL FUNCTION 'ZCREATE_FLIGHT_REC'
 IN BACKGROUND TASK
 "AS SEPARATE UNIT " creates a separate luw
 DESTINATION 'SRC_TO_TGT'
EXPORTING
  is = ls.

CALL FUNCTION 'TRFC_SET_QIN_PROPERTIES'
  EXPORTING
    qout_name = 'OUT_QUEUE2'
    qin_name  = 'INN_QUEUE2'.
clear ls.
ls-carrid = 'YY'.
CALL FUNCTION 'ZCREATE_FLIGHT_REC'
 IN BACKGROUND TASK
 "AS SEPARATE UNIT " creates a separate luw
 DESTINATION 'SRC_TO_TGT'
EXPORTING
  is = ls.
commit work. " First luw includes two queues

*** second luw multiple queue  *****
CALL FUNCTION 'TRFC_SET_QIN_PROPERTIES'
  EXPORTING
    qout_name = 'OUT_QUEUE1'
    qin_name  = 'INN_QUEUE1'.
CLEAR ls.
ls-carrid = 'XX'.
ls-carrname = 'XX AIRLINE'.
CALL FUNCTION 'ZUPDATE_FLIGHT_REC'
 IN BACKGROUND TASK
 "AS SEPARATE UNIT " creates a separate luw
 DESTINATION 'SRC_TO_TGT'
EXPORTING
  is = ls.

CALL FUNCTION 'TRFC_SET_QIN_PROPERTIES'
  EXPORTING
    qout_name = 'OUT_QUEUE2'
    qin_name  = 'INN_QUEUE2'.

CLEAR ls.
ls-carrid = 'YY'.
ls-carrname = 'YY AIRLINE'.
CALL FUNCTION 'ZUPDATE_FLIGHT_REC'
 IN BACKGROUND TASK
 "AS SEPARATE UNIT " creates a separate luw
 DESTINATION 'SRC_TO_TGT'
EXPORTING
  is = ls.
COMMIT WORK. " second luw with multiple queue
WRITE :/ 'Check outbound queues in source system in Tx- SMQS'.
WRITE :/ 'Check Inbound queues in target system in Tx- SMQR'.

--------------------------------------------------------------------------------------------------------------------------------
Step2. Source system: program output.

Step3.  Source system: Tx- SMQR ( out bound scheduler) . Select the Two queues. Double click on it.

Step4.  Source system:  Double click on queue name.

Step5.  Source system:  So here some part of the each queue is added to one LUW. process the queues.

Step6. Target system: :  Tx- SMQS( In bound scheduler) . Select the two queues and double click on it.

Step7.  Target system:  Double click on it.

Step8.  Target system:  So we have two LUWS each contains some part of both queues.

Step9.  Target system:  Juts a comparison of TIDs of the source and target system.

----------------------------------------------------------------------------------------------------------------------------------------

No comments:

Comments system

Disqus Shortname