IT干货网

ABAP-QRFC

shasha 2022年03月09日 SAP 189 0

IT虾米网

1.QRFC DEMO:

RSTRFCT0

RSTRFCT1

RSTRFCQ4

2. qRFC with Outbound Queue

 1 REPORT rstrfct0. 
 2 ... 
 3  
 4 CALL FUNCTION ‘TRFC_SET_QUEUE_NAME’. 
 5  
 6   EXPORTING 
 7  
 8     QNAME                           = ‘queue1’ 
 9  
10 *   NOSEND                        = ' ' 
11  
12 *   TRFC_IF_SYSFAIL           = ' ' 
13  
14 *   CALL_EVENT                  = ' ' 
15  
16 *   EXCEPTIONS 
17  
18 *   INVALID_QUEUE_NAME   = 1 
19  
20 *   OTHERS                         = 2 
21  
22 . 
23  
24 CALL FUNCTION ’rfc_function’ 
25  
26  DESTINATION rfcdest 
27  
28  IN BACKGROUND TASK 
29  
30  ( AS SEPARATE UNIT ) 
31  
32  EXPORTING ... 
33  
34  TABLES ... 
35 ... 
36  
37 COMMIT WORK.    

SMQS:Register destination

3. qRFC with Inbound QueueREPORT rstrfct5....

CALL FUNCTION 'TRFC_SET_QIN_PROPERTIES' 
 
  EXPORTING 
 
*   QOUT_NAME                 = ' ' 
 
    QIN_NAME                    = 
 
*   CALL_EVENT                 = ' ' 
 
*   NO_EXECUTE                = ' ' 
 
* EXCEPTIONS 
 
*   INVALID_QUEUE_NAME  = 1 
 
*   OTHERS                         = 2 
 
. 
 
CALL FUNCTION ’rfc_function’ 
IN BACKGROUND TASK
( AS SEPARATE UNIT ) EXPORTING ... TABLES ... ... COMMIT WORK.

Table : TRFCQIN , TRFCQSTATE  ,TRFCQDATA.

SMQR:  Register queue name

IN BACKGROUND TASK

评论关闭
IT干货网

微信公众号号:IT虾米 (左侧二维码扫一扫)欢迎添加!