<?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 Re: Internal table problem for BDC in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem-for-bdc/m-p/6707754#M1453320</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you for your answers&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: Prabu S on Mar 8, 2010 6:51 AM&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 08 Mar 2010 05:50:53 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2010-03-08T05:50:53Z</dc:date>
    <item>
      <title>Internal table problem for BDC</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem-for-bdc/m-p/6707749#M1453315</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hai i am having flatfile like this format&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;H   text1   1000   plant_name   10 short_text   X     X&lt;/P&gt;&lt;P&gt;                                                 20 short_text   X     X&lt;/P&gt;&lt;P&gt;                                                 30 short_text   X     X&lt;/P&gt;&lt;P&gt;H   text1   1000   plant_name   10 short_text   X     X&lt;/P&gt;&lt;P&gt;                                                 20 short_text   X     X&lt;/P&gt;&lt;P&gt;                                                 30 short_text   X     X&lt;/P&gt;&lt;P&gt;   &lt;/P&gt;&lt;P&gt;now this H indicates new record. In each new record number of line items are there.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;How to proceed using internal tables. please help me.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Mar 2010 07:39:14 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem-for-bdc/m-p/6707749#M1453315</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-03-04T07:39:14Z</dc:date>
    </item>
    <item>
      <title>Re: Internal table problem for BDC</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem-for-bdc/m-p/6707750#M1453316</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 to use EXTRACT data set , as in that u can use different structure in a single table. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;[http://help.sap.com/saphelp_nw70ehp1/helpdata/en/9f/db9ed135c111d1829f0000e829fbfe/content.htm] &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;lemme know the BDC code which u are using in case of confusion...&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Mar 2010 07:51:48 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem-for-bdc/m-p/6707750#M1453316</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-03-04T07:51:48Z</dc:date>
    </item>
    <item>
      <title>Re: Internal table problem for BDC</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem-for-bdc/m-p/6707751#M1453317</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;arrange your flat file like this...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;H    text1 1000  plant_name  10  short_text X X&lt;/P&gt;&lt;P&gt;H    text1 1000  plant_name  20 short_text  X X&lt;/P&gt;&lt;P&gt;H    text1 1000  plant_name  30 short_text  X X&lt;/P&gt;&lt;P&gt;H1  text1 1000  plant_name  10 short_text  X X&lt;/P&gt;&lt;P&gt;H1  text1 1000  plant_name  20 short_text  X X&lt;/P&gt;&lt;P&gt;H1  text1 1000  plant_name  30 short_text  X X&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;now make an internal table having all the fields present in your flat file&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;and loop at that internal table and on change of field H call your function module and pass the value for record H......&lt;/P&gt;&lt;P&gt;similarly it will work for H1.....H2.....&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;for eg...&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
LOOP AT "Your internal table" INTO "Work area of your internal table".
    
    AT END OF "field name for H".
      CALL FUNCTION ''Your function module"
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Mar 2010 07:58:06 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem-for-bdc/m-p/6707751#M1453317</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-03-04T07:58:06Z</dc:date>
    </item>
    <item>
      <title>Re: Internal table problem for BDC</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem-for-bdc/m-p/6707752#M1453318</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;Use the Control Break statments for your requirements.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you want make one record per line, the record which is start with H you can separate the below way.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOOP &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;AT END OF H ( H - The new record start with H)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;use the move statement to make one record per line.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ENDAT.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ENDLOOP.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Mar 2010 08:02:03 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem-for-bdc/m-p/6707752#M1453318</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-03-04T08:02:03Z</dc:date>
    </item>
    <item>
      <title>Re: Internal table problem for BDC</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem-for-bdc/m-p/6707753#M1453319</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Try splitting your flat file data into 2 separate internal tables. One will hold the header data and one will hold the line item data. Both the internal tables would be linked with a set of common columns to identify the set of line item data related to the header data.&lt;/P&gt;&lt;P&gt;Suppose you have created 2 internal tables say int_h and int_i  (for header and line items respectively).&lt;/P&gt;&lt;P&gt;loop across the header table and run your BDC. As soon as you reach the screen where line item data is used, run another loop in the line item table with the where condition on the common fields from header table and continue with your BDC. Save data before next header data starts. Check the following pseudo code&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
loop at int_h into wa_h.
perform BDC for header data.
loop at int_i into wa_i where f1 = wa_h-f1 "assuming f1 is the linking field 
perform BDC for line items.
endloop.
perform save
endloop.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this helps.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Sachin&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Mar 2010 08:04:44 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem-for-bdc/m-p/6707753#M1453319</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-03-04T08:04:44Z</dc:date>
    </item>
    <item>
      <title>Re: Internal table problem for BDC</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem-for-bdc/m-p/6707754#M1453320</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you for your answers&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: Prabu S on Mar 8, 2010 6:51 AM&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 08 Mar 2010 05:50:53 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem-for-bdc/m-p/6707754#M1453320</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-03-08T05:50:53Z</dc:date>
    </item>
  </channel>
</rss>

