<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic How to create Inbound Idocs in a ABAP program? Any function Module? in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-create-inbound-idocs-in-a-abap-program-any-function-module/m-p/5552617#M1267564</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Experts,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My requirement is : I have sales order data which I extracted from third party system in my internal tables. In the same box I need to create inbound Idocs and then consequently create sales orders. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have used the function module &lt;STRONG&gt;IDOC_INBOUND_WRITE_TO_DB&lt;/STRONG&gt; to create inbound Idocs from Sales Orders data in internal tables. I have populated all the data records with correct &lt;STRONG&gt;PSGNUM&lt;/STRONG&gt; and &lt;STRONG&gt;HLEVEL&lt;/STRONG&gt; values. My plan is to create inbound idocs with this function module and send those to &lt;STRONG&gt;IDOC_INPUT_ORDERS&lt;/STRONG&gt; function module which creates Sales Orders. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If a sales order in the internal table in ABAP program contains only one item, then I am getting correct idocs. But if more than one item exists for a sales order then the line item segments which got repeated in Idoc are having PSGNUM and HLEVEL values as zero when I checked in WE02. As a result the hierarchy from the second item segment is getting disturbed and getting the status 60.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I populated T_EDIDD with data records from  IDOC_INBOUND_WRITE_TO_DB.&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;To the function module &lt;STRONG&gt;IDOC_INPUT_ORDERS&lt;/STRONG&gt;,  T_EDIDC and T_EDIDD are the input. I observed that in T_EDIDD also the PSGNUM and HLEVEL values are blank.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am getting Status 60 with message &lt;STRONG&gt;'EDI: Syntax error in IDoc (segment cannot be identified)&lt;/STRONG&gt;' for idocs which have more than one item.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I need to extract sales data from third party and create inbound idocs and create sales orders in one ABAP program only. I need to display corresponding Idoc numbers for the corresponding third party sales order number in a listoutput.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can anybody please provide inputs?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 27 Apr 2009 17:12:29 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2009-04-27T17:12:29Z</dc:date>
    <item>
      <title>How to create Inbound Idocs in a ABAP program? Any function Module?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-create-inbound-idocs-in-a-abap-program-any-function-module/m-p/5552617#M1267564</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Experts,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My requirement is : I have sales order data which I extracted from third party system in my internal tables. In the same box I need to create inbound Idocs and then consequently create sales orders. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have used the function module &lt;STRONG&gt;IDOC_INBOUND_WRITE_TO_DB&lt;/STRONG&gt; to create inbound Idocs from Sales Orders data in internal tables. I have populated all the data records with correct &lt;STRONG&gt;PSGNUM&lt;/STRONG&gt; and &lt;STRONG&gt;HLEVEL&lt;/STRONG&gt; values. My plan is to create inbound idocs with this function module and send those to &lt;STRONG&gt;IDOC_INPUT_ORDERS&lt;/STRONG&gt; function module which creates Sales Orders. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If a sales order in the internal table in ABAP program contains only one item, then I am getting correct idocs. But if more than one item exists for a sales order then the line item segments which got repeated in Idoc are having PSGNUM and HLEVEL values as zero when I checked in WE02. As a result the hierarchy from the second item segment is getting disturbed and getting the status 60.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I populated T_EDIDD with data records from  IDOC_INBOUND_WRITE_TO_DB.&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;To the function module &lt;STRONG&gt;IDOC_INPUT_ORDERS&lt;/STRONG&gt;,  T_EDIDC and T_EDIDD are the input. I observed that in T_EDIDD also the PSGNUM and HLEVEL values are blank.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am getting Status 60 with message &lt;STRONG&gt;'EDI: Syntax error in IDoc (segment cannot be identified)&lt;/STRONG&gt;' for idocs which have more than one item.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I need to extract sales data from third party and create inbound idocs and create sales orders in one ABAP program only. I need to display corresponding Idoc numbers for the corresponding third party sales order number in a listoutput.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can anybody please provide inputs?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 27 Apr 2009 17:12:29 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-create-inbound-idocs-in-a-abap-program-any-function-module/m-p/5552617#M1267564</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-04-27T17:12:29Z</dc:date>
    </item>
    <item>
      <title>Re: How to create Inbound Idocs in a ABAP program? Any function Module?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-create-inbound-idocs-in-a-abap-program-any-function-module/m-p/5552618#M1267565</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;to proces inobund idoc..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;60    Error during syntax check of IDoc (inbound)                 &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;so find go to user exit or program and correct the syntax and process the below inbound program to create idoc..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
