<?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: Read tables inside Internal table at Runtime in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/read-tables-inside-internal-table-at-runtime/m-p/2362213#M522648</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;Do you know the field of every table in which the material number is located?&lt;/P&gt;&lt;P&gt;If so you can do like this (assuming the field is MATNR)&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
LOOP AT t_internal.
SELECT SINGLE FROM (t_internal-table)
  INTO &amp;lt;wherever&amp;gt;
  WHERE MATNR EQ searched_matnr.
ENDLOOP.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;If the field is different for every table u can use&lt;/P&gt;&lt;P&gt;CONCATENATE t_internal-field 'EQ' searched_matnr&lt;/P&gt;&lt;P&gt; INTO where_clause SEPARATED BY SPACE.&lt;/P&gt;&lt;P&gt; and call the SELECT statement with a dynamic where clause&lt;/P&gt;&lt;P&gt;WHERE (where_clause).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Timo&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 01 Jun 2007 07:56:07 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-06-01T07:56:07Z</dc:date>
    <item>
      <title>Read tables inside Internal table at Runtime</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/read-tables-inside-internal-table-at-runtime/m-p/2362212#M522647</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Guys!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have an internal table which holds many table at runtime. The table names are coming from table TMC1T. so the structure of the internal table is :&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Language Table                            Short text&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;E        KOTI001                          Material&lt;/P&gt;&lt;P&gt;E       KOTI002              .............................................&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now at runtime, i am getting these tables into the internal table. I need to get inside each KOTI001 ,KOTI002 tables and search for a material number. Hw can i do that? Is there a function module to get the data for these tables inside the Itab for dynamically reading them?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please let me know. Its Urgent....Useful answers will be rewarded!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;San&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 01 Jun 2007 05:47:35 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/read-tables-inside-internal-table-at-runtime/m-p/2362212#M522647</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-06-01T05:47:35Z</dc:date>
    </item>
    <item>
      <title>Re: Read tables inside Internal table at Runtime</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/read-tables-inside-internal-table-at-runtime/m-p/2362213#M522648</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;Do you know the field of every table in which the material number is located?&lt;/P&gt;&lt;P&gt;If so you can do like this (assuming the field is MATNR)&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
LOOP AT t_internal.
SELECT SINGLE FROM (t_internal-table)
  INTO &amp;lt;wherever&amp;gt;
  WHERE MATNR EQ searched_matnr.
ENDLOOP.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;If the field is different for every table u can use&lt;/P&gt;&lt;P&gt;CONCATENATE t_internal-field 'EQ' searched_matnr&lt;/P&gt;&lt;P&gt; INTO where_clause SEPARATED BY SPACE.&lt;/P&gt;&lt;P&gt; and call the SELECT statement with a dynamic where clause&lt;/P&gt;&lt;P&gt;WHERE (where_clause).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Timo&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 01 Jun 2007 07:56:07 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/read-tables-inside-internal-table-at-runtime/m-p/2362213#M522648</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-06-01T07:56:07Z</dc:date>
    </item>
  </channel>
</rss>

