Chinese (People's Republic of China)  English  Français


Supinfo-Projects.com
所有Supinfo学生项目



项目
  最新项目
  项目排行
  所有项目

93 在线访问者
3168 项目


My Supinfo-Projects

   登录
   注册


概要

   13 访问
   访问者评分 : 18.6
    (3 选举)
   27 评注

   查阅文章

评估这篇文章

20
18
16
14
12
10
8
6
4
2
0


评论这篇文章

作者 :

电子邮件 :

你的评论 :



 
2005 - Mémoire de fin d'étude
Idocs in SAP R/3
[30 mn 阅读 - 发表时间 6/13/2005 2:52:29 AM - 对象 : Expert]

作者

heng_sSeng-Houth HENG
学生-工程师 Supinfo Paris
SUPINFO毕业年届 2005

   给他/她写信
   该作者所有项目
   作者简历

2 Customizing of an outbound interface

This chapter approaches the creation of a new outbound interface entirely specific. It uses no one of the standard SAP R/3 structures.

2.1 Creation of a new message type

2.1.1 Creation of a new segment type

Launch the WE31 transaction (Development segments: Initial screen).

Fill the Segment type field with the value Z1VISTAPM then press F5 (Create).

WE31_001.JPG

Fill the Short Description field and add as much lines as wished fields in the segment. For each field, give it a name and a Data Element to refer to.

WE31_002.JPG

Save.

2.1.2 Creation of a new basic IDoc type

Launch WE30 transaction (Develop IDoc Types: Initial Screen).

Fill the Obj. name field with the value ZVISTAPM01 then press F5 (Create).

WE30_000.JPG

In the popup window which appears, choose Create new and fill the Description field.

Select the ZVISTAPM01 header line then choose the Create segment... button. In the popup window which appears, fill the fields like the following:

  • Segm.type: Z1VISTAPM
  • Mandatory seg.: [checked]
  • Minimum number: 1
  • Maximum number: 999999

WE30_001.JPG

Save.

2.1.3 Creation of a new message type

Launch the WE81 transaction (Display View "EDI: Logical Message Types": Overview).

WE81_000.JPG

Choose the Display -> Change button then the New Entries button.

In the Message type column, type the value ZVISTAPM then in the Short text column type a short description.

WE81_001.JPG

Save.

2.1.4 Association of the basic IDoc type to the message type

Launch the WE82 transaction (Display View "Output Types and Assignment to IDoc Types": Overview).

WE82_010.JPG

Choose the Display -> Change button then the New Entries button.

In the Message Type column, type the value ZVISTAPM. In the Basic Type column, type the value ZVISTAPM01. In the Release column, type the value 620.

WE82_011.JPG

2.2 Customizing of a new interface

2.2.1 Creation of a new distribution model view

Launch the BD64 transaction (Display Distribution Model).

BD64_010.JPG

Press the Switch between display and edit mode button, then the Create model view button.

In the popup window which appears, enter in the Short text field a short description and in the Technical name field the value YVISTAPM.

BD64_011.JPG

Place on the newly created entry then press the Add Message Type button.

In the popup window which appears, enter in the Sender field the name of the local logical system, in the Receiver field the name of the receiving logical system and in the Message type field the name of the message type of the interface.

BD64_012.JPG

Validate then save.

BD64_013.JPG

2.2.2 Distribute the distribution model view

This step is necessary only if the partner system is a SAP R/3 system. It allows to centralize the changes to make on the interface. Be careful! The partner profiles also have to be generated and managed in the partner system.

Select the recently created view then choose in the menu Edit / Model view / Distribute. In the popup window which appears, the partner system is already selected, there is no need to make other further selection. Validate.

2.2.3 Generate and manage the partner profiles

From the distribution model view (BD64 transaction), place on the message type then choose in the menu Environment / Generate partner profiles, or launch the BD82 transaction (Generating partner profile).

Enter in the Model view field the value YVISTAPM, in the Partner system field the value TIBCO, and choose as Output mode the Collect IDocs and transfer radio button. Press the Execute button.

BD82_000.JPG

BD82_001.JPG

Check the partner profiles. To do so, launch the WE20 transaction (Partner profiles). Select LS / TIBCO / Outbound parmtrs. / ZVISTAPM.

The port should be checked first, because it is not specified at the generation of the partner profiles level, so it is the first port which is selected by default.

If needed, manage the partner profiles then save.

WE20_011.JPG

2.3 Creation of an outbound interface program

2.3.1 Creation of an IDoc generation program

The following code extract contains everything needed to generate an IDoc from data contained in a table.

FORM F_110_SEND_IDOC.
CONSTANTS:
C_MESTYP TYPE EDIDC-MESTYP VALUE 'ZVISTAPM',
C_DOCTYP TYPE EDIDC-IDOCTP VALUE 'ZVISTAPM01',
C_SEGNAM TYPE EDIDD-SEGNAM VALUE 'Z1VISTAPM'.
DATA:
I_ZVISTA_PM TYPE ZVISTA_PM_T OCCURS 6000,
I_EDIDC TYPE EDIDC OCCURS 0,
I_EDIDD TYPE EDIDD OCCURS 0,
WA_ZVISTA_PM TYPE ZVISTA_PM_T,
WA_EDIDC TYPE EDIDC,
WA_EDIDD TYPE EDIDD,
WA_Z1VISTAPM TYPE Z1VISTAPM,
V_OCCMAX TYPE IDOCSYN-OCCMAX,
V_NBSEG TYPE I.
CLEAR WA_ZVISTA_PM.
CLEAR WA_EDIDC.
* Save the message type and the basic IDoc type
* in the control segment
MOVE C_MESTYP TO WA_EDIDC-MESTYP.
MOVE C_DOCTYP TO WA_EDIDC-IDOCTP.
* Retrieve the maximum number of segments in the basic IDoc
* type
SELECT MIN( OCCMAX )
FROM IDOCSYN
INTO V_OCCMAX
WHERE IDOCTYP EQ C_DOCTYP AND SEGTYP EQ C_SEGNAM.
* Save the whole ZVISTA_PM_T table content
* in the I_ZVISTA_PM internal table.
SELECT *
FROM ZVISTA_PM_T
INTO CORRESPONDING FIELDS OF TABLE I_ZVISTA_PM.
* Create a data segment for each line of I_ZVISTA_PM
LOOP AT I_ZVISTA_PM INTO WA_ZVISTA_PM.
MOVE-CORRESPONDING WA_ZVISTA_PM TO WA_Z1VISTAPM.
CLEAR WA_EDIDD.
MOVE C_SEGNAM TO WA_EDIDD-SEGNAM.
MOVE WA_Z1VISTAPM TO WA_EDIDD-SDATA.
APPEND WA_EDIDD TO I_EDIDD.
CLEAR WA_ZVISTA_PM.
CLEAR WA_Z1VISTAPM.
ENDLOOP.
* Count the number of data segments
DESCRIBE TABLE I_EDIDD LINES V_NBSEG.
* If the number of data segments exceeds the maximum
* allowed number, then edit a message in the spool,
* then display an error message (quit the program)
IF V_NBSEG GT V_OCCMAX.
WRITE:/ TEXT-003, V_OCCMAX.
MESSAGE E751.
ENDIF.
* Call the IDoc creation function
CALL FUNCTION 'MASTER_IDOC_DISTRIBUTE'
EXPORTING
MASTER_IDOC_CONTROL = WA_EDIDC
TABLES
COMMUNICATION_IDOC_CONTROL = I_EDIDC
MASTER_IDOC_DATA = I_EDIDD
EXCEPTIONS
ERROR_IN_IDOC_CONTROL = 1
ERROR_WRITING_IDOC_STATUS = 2
ERROR_IN_IDOC_DATA = 3
SENDING_LOGICAL_SYSTEM_UNKNOWN = 4
OTHERS = 5.
* If there was an error, display a message (quit the
* program)
IF SY-SUBRC NE 0.
MESSAGE E746.
ENDIF.
ENDFORM.

2.3.2 Running of the IDoc sending program

The interface having been customized for a collected mode output, the program created IDoc is not sent immediately to the receiving system. The IDoc stays waiting for processing. It can be viewed in the BD87 transaction (Status Monitor for ALE Messages).

BD87_010.JPG

It is possible to press the Process button to send the IDoc which waits for processing. However, if there were several IDocs to be sent in collected mode, pressing the Process button would have sent them one by one instead of sending them in a batch.

Actually, the RSEOUT00 program has to be executed with adequat parameters: Logical message set to the value ZVISTAPM and Output mode set to the value 4.

SA38_000.JPG



Articles de la même catégorie

 Pages : Top


24 访问
0 评注
Presentation du Framework .Net 2.0
[50 分钟阅读时间 - 公布时间 6/13/2005 12:07:03 AM - 对象 : Confirmé]

更多


9 访问
0 评注
Consolidation of information systems: integration of the triptych SAP/ .NET/ InfoPath
[30 分钟阅读时间 - 公布时间 6/12/2005 7:42:37 PM - 对象 : Confirmé]

更多


16 访问
0 评注
Bases de la programmation pour périphérique mobile avec la technologie Microsoft .NET
[30 分钟阅读时间 - 公布时间 6/12/2005 4:59:54 PM - 对象 : Confirmé]

更多

Powered by Campus-Booster Technology
Conditions d'utilisation & Copyright | Respect de la vie privée
© Copyright 1965-2006 Supinfo Paris, Paris Academy of Computer Science
Supinfo, Ecole Supérieure d'Informatique et Paris Academy Of Computer Science are trade marks.
23, rue de Château LANDON - 75010 PARIS - Phone : +33 (0) 153359 700 Fax : +33 (0) 153359 701

Web site autided by :