<?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: Prob in Select stmt in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/prob-in-select-stmt/m-p/4206910#M1005392</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Madan,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;just modify your query like this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;SELECT matnr
FROM ekpo
INTO TABLE t_ekpo
FOR ALL ENTRIES IN t_final
WHERE konnr IN s_konnr
AND matnr EQ t_final-number
AND matkl IN s_matkl
AND meins IN s_meins
AND bstyp = 'C_K'."should be in caps
IF sy-subrc EQ 0.
SORT t_ekpo BY matnr.
ENDIF.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Amit.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 23 Jul 2008 06:27:16 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2008-07-23T06:27:16Z</dc:date>
    <item>
      <title>Prob in Select stmt</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/prob-in-select-stmt/m-p/4206909#M1005391</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have wrote the following select query&lt;/P&gt;&lt;P&gt;Already my final Internal table contains Material number&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT matnr&lt;/P&gt;&lt;P&gt;      FROM ekpo&lt;/P&gt;&lt;P&gt;      INTO TABLE t_ekpo&lt;/P&gt;&lt;P&gt;       FOR ALL ENTRIES IN t_final&lt;/P&gt;&lt;P&gt;     WHERE konnr IN s_konnr&lt;/P&gt;&lt;P&gt;       AND matnr EQ t_final-number&lt;/P&gt;&lt;P&gt;       AND matkl IN s_matkl&lt;/P&gt;&lt;P&gt;       AND meins IN s_meins&lt;/P&gt;&lt;P&gt;       AND bstyp = c_k.&lt;/P&gt;&lt;P&gt;    IF sy-subrc EQ 0.&lt;/P&gt;&lt;P&gt;      SORT t_ekpo BY matnr.&lt;/P&gt;&lt;P&gt;    ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In select option i have entered a valid Konnr which have material number(in t_final) I am not getting any Material numbers.&lt;/P&gt;&lt;P&gt;Sy-subrc =4&lt;/P&gt;&lt;P&gt;Can anyone tell me where is the problem?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 Jul 2008 06:22:30 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/prob-in-select-stmt/m-p/4206909#M1005391</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-07-23T06:22:30Z</dc:date>
    </item>
    <item>
      <title>Re: Prob in Select stmt</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/prob-in-select-stmt/m-p/4206910#M1005392</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Madan,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;just modify your query like this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;SELECT matnr
FROM ekpo
INTO TABLE t_ekpo
FOR ALL ENTRIES IN t_final
WHERE konnr IN s_konnr
AND matnr EQ t_final-number
AND matkl IN s_matkl
AND meins IN s_meins
AND bstyp = 'C_K'."should be in caps
IF sy-subrc EQ 0.
SORT t_ekpo BY matnr.
ENDIF.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Amit.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 Jul 2008 06:27:16 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/prob-in-select-stmt/m-p/4206910#M1005392</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-07-23T06:27:16Z</dc:date>
    </item>
    <item>
      <title>Re: Prob in Select stmt</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/prob-in-select-stmt/m-p/4206911#M1005393</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi,&lt;/P&gt;&lt;P&gt;Since you say u have matching konnr for the s_konnr you enter :&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Check if you have any &lt;STRONG&gt;matnr from ekpo&lt;/STRONG&gt; matching the values in &lt;STRONG&gt;t_final-number&lt;/STRONG&gt;. If there is no matching matnr in ekpo when compared to the matnr in internal  table then there is a possibility of select to have sy-subrc = 4.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;madhu&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 Jul 2008 06:28:55 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/prob-in-select-stmt/m-p/4206911#M1005393</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-07-23T06:28:55Z</dc:date>
    </item>
    <item>
      <title>Re: Prob in Select stmt</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/prob-in-select-stmt/m-p/4206912#M1005394</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hiiii&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;check before this select statement that t_final is initial or not then use this select query..also check with the table taht wether that particular data exist with the same data you are entering on selection screen..check with following code&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;SELECT matnr                         " Material Number
    FROM mara
    INTO TABLE t_final
   WHERE matnr IN s_matnr.

  IF t_final[] IS NOT INITIAL.
    SELECT matnr
