<?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: selection statement in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/selection-statement/m-p/3482328#M837230</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;same fields as in itab2 and i am getting the data from bsik table&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 29 Feb 2008 12:54:11 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2008-02-29T12:54:11Z</dc:date>
    <item>
      <title>selection statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/selection-statement/m-p/3482325#M837227</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;in my report i am selectin data from bsak table into itab2 for all entries in itab1.&lt;/P&gt;&lt;P&gt;itab1 has got only one record but the problem is that it is picking all the data not only the data corresponding to the data in itab1.&lt;/P&gt;&lt;P&gt;in itab1 i am selecting data based on the vendor no enetred by the user in seelcetion screen&lt;/P&gt;&lt;P&gt;this is the code for second selectionm&lt;/P&gt;&lt;P&gt;SELECT   bukrs                                                    "getting details of open items based on user input&lt;/P&gt;&lt;P&gt;           lifnr&lt;/P&gt;&lt;P&gt;           umskz&lt;/P&gt;&lt;P&gt;           augdt&lt;/P&gt;&lt;P&gt;           augbl&lt;/P&gt;&lt;P&gt;           belnr&lt;/P&gt;&lt;P&gt;           budat&lt;/P&gt;&lt;P&gt;           zterm&lt;/P&gt;&lt;P&gt;           waers&lt;/P&gt;&lt;P&gt;           bschl&lt;/P&gt;&lt;P&gt;           bstat&lt;/P&gt;&lt;P&gt;           zfbdt&lt;/P&gt;&lt;P&gt;           shkzg&lt;/P&gt;&lt;P&gt;           zbd1t&lt;/P&gt;&lt;P&gt;           zbd2t&lt;/P&gt;&lt;P&gt;           zbd3t&lt;/P&gt;&lt;P&gt;           rebzg&lt;/P&gt;&lt;P&gt;           rebzt&lt;/P&gt;&lt;P&gt;           bldat&lt;/P&gt;&lt;P&gt;           dmbtr&lt;/P&gt;&lt;P&gt;         FROM bsak&lt;/P&gt;&lt;P&gt;         INTO TABLE t_cleared&lt;/P&gt;&lt;P&gt;          FOR ALL ENTRIES IN t_data1&lt;/P&gt;&lt;P&gt;          WHERE  bukrs IN s_bukrs&lt;/P&gt;&lt;P&gt;          AND  lifnr  = t_data1-lifnr&lt;/P&gt;&lt;P&gt;          AND  augdt LE p_kdate&lt;/P&gt;&lt;P&gt;          OR   augdt LE p_kdate&lt;/P&gt;&lt;P&gt;          AND  belnr NE bsik-augbl&lt;/P&gt;&lt;P&gt;          AND  bschl = 31.&lt;/P&gt;&lt;P&gt;ENDFORM.                    "f_get_cleared_data&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 29 Feb 2008 12:43:52 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/selection-statement/m-p/3482325#M837227</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-02-29T12:43:52Z</dc:date>
    </item>
    <item>
      <title>Re: selection statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/selection-statement/m-p/3482326#M837228</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;Modify ur code as follows:&lt;/P&gt;&lt;P&gt;SELECT bukrs "getting details of open items based on user input&lt;/P&gt;&lt;P&gt;lifnr&lt;/P&gt;&lt;P&gt;umskz&lt;/P&gt;&lt;P&gt;augdt&lt;/P&gt;&lt;P&gt;augbl&lt;/P&gt;&lt;P&gt;belnr&lt;/P&gt;&lt;P&gt;budat&lt;/P&gt;&lt;P&gt;zterm&lt;/P&gt;&lt;P&gt;waers&lt;/P&gt;&lt;P&gt;bschl&lt;/P&gt;&lt;P&gt;bstat&lt;/P&gt;&lt;P&gt;zfbdt&lt;/P&gt;&lt;P&gt;shkzg&lt;/P&gt;&lt;P&gt;zbd1t&lt;/P&gt;&lt;P&gt;zbd2t&lt;/P&gt;&lt;P&gt;zbd3t&lt;/P&gt;&lt;P&gt;rebzg&lt;/P&gt;&lt;P&gt;rebzt&lt;/P&gt;&lt;P&gt;bldat&lt;/P&gt;&lt;P&gt;dmbtr&lt;/P&gt;&lt;P&gt;FROM bsak&lt;/P&gt;&lt;P&gt;INTO TABLE t_cleared&lt;/P&gt;&lt;P&gt;FOR ALL ENTRIES IN t_data1&lt;/P&gt;&lt;P&gt;WHERE lifnr = t_data1-lifnr&lt;/P&gt;&lt;P&gt;AND bukrs IN s_bukrs&lt;/P&gt;&lt;P&gt;AND augdt LE p_kdate&lt;/P&gt;&lt;P&gt;OR augdt LE p_kdate&lt;/P&gt;&lt;P&gt;AND belnr NE bsik-augbl&lt;/P&gt;&lt;P&gt;AND bschl = 31.&lt;/P&gt;&lt;P&gt;ENDFORM. "f_get_cleared_data&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 29 Feb 2008 12:46:55 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/selection-statement/m-p/3482326#M837228</guid>
      <dc:creator>abdulazeez12</dc:creator>
      <dc:date>2008-02-29T12:46:55Z</dc:date>
    </item>
    <item>
      <title>Re: selection statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/selection-statement/m-p/3482327#M837229</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;What are the fields in itab1 and from which table are you filling the internal table itab1 ?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 29 Feb 2008 12:49:46 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/selection-statement/m-p/3482327#M837229</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-02-29T12:49:46Z</dc:date>
    </item>
    <item>
      <title>Re: selection statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/selection-statement/m-p/3482328#M837230</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;same fields as in itab2 and i am getting the data from bsik table&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 29 Feb 2008 12:54:11 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/selection-statement/m-p/3482328#M837230</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-02-29T12:54:11Z</dc:date>
    </item>
    <item>
      <title>Re: selection statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/selection-statement/m-p/3482329#M837231</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;When you are selecting from BSAK table , in order to get a single entry you need to enter all the key fields. Unless you enter all the key fields you may get multiple records.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Tell me thru which table are u filling itab1 and what are those fields.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 29 Feb 2008 12:54:11 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/selection-statement/m-p/3482329#M837231</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-02-29T12:54:11Z</dc:date>
    </item>
    <item>
      <title>Re: selection statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/selection-statement/m-p/3482330#M837232</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;When you are filling into the internal table itab1, fetch all the key fields from the table BSIK.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I think you should not have any problem then.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 29 Feb 2008 13:00:45 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/selection-statement/m-p/3482330#M837232</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-02-29T13:00:45Z</dc:date>
    </item>
    <item>
      <title>Re: selection statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/selection-statement/m-p/3482331#M837233</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Make sure ur internal table has data.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If internal table has no data, FOR ALL ENTRIES fetches all the records from the data base .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Ajay&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 29 Feb 2008 13:06:51 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/selection-statement/m-p/3482331#M837233</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-02-29T13:06:51Z</dc:date>
    </item>
    <item>
      <title>Re: selection statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/selection-statement/m-p/3482332#M837234</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Check ur where clause. Why u gave condition OR augdt LE p_kdate. Let me know this. Just remove this condition. U can get the proper out put. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;WHERE bukrs IN s_bukrs&lt;/P&gt;&lt;P&gt;AND lifnr = t_data1-lifnr&lt;/P&gt;&lt;P&gt;AND augdt LE p_kdate&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;OR augdt LE p_kdate&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;AND belnr NE bsik-augbl&lt;/P&gt;&lt;P&gt;AND bschl = 31.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Vinod.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 29 Feb 2008 13:12:31 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/selection-statement/m-p/3482332#M837234</guid>
      <dc:creator>vinod_vemuru2</dc:creator>
      <dc:date>2008-02-29T13:12:31Z</dc:date>
    </item>
  </channel>
</rss>

