<?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 statement in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/abap-statement/m-p/2277604#M495518</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi jeff,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Just change the query given by Seshu as below.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;tables : REGUH,&lt;/P&gt;&lt;P&gt;PAYR .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data : begin of itab occurs 0,&lt;/P&gt;&lt;P&gt;zbukr like reguh-zbukr,&lt;/P&gt;&lt;P&gt;hbkid like reguh-hbkid,&lt;/P&gt;&lt;P&gt;hktid like reguh-hktid,&lt;/P&gt;&lt;P&gt;vblnr like reguh-vblnr,&lt;/P&gt;&lt;P&gt;CHECT like payr-CHECT,&lt;/P&gt;&lt;P&gt;end of itab.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;start-of-selection.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select a&lt;SUB&gt;zbukr a&lt;/SUB&gt;hbkid a&lt;SUB&gt;hktid a&lt;/SUB&gt;vblnr&lt;/P&gt;&lt;P&gt;b~chect into table itab&lt;/P&gt;&lt;P&gt;from reguh as a &amp;lt;b&amp;gt;LEFT OUTER JOIN&amp;lt;/b&amp;gt; payr as b on b&lt;SUB&gt;vblnr = a&lt;/SUB&gt;vblnr. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Reward points if useful.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Atish&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Message was edited by: &lt;/P&gt;&lt;P&gt;        Atish Sarda&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 22 May 2007 23:35:27 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-05-22T23:35:27Z</dc:date>
    <item>
      <title>ABAP statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/abap-statement/m-p/2277603#M495517</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I didnt giev exact requirement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;my requirement&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;is REGUH table has  fields&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;          a&lt;SUB&gt;zbukr  a&lt;/SUB&gt;hbkid a&lt;SUB&gt;hktid a&lt;/SUB&gt;vblnr&lt;/P&gt;&lt;P&gt;           a&lt;SUB&gt;zaldt  a&lt;/SUB&gt;znme1 a~rwbtr&lt;/P&gt;&lt;P&gt;           a&lt;SUB&gt;waers  a&lt;/SUB&gt;zbnkl a~rzawe&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PAYR has fields&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;b&lt;SUB&gt;chect  b&lt;/SUB&gt;checf b~gjahr&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;common fiels is vblnr&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;reguh can have 10 records and payr will have 10 or less then that.&lt;/P&gt;&lt;P&gt;for example 5.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;but i want to extract all the 10 records.&lt;/P&gt;&lt;P&gt;from reguh but additional field check frok payr to be filled in for 5 records.&lt;/P&gt;&lt;P&gt;remaining 5 fields can be empty.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;could you help me out&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;jeff&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 22 May 2007 23:32:16 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/abap-statement/m-p/2277603#M495517</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-05-22T23:32:16Z</dc:date>
    </item>
    <item>
      <title>Re: ABAP statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/abap-statement/m-p/2277604#M495518</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi jeff,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Just change the query given by Seshu as below.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;tables : REGUH,&lt;/P&gt;&lt;P&gt;PAYR .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data : begin of itab occurs 0,&lt;/P&gt;&lt;P&gt;zbukr like reguh-zbukr,&lt;/P&gt;&lt;P&gt;hbkid like reguh-hbkid,&lt;/P&gt;&lt;P&gt;hktid like reguh-hktid,&lt;/P&gt;&lt;P&gt;vblnr like reguh-vblnr,&lt;/P&gt;&lt;P&gt;CHECT like payr-CHECT,&lt;/P&gt;&lt;P&gt;end of itab.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;start-of-selection.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select a&lt;SUB&gt;zbukr a&lt;/SUB&gt;hbkid a&lt;SUB&gt;hktid a&lt;/SUB&gt;vblnr&lt;/P&gt;&lt;P&gt;b~chect into table itab&lt;/P&gt;&lt;P&gt;from reguh as a &amp;lt;b&amp;gt;LEFT OUTER JOIN&amp;lt;/b&amp;gt; payr as b on b&lt;SUB&gt;vblnr = a&lt;/SUB&gt;vblnr. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Reward points if useful.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Atish&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Message was edited by: &lt;/P&gt;&lt;P&gt;        Atish Sarda&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 22 May 2007 23:35:27 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/abap-statement/m-p/2277604#M495518</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-05-22T23:35:27Z</dc:date>
    </item>
    <item>
      <title>Re: ABAP statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/abap-statement/m-p/2277605#M495519</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You can use LEFT OUTER JOIN between 2 tables.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT a&lt;SUB&gt;zbukr a&lt;/SUB&gt;hbkid a&lt;SUB&gt;hktid a&lt;/SUB&gt;vblnr&lt;/P&gt;&lt;P&gt;a&lt;SUB&gt;zaldt a&lt;/SUB&gt;znme1 a~rwbtr&lt;/P&gt;&lt;P&gt;a&lt;SUB&gt;waers a&lt;/SUB&gt;zbnkl a&lt;SUB&gt;rzawe b&lt;/SUB&gt;chect b&lt;SUB&gt;checf b&lt;/SUB&gt;gjahr&lt;/P&gt;&lt;P&gt;INTO TABLE ITAB&lt;/P&gt;&lt;P&gt;FROM REGUH AS A&lt;/P&gt;&lt;P&gt;LEFT OUTER JOIN PAYR AS B&lt;/P&gt;&lt;P&gt;ON A&lt;SUB&gt;VBLNR = B&lt;/SUB&gt;VBLNR.&lt;/P&gt;&lt;P&gt;WHERE....&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 22 May 2007 23:37:29 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/abap-statement/m-p/2277605#M495519</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-05-22T23:37:29Z</dc:date>
    </item>
    <item>
      <title>Re: ABAP statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/abap-statement/m-p/2277606#M495520</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Jeff,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Resulting set for outer join &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The outer join basically creates the same resulting set as the inner join, with the difference that at least one line is created in the resulting set for every selected line on the left-hand side, even if no line on the right-hand side fulfils the join_cond condition. The columns on the right-hand side that do not fulfil the join_cond condition are filled with null values. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Your query should be something like this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;SELECT a~zbukr a~hbkid a~hktid a~vblnr
       a~zaldt a~znme1 a~rwbtr
       a~waers a~zbnkl a~rzawe  
       b~chect b~checf b~gjahr
from REGUH as a 
LEFT OUTER JOIN PAYR as b on a~vblnr = b~vblnr
 AND a~XXXXX = restriction field&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Do let me know if I can be further help on this and reward points if helpful.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Ram&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 May 2007 00:02:38 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/abap-statement/m-p/2277606#M495520</guid>
      <dc:creator>former_member214288</dc:creator>
      <dc:date>2007-05-23T00:02:38Z</dc:date>
    </item>
  </channel>
</rss>

