<?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: ABAP SQL in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/abap-sql/m-p/6720984#M1455431</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Actually I have a field that I should retrieve data to from different tables, so instead of making 3 or 4 queries I thought it is possible to write in my program a single query. but since this is not recommended I will try to get data from each table seperately.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 16 Mar 2010 13:29:59 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2010-03-16T13:29:59Z</dc:date>
    <item>
      <title>ABAP SQL</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/abap-sql/m-p/6720981#M1455428</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Experts,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;can anyone please help me translate an Oracle select statement into ABAP, the main problem is reading from more than 4 tables in a single select query such as:&lt;/P&gt;&lt;P&gt;select  &lt;STRONG&gt;t1&lt;/STRONG&gt;.F1, &lt;STRONG&gt;t1&lt;/STRONG&gt;.F2, &lt;STRONG&gt;t2&lt;/STRONG&gt;.F3, &lt;STRONG&gt;t3&lt;/STRONG&gt;.F4, &lt;STRONG&gt;t3&lt;/STRONG&gt;.F5&lt;/P&gt;&lt;P&gt;from &lt;U&gt;tabl1 t1&lt;/U&gt;, &lt;U&gt;table2 t2&lt;/U&gt;, &lt;U&gt;table3 t3&lt;/U&gt;, &lt;U&gt;table4 t4&lt;/U&gt;&lt;/P&gt;&lt;P&gt;where &lt;STRONG&gt;t1&lt;/STRONG&gt;.PK = &lt;STRONG&gt;t2&lt;/STRONG&gt;.FK&lt;/P&gt;&lt;P&gt;and &lt;STRONG&gt;t1&lt;/STRONG&gt;.PK = &lt;STRONG&gt;t3&lt;/STRONG&gt;.FK&lt;/P&gt;&lt;P&gt;and &lt;STRONG&gt;t1&lt;/STRONG&gt;.PK(+) = &lt;STRONG&gt;t2&lt;/STRONG&gt;.FK&lt;/P&gt;&lt;P&gt;and &lt;STRONG&gt;t3&lt;/STRONG&gt;.PK = &lt;STRONG&gt;t4&lt;/STRONG&gt;.FK&lt;/P&gt;&lt;P&gt;and &lt;U&gt;t4.F6&lt;/U&gt; = &lt;EM&gt;'VALUE'&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;where table1,2,3,4 are table names / F1,2,3,4 are table fields / &lt;SPAN __jive_emoticon_name="plus"&gt;&lt;/SPAN&gt; left outer join / and 'VALUE' is any value passed to query / FK foreign key / PK primary key&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;note that table4 is used to setup the where clase and no fields are retrieved from it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;can this be translated into ABAP query? please help&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best Regards,&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 16 Mar 2010 12:39:39 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/abap-sql/m-p/6720981#M1455428</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-03-16T12:39:39Z</dc:date>
    </item>
    <item>
      <title>Re: ABAP SQL</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/abap-sql/m-p/6720982#M1455429</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;There must a option like Bind variable in your screen. Are you running a SQL trace in ST05?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Vijay V&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 16 Mar 2010 12:45:30 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/abap-sql/m-p/6720982#M1455429</guid>
      <dc:creator>vijaymanikandan</dc:creator>
      <dc:date>2010-03-16T12:45:30Z</dc:date>
    </item>
    <item>
      <title>Re: ABAP SQL</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/abap-sql/m-p/6720983#M1455430</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;It's shoul look something like this....&lt;/P&gt;&lt;P&gt;But not recommended to much...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select t1&lt;SUB&gt;F1, t1&lt;/SUB&gt;F2, t2&lt;SUB&gt;F3, t3&lt;/SUB&gt;F4, t3~F5&lt;/P&gt;&lt;P&gt;from tabl1 as t1 left outer join  table2 as t2&lt;/P&gt;&lt;P&gt;  on t1&lt;SUB&gt;PK = t2&lt;/SUB&gt;FK&lt;/P&gt;&lt;P&gt;inner join  table3 as t3&lt;/P&gt;&lt;P&gt;  on t1&lt;SUB&gt;PK = t3&lt;/SUB&gt;FK&lt;/P&gt;&lt;P&gt;inner join  table4 as t4&lt;/P&gt;&lt;P&gt;  on t3&lt;SUB&gt;PK = t4&lt;/SUB&gt;FK&lt;/P&gt;&lt;P&gt;where  t4~F6 = 'VALUE'&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best Regards&lt;/P&gt;&lt;P&gt;Yossi Rozenberg&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 16 Mar 2010 12:48:41 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/abap-sql/m-p/6720983#M1455430</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-03-16T12:48:41Z</dc:date>
    </item>
    <item>
      <title>Re: ABAP SQL</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/abap-sql/m-p/6720984#M1455431</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Actually I have a field that I should retrieve data to from different tables, so instead of making 3 or 4 queries I thought it is possible to write in my program a single query. but since this is not recommended I will try to get data from each table seperately.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 16 Mar 2010 13:29:59 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/abap-sql/m-p/6720984#M1455431</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-03-16T13:29:59Z</dc:date>
    </item>
    <item>
      <title>Re: ABAP SQL</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/abap-sql/m-p/6720985#M1455432</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 "for all entries" or you can find a suitable Function module that can meet your requirement. I think you can write a join upto 3 tables if the requirement is there. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Vijay V&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 16 Mar 2010 13:33:27 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/abap-sql/m-p/6720985#M1455432</guid>
      <dc:creator>vijaymanikandan</dc:creator>
      <dc:date>2010-03-16T13:33:27Z</dc:date>
    </item>
    <item>
      <title>Re: ABAP SQL</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/abap-sql/m-p/6720986#M1455433</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Samir&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;As far as i know you should avoid very complex joins (4 tables it's too much and not afficient but join of 2 tables for example it's more than welcome ( based on situation of course),but you can use all kinds of other tools like for all entries for example)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best Regards&lt;/P&gt;&lt;P&gt;Yossi Rozenberg&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 16 Mar 2010 13:34:59 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/abap-sql/m-p/6720986#M1455433</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-03-16T13:34:59Z</dc:date>
    </item>
  </channel>
</rss>

