<?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: sql select in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/sql-select/m-p/2956009#M697281</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You cannot use offsets or substrings in a select.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You may have to load the data in an internal table and then loop at the table to do the comparison, where offset and substrings would be allowed.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you do, just make sure that itab2 can accomodate both pallet_id fields.   You may have to do explicit mapping of fields into i_tab2 in such a case, since one of the pallet fields will have to have a different name, so CORRESPONDING FIELDS won't work.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Good luck&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Brian&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 10 Oct 2007 22:41:44 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-10-10T22:41:44Z</dc:date>
    <item>
      <title>sql select</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/sql-select/m-p/2956008#M697280</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;See the sql below... I would like to make the comparison&lt;/P&gt;&lt;P&gt; t1&lt;SUB&gt;pallet_id = t2&lt;/SUB&gt;pallet_id+2(18)  but it is not possible. Any help?&lt;/P&gt;&lt;P&gt;SELECT *&lt;/P&gt;&lt;P&gt;    INTO CORRESPONDING FIELDS OF TABLE i_tab2&lt;/P&gt;&lt;P&gt;    FROM  t1&lt;/P&gt;&lt;P&gt;    INNER JOIN t2&lt;/P&gt;&lt;P&gt;    ON t1&lt;SUB&gt;pallet_id = t2&lt;/SUB&gt;pallet_id&lt;/P&gt;&lt;P&gt;    FOR ALL entries IN i_tab&lt;/P&gt;&lt;P&gt;    WHERE t2~vbeln = i_tab-vbeln.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 10 Oct 2007 22:25:52 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/sql-select/m-p/2956008#M697280</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-10-10T22:25:52Z</dc:date>
    </item>
    <item>
      <title>Re: sql select</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/sql-select/m-p/2956009#M697281</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You cannot use offsets or substrings in a select.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You may have to load the data in an internal table and then loop at the table to do the comparison, where offset and substrings would be allowed.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you do, just make sure that itab2 can accomodate both pallet_id fields.   You may have to do explicit mapping of fields into i_tab2 in such a case, since one of the pallet fields will have to have a different name, so CORRESPONDING FIELDS won't work.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Good luck&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Brian&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 10 Oct 2007 22:41:44 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/sql-select/m-p/2956009#M697281</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-10-10T22:41:44Z</dc:date>
    </item>
    <item>
      <title>Re: sql select</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/sql-select/m-p/2956010#M697282</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Please avoid inner join &lt;/P&gt;&lt;P&gt;First select data from one table and then use that for other in For ALL Entries&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT * &lt;/P&gt;&lt;P&gt;FROM T1&lt;/P&gt;&lt;P&gt;WHERE .........conditions&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Temerory table TEMP with field TMP_ID&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOOP AT T1 &lt;/P&gt;&lt;P&gt;TEMP-TMP_ID = T1+2(18)&lt;/P&gt;&lt;P&gt;APPEND TEMP.&lt;/P&gt;&lt;P&gt;ENDLOOP&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT * &lt;/P&gt;&lt;P&gt;FROM T2&lt;/P&gt;&lt;P&gt;FOR ALL ENTERIS IN TEMP&lt;/P&gt;&lt;P&gt;WHERE ID = TEMP-TEP_ID&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rewards if useful.......................&lt;/P&gt;&lt;P&gt;Minal&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 11 Oct 2007 03:26:44 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/sql-select/m-p/2956010#M697282</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-10-11T03:26:44Z</dc:date>
    </item>
    <item>
      <title>Re: sql select</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/sql-select/m-p/2956011#M697283</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;OK&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 11 Oct 2007 15:55:10 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/sql-select/m-p/2956011#M697283</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-10-11T15:55:10Z</dc:date>
    </item>
  </channel>
</rss>

