Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Error during syntax check of IDoc (outbound)

Former Member
0 Kudos

Hello,

I did an insert into idoc_data of segment E1TXTH8 (level 3 - as child of E1EDL20) and E1TXTP8 (level 4 as child of E1TXTH8).

inside user-exit ZXTRKU02.

But idoc is created with error 26 (and hierarchy is not respected! (WE05)).

Am I using the right user-exit or i miss something in the sequence while insert??

Error:

*****************************************

EDI: Syntax error in IDoc (segment cannot be identified)

Message no. E0078

Diagnosis

The segment E1TXTH8 does not occur at the current level of the basic type DELVRY03 (extension ).

This error can have several reasons:

The segment E1TXTH8 is assigned to a group whose header segment does not occur.

The segment E1TXTH8 does not exist in the syntax description of the basic type DELVRY03 (extension ).

The sequence of segments in the group in which the segment appears is incorrect.

Previous errors ('mandatory' segment or group missing) may be due to this error.

Procedure

Please check the IDoc or the syntax description of the basic type DELVRY03 (extension ).

*****************************************************

Thank you in advance for your help.

Edited by: Fakher Baklouti on Apr 9, 2010 7:12 PM

1 ACCEPTED SOLUTION

asik_shameem
Active Contributor
0 Kudos

Hello Fakher,

Put a break point in FM MASTER_IDOC_DISTRIBUTE and Check your idoc data is in the proper order of WE30->DELVRY03.

The user exit you are using is the correct one as long as your process code is DELV or the FM is IDOC_OUTPUT_DELVRY.

4 REPLIES 4

asik_shameem
Active Contributor
0 Kudos

Hello Fakher,

Put a break point in FM MASTER_IDOC_DISTRIBUTE and Check your idoc data is in the proper order of WE30->DELVRY03.

The user exit you are using is the correct one as long as your process code is DELV or the FM is IDOC_OUTPUT_DELVRY.

0 Kudos

Hello Asik,

Thank you for your answer. But, you said, the same order in idoc data than WE30? You mean, segment "E1TXTH8" must be inserted just after "E1EDT13"?? I should so parse all the idoc_data to check which segments available to respect order? What is so the proper way to insert segment?

Thank you again.

Edited by: Fakher Baklouti on Apr 12, 2010 9:30 AM

0 Kudos

Hello Faker,

It depends on the previous available segment.

Here is the procedure,

1. Get all the segments from the database table IDOCSYN where basic type is DELVRY03

2. Sort them by Sequential number in DESCENDING

3. Get the Index (say GV_INDEX) of the segment in IDOCSYN which you want to insert or edit

4. LOOP internal table of IDOCSYN from index GV_INDEX and check for the availability of the segment of IDOCSYN in idoc data

5. If it is success, break the loop and now you got the previous available segment

6. Now just insert your segment in the idoc table just after it.

0 Kudos

This was very helpfull..

Thanks a lot Asik Shameem.