Program RBDAPP01 for status 64
Program RBDAGAIE for status 32 and 60 (Edited IDocs)
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;Prabhudas&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 27 Apr 2009 17:15:46 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-create-inbound-idocs-in-a-abap-program-any-function-module/m-p/5552618#M1267565</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-04-27T17:15:46Z</dc:date>
    </item>
    <item>
      <title>Re: How to create Inbound Idocs in a ABAP program? Any function Module?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-create-inbound-idocs-in-a-abap-program-any-function-module/m-p/5552619#M1267566</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Prabhudas,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thankyou for your reply.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But I have to create Inbound Idocs from the ABAP progam first. That is failing as a result of disturbed hierarchy level (HLEVEL) and PSGNUM values.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;HLEVEL and PSGNUM are having zeroes from the second line item segment. They are having correct values up to first line item for the same Idoc.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 27 Apr 2009 17:19:05 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-create-inbound-idocs-in-a-abap-program-any-function-module/m-p/5552619#M1267566</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-04-27T17:19:05Z</dc:date>
    </item>
    <item>
      <title>Re: How to create Inbound Idocs in a ABAP program? Any function Module?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-create-inbound-idocs-in-a-abap-program-any-function-module/m-p/5552620#M1267567</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi &lt;/P&gt;&lt;P&gt;Try getting the value of the segment number and hierarcy fro the idoc itself and recreate it in the ABAP program.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am doing a similar one where i use the function module and get the data from what is input input in the idoc.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Display the data  for a succesful idoc and get the 2 values from the display and then put that into the ABAP program.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 28 Apr 2009 06:19:53 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-create-inbound-idocs-in-a-abap-program-any-function-module/m-p/5552620#M1267567</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-04-28T06:19:53Z</dc:date>
    </item>
    <item>
      <title>Re: How to create Inbound Idocs in a ABAP program? Any function Module?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-create-inbound-idocs-in-a-abap-program-any-function-module/m-p/5552621#M1267568</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Anjali,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; Thanks for the response.&lt;/P&gt;&lt;P&gt;.&lt;/P&gt;&lt;P&gt;I have passed the PSGNUM and HLEVEL values while populating the data records. Then I sent the data records and control record information to the function module IDOC_INBOUND_WRITE_TO_DB. Inside this function module there is code to clear the PSGNUM values and HLEVEL values.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;for compatibility: clear administration data of data records&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;           perform data_records_wipe&lt;/P&gt;&lt;P&gt;                                  tables&lt;/P&gt;&lt;P&gt;                                      t_data_records.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FORM DATA_RECORDS_WIPE&lt;/P&gt;&lt;P&gt;                  TABLES&lt;/P&gt;&lt;P&gt;                      T_DATA_RECORDS_IN  STRUCTURE EDIDD.&lt;/P&gt;&lt;P&gt;  LOOP AT  T_DATA_RECORDS_IN.&lt;/P&gt;&lt;P&gt;    CLEAR: T_DATA_RECORDS_IN-MANDT,&lt;/P&gt;&lt;P&gt;           T_DATA_RECORDS_IN-DOCNUM,&lt;/P&gt;&lt;P&gt;           T_DATA_RECORDS_IN-SEGNUM,&lt;/P&gt;&lt;P&gt;           T_DATA_RECORDS_IN-PSGNUM,&lt;/P&gt;&lt;P&gt;           T_DATA_RECORDS_IN-HLEVEL.&lt;/P&gt;&lt;P&gt;    modify t_data_records_in.&lt;/P&gt;&lt;P&gt;  ENDLOOP.&lt;/P&gt;&lt;P&gt;ENDFORM.                               " DATA_RECORDS_WIPE&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This is the code which is clearing all the PSGNUM and HLEVEL values. After coming out of this function module we are getting the error idocs created with disturbed hierarchy. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I need to create INBOUND Idocs with the data in ABAP program.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please let me know if any inputs? Is there any function module existing to create Inbound Idocs inside an ABAP program?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 28 Apr 2009 16:04:20 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-create-inbound-idocs-in-a-abap-program-any-function-module/m-p/5552621#M1267568</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-04-28T16:04:20Z</dc:date>
    </item>
    <item>
      <title>Re: How to create Inbound Idocs in a ABAP program? Any function Module?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-create-inbound-idocs-in-a-abap-program-any-function-module/m-p/5552622#M1267569</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Can anybody provide their valuable inputs?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 29 Apr 2009 07:42:31 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-create-inbound-idocs-in-a-abap-program-any-function-module/m-p/5552622#M1267569</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-04-29T07:42:31Z</dc:date>
    </item>
    <item>
      <title>Re: How to create Inbound Idocs in a ABAP program? Any function Module?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-create-inbound-idocs-in-a-abap-program-any-function-module/m-p/5552623#M1267570</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi , &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can use FM IDOC_INBOUND_SINGLE to create inbound Idocs. Mention Idoc type and message type in the control record.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Deepthi&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 29 Apr 2009 11:38:10 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-create-inbound-idocs-in-a-abap-program-any-function-module/m-p/5552623#M1267570</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-04-29T11:38:10Z</dc:date>
    </item>
    <item>
      <title>Re: How to create Inbound Idocs in a ABAP program? Any function Module?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-create-inbound-idocs-in-a-abap-program-any-function-module/m-p/5552624#M1267571</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Deepthi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thankyou for your reply.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have made use of that function module also. But no use. IDOC_INBOUND_SINGLE again calls the function module IDOC_INBOUND_WRITE_TO_DB inside.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is there any other way?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;REgards.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 29 Apr 2009 16:30:34 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-create-inbound-idocs-in-a-abap-program-any-function-module/m-p/5552624#M1267571</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-04-29T16:30:34Z</dc:date>
    </item>
    <item>
      <title>Re: How to create Inbound Idocs in a ABAP program? Any function Module?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-create-inbound-idocs-in-a-abap-program-any-function-module/m-p/5552625#M1267572</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  Check this sample program.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://www.sdn.sap.com/irj/sdn/wiki?path=?path=/display/SCM/SCM%2bInbound%2bIdoc%2bProgram" target="test_blank"&gt;https://www.sdn.sap.com/irj/sdn/wiki?path=?path=/display/SCM/SCM%2bInbound%2bIdoc%2bProgram&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It is in the SCM Code Gallery&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;cheers&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Aveek&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 29 Apr 2009 16:57:54 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-create-inbound-idocs-in-a-abap-program-any-function-module/m-p/5552625#M1267572</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-04-29T16:57:54Z</dc:date>
    </item>
    <item>
      <title>Re: How to create Inbound Idocs in a ABAP program? Any function Module?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-create-inbound-idocs-in-a-abap-program-any-function-module/m-p/5552626#M1267573</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;  You can also refer to the program:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://www.sdn.sap.com/irj/sdn/wiki?path=?path=/display/ABAP/File%2bto%2bInbound%2bIdoc%2bProgram" target="test_blank"&gt;https://www.sdn.sap.com/irj/sdn/wiki?path=?path=/display/ABAP/File%2bto%2bInbound%2bIdoc%2bProgram&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;cheers&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Aveek&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 30 Apr 2009 01:17:19 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-create-inbound-idocs-in-a-abap-program-any-function-module/m-p/5552626#M1267573</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-04-30T01:17:19Z</dc:date>
    </item>
  </channel>
</rss>

