<?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 with header line in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-with-header-line/m-p/3049750#M722027</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;Declare your internal table as below :&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;tables: spfli.

types: begin of it_line,
carrid type s_carrid,
connid type s_conn_id,
end of it_line.

data : it_tt type like it_line occurs 0 with header line.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Sriram Ponna.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sat, 03 Nov 2007 16:59:27 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-11-03T16:59:27Z</dc:date>
    <item>
      <title>internal table with header line</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-with-header-line/m-p/3049745#M722022</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;What is worng with this code. it's giving error internal table with no header line&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;tables: spfli.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;types: begin of it_line,&lt;/P&gt;&lt;P&gt;       carrid type s_carrid,&lt;/P&gt;&lt;P&gt;       connid type s_conn_id,&lt;/P&gt;&lt;P&gt;       end of it_line.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;types: it_tt type standard table of it_line  with default key.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data: it type it_line.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; select * from spfli into  corresponding fields of table it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; loop at it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; write it-carrid, it-connid.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; endloop.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 03 Nov 2007 12:06:33 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-with-header-line/m-p/3049745#M722022</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-11-03T12:06:33Z</dc:date>
    </item>
    <item>
      <title>Re: internal table with header line</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-with-header-line/m-p/3049746#M722023</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Replace the "data: it type it_line."&lt;/P&gt;&lt;P&gt;With&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data : it like it_line occurs 0 with header line.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 03 Nov 2007 12:10:53 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-with-header-line/m-p/3049746#M722023</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-11-03T12:10:53Z</dc:date>
    </item>
    <item>
      <title>Re: internal table with header line</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-with-header-line/m-p/3049747#M722024</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;use this code it wil b helpful&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;REPORT zmftest2.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;tables: spfli.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;types: begin of it_line,&lt;/P&gt;&lt;P&gt;carrid type s_carrid,&lt;/P&gt;&lt;P&gt;connid type s_conn_id,&lt;/P&gt;&lt;P&gt;end of it_line.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;types: it_tt type standard table of it_line with default key initial size 0.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data: it type it_tt with header line.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select carrid from spfli into table it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;loop at it.&lt;/P&gt;&lt;P&gt;  write: it-carrid.&lt;/P&gt;&lt;P&gt;endloop.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 03 Nov 2007 12:15:31 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-with-header-line/m-p/3049747#M722024</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-11-03T12:15:31Z</dc:date>
    </item>
    <item>
      <title>Re: internal table with header line</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-with-header-line/m-p/3049748#M722025</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks, your answers are helpful. but could you please clarfy few more doubts in this program.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1. what is the difference between occurs and intial size.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;2.what is the need of header line as we have line type&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;3. what are the different ways to define it with header line&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;points for sure&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 03 Nov 2007 12:22:57 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-with-header-line/m-p/3049748#M722025</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-11-03T12:22:57Z</dc:date>
    </item>
    <item>
      <title>Re: internal table with header line</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-with-header-line/m-p/3049749#M722026</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Ajay,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here some examples on iternal table declarations..&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
REPORT  ZTYPES                                                  .

* Table declaration (old method)
DATA: BEGIN OF tab_ekpo OCCURS 0,             "itab with header line
  ebeln TYPE ekpo-ebeln,
  ebelp TYPE ekpo-ebelp,
 END OF tab_ekpo.

*Table declaration (new method)     "USE THIS WAY!!!
TYPES: BEGIN OF t_ekpo,
  ebeln TYPE ekpo-ebeln,
  ebelp TYPE ekpo-ebelp,
 END OF t_ekpo.
DATA: it_ekpo TYPE STANDARD TABLE OF t_ekpo INITIAL SIZE 0,      "itab
      wa_ekpo TYPE t_ekpo.                    "work area (header line)

* Build internal table and work area from existing internal table
DATA: it_datatab LIKE tab_ekpo OCCURS 0,      "old method
      wa_datatab LIKE LINE OF tab_ekpo.

* Build internal table and work area from existing internal table,
* adding additional fields
TYPES: BEGIN OF t_repdata.
        INCLUDE STRUCTURE tab_ekpo.  "could include EKKO table itself!!
TYPES: bukrs  TYPE ekpo-werks,
       bstyp  TYPE ekpo-bukrs.
TYPES: END OF t_repdata.
DATA: it_repdata TYPE STANDARD TABLE OF t_repdata INITIAL SIZE 0,   "itab
      wa_repdata TYPE t_repdata.                 "work area (header line)

&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 03 Nov 2007 12:31:42 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-with-header-line/m-p/3049749#M722026</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-11-03T12:31:42Z</dc:date>
    </item>
    <item>
      <title>Re: internal table with header line</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-with-header-line/m-p/3049750#M722027</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;Declare your internal table as below :&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;tables: spfli.

types: begin of it_line,
carrid type s_carrid,
connid type s_conn_id,
end of it_line.

data : it_tt type like it_line occurs 0 with header line.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Sriram Ponna.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 03 Nov 2007 16:59:27 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-with-header-line/m-p/3049750#M722027</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-11-03T16:59:27Z</dc:date>
    </item>
    <item>
      <title>Re: internal table with header line</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-with-header-line/m-p/3049751#M722028</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;tables: spfli.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;types: begin of it_line,&lt;/P&gt;&lt;P&gt;carrid type s_carrid,&lt;/P&gt;&lt;P&gt;connid type s_conn_id,&lt;/P&gt;&lt;P&gt;end of it_line.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;types: it_tt type standard table of it_line with default key.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data: it type it_line.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select * from spfli into corresponding fields of table &amp;lt;b&amp;gt;it_tt.&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;loop at &amp;lt;b&amp;gt;it_tt into it&amp;lt;/b&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;write it-carrid, it-connid.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;endloop.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 03 Nov 2007 19:29:48 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-with-header-line/m-p/3049751#M722028</guid>
      <dc:creator>rainer_hbenthal</dc:creator>
      <dc:date>2007-11-03T19:29:48Z</dc:date>
    </item>
    <item>
      <title>Re: internal table with header line</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-with-header-line/m-p/3049752#M722029</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;tables: spfli.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;types: begin of it_line,&lt;/P&gt;&lt;P&gt;carrid type s_carrid,&lt;/P&gt;&lt;P&gt;connid type s_conn_id,&lt;/P&gt;&lt;P&gt;end of it_line.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;types: it_tt type standard table of it_line with default key.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data: it type it_line  &amp;lt;b&amp;gt;occurs 0 with header line. " this you want to correct&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select * from spfli into corresponding fields of table it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;loop at it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;write it-carrid, it-connid.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;endloop.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 03 Nov 2007 20:59:45 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-with-header-line/m-p/3049752#M722029</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-11-03T20:59:45Z</dc:date>
    </item>
  </channel>
</rss>

