<?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: Help with SQL statement using structures in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-sql-statement-using-structures/m-p/12650204#M2014990</link>
    <description>&lt;P&gt;I don't understand. Better provide an example with input data, expected output, and the rules in plain words.&lt;/P&gt;</description>
    <pubDate>Wed, 08 Feb 2023 16:06:15 GMT</pubDate>
    <dc:creator>Sandra_Rossi</dc:creator>
    <dc:date>2023-02-08T16:06:15Z</dc:date>
    <item>
      <title>Help with SQL statement using structures</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-sql-statement-using-structures/m-p/12650203#M2014989</link>
      <description>&lt;P&gt;Hi, I have a local table named&lt;STRONG&gt; t_test&lt;/STRONG&gt; that contains a field IDNRK and here are the values:&lt;/P&gt;
  &lt;P&gt;000000000001019917&lt;/P&gt;
  &lt;P&gt;000000000001020057&lt;/P&gt;
  &lt;P&gt;000000000001345359&lt;/P&gt;
  &lt;P&gt;I was trying to select data from AUSP using the values above. However, I was only able to use 1 as I'm not familiar on how to loop a table into a structure:&lt;/P&gt;
  &lt;PRE&gt;&lt;CODE&gt;      SELECT objek,&lt;BR /&gt;             atwrt&lt;BR /&gt;        INTO TABLE @DATA(t_itemcat)&lt;BR /&gt;        FROM ausp&lt;BR /&gt;        WHERE objek = @x_test-idnrk&lt;BR /&gt;        AND atinn = '1234'.&lt;/CODE&gt;&lt;/PRE&gt;
  &lt;P&gt;X_TEST-IDNRK comes from T_TEST which has a code:&lt;/P&gt;
  &lt;PRE&gt;&lt;CODE&gt;      LOOP AT t_stbdata INTO DATA(x_stb)&lt;BR /&gt;      "SOMETHING HERE&lt;BR /&gt;      ENDLOOP.&lt;/CODE&gt;&lt;/PRE&gt;
  &lt;P&gt;IF I WANT TO USE ALL THE T_ITEMCAT IN X_ITEMCAT should I also use LOOP AT? &lt;/P&gt;
  &lt;PRE&gt;&lt;CODE&gt;      LOOP AT t_itemcat INTO DATA(x_itemcat).&lt;BR /&gt;      ENDLOOP.&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Wed, 08 Feb 2023 15:13:19 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-sql-statement-using-structures/m-p/12650203#M2014989</guid>
      <dc:creator>walkerist79</dc:creator>
      <dc:date>2023-02-08T15:13:19Z</dc:date>
    </item>
    <item>
      <title>Re: Help with SQL statement using structures</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-sql-statement-using-structures/m-p/12650204#M2014990</link>
      <description>&lt;P&gt;I don't understand. Better provide an example with input data, expected output, and the rules in plain words.&lt;/P&gt;</description>
      <pubDate>Wed, 08 Feb 2023 16:06:15 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-sql-statement-using-structures/m-p/12650204#M2014990</guid>
      <dc:creator>Sandra_Rossi</dc:creator>
      <dc:date>2023-02-08T16:06:15Z</dc:date>
    </item>
  </channel>
</rss>