FROM ekpo
INTO TABLE t_ekpo
FOR ALL ENTRIES IN t_final
WHERE matnr EQ t_final-number
AND matkl IN s_matkl
AND konnr IN s_konnr
AND meins IN s_meins
AND bstyp = c_k.
ENDIF.

IF sy-subrc EQ 0.
SORT t_ekpo BY matnr.
ENDIF.

  ENDIF.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;      &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards&lt;/P&gt;&lt;P&gt;twinkal&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: twinkal patel on Jul 23, 2008 8:29 AM&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: twinkal patel on Jul 23, 2008 8:30 AM&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 Jul 2008 06:29:27 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/prob-in-select-stmt/m-p/4206912#M1005394</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-07-23T06:29:27Z</dc:date>
    </item>
    <item>
      <title>Re: Prob in Select stmt</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/prob-in-select-stmt/m-p/4206913#M1005395</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 using for all entries in select statement.. either select fields should contain all the key fields or in where clause it should contain all the key fields where as u r select query on table EKPO either in select clause or in where clause u have not mentioned any key fields rectify it.&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;Sunil Kumar Mutyala&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 Jul 2008 06:31:27 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/prob-in-select-stmt/m-p/4206913#M1005395</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-07-23T06:31:27Z</dc:date>
    </item>
    <item>
      <title>Re: Prob in Select stmt</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/prob-in-select-stmt/m-p/4206914#M1005396</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;you have to  mention bstyp in CAPSLOCK.&lt;/P&gt;&lt;P&gt;any Types i.e., Document type ,Material type ,BOM type has to be mentioned in CAPSLOCK.&lt;/P&gt;&lt;P&gt;Hope this will solve your problem.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;sharmishta.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 Jul 2008 06:32:08 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/prob-in-select-stmt/m-p/4206914#M1005396</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-07-23T06:32:08Z</dc:date>
    </item>
    <item>
      <title>Re: Prob in Select stmt</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/prob-in-select-stmt/m-p/4206915#M1005397</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;Please check wether c_k = 'K'. - Capital &lt;STRONG&gt;K&lt;/STRONG&gt;. If you see domain &lt;STRONG&gt;BSTYP&lt;/STRONG&gt;, there will be value ranges which are A,B,F,I,K,L,Q,W.&lt;/P&gt;&lt;P&gt;&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;Sukhbold&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 Jul 2008 06:32:14 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/prob-in-select-stmt/m-p/4206915#M1005397</guid>
      <dc:creator>sukhbold_altanbat</dc:creator>
      <dc:date>2008-07-23T06:32:14Z</dc:date>
    </item>
    <item>
      <title>Re: Prob in Select stmt</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/prob-in-select-stmt/m-p/4206916#M1005398</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Madan,&lt;/P&gt;&lt;P&gt;  i think the problem is with ekpo just check whether the same Konnr is availble in ekpo also or not. ithink c_k is constant so no need to have it in capital only pretty printer will do it for u if necessary. also check the Matkl, meins and Bstyp = c_k  are their in ekpo corresponds to Konnr you are entering in the screen.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;hope this will help&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Ankur&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 Jul 2008 06:35:14 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/prob-in-select-stmt/m-p/4206916#M1005398</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-07-23T06:35:14Z</dc:date>
    </item>
    <item>
      <title>Re: Prob in Select stmt</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/prob-in-select-stmt/m-p/4206917#M1005399</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Twinkel,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thanks for replying and giving time to SDNers.&lt;/P&gt;&lt;P&gt;but i would suggest you that pls once you sure than only put your thoughts in forum you wrote:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;check before this select statement that t_final is initial or not then use this select query&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if the internal table is blank on which you are using for all entries than no data is suppose to fetch or all data will be fetch pls confirm than reply.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;because in future from this thread some other person may also can take help so pls donot create misleads.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;hope you dont hurt.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Amit.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 Jul 2008 06:39:02 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/prob-in-select-stmt/m-p/4206917#M1005399</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-07-23T06:39:02Z</dc:date>
    </item>
  </channel>
</rss>

