Skip to Content
author's profile photo Former Member
Former Member

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

Hi ,

I created a basic type 'ZWXWIDOCTYPE' with 2 Segment type: 'ZWXWIDOC2' and 'ZWXWIDOC' .

When i run my program to create idoc files , it gives me an error (see with tcode we02 ),

here is the error text :

________________________begin of text ____________________________________

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

Message no. E0078

Diagnosis

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

This error can have several reasons:

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

The segment ZWXWIDOC2 does not exist in the syntax description of the basic type ZWXWIDOCTYPE (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 ZWXWIDOCTYPE (extension ).

_____________________end of text _______________________________________

Here is some of my program :

____________________ begin of program _________________________________

control_dat-mestyp = 'ZWXWIDOCMSG'.

control_dat-idoctp = 'ZWXWIDOCTYPE'.

control_dat-rcvprt = 'LS'.

control_dat-rcvprn = p_logsys.

gen_segment = 'ZWXWIDOC'.

select * into corresponding fields of gen_data

from ekko where ebeln = ebeln .

int_edidd-segnam = gen_segment.

int_edidd-sdata = gen_data.

append int_edidd.

endselect.

gen_segment = 'ZWXWIDOC2'.

select * into corresponding fields of gen_data2

from ekpo where ebeln = ebeln .

int_edidd-segnam = gen_segment.

int_edidd-sdata = gen_data2.

append int_edidd.

endselect.

____________________end of program _________________________________

Anyone can help me ?

Thanks a lot .

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

1 Answer

  • Best Answer
    author's profile photo Former Member
    Former Member
    Posted on Jul 03, 2007 at 10:04 AM

    Hi,

    after adding those segments you need to release it.

    check it menu you can see the release option, you need to release it.

    then only it will work

    refer the link

    https://forums.sdn.sap.com/click.jspa?searchID=3611132&messageID=1232098

    <b>Reward points</b>

    Regards

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.