<?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: Ranges in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/985000#M72787</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Jayanthi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;for one thing, you are not properly manipulating the values for the &amp;lt;b&amp;gt;option&amp;lt;/b&amp;gt; (and possibly the &amp;lt;b&amp;gt;sign&amp;lt;/b&amp;gt; field).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For example, if both high and low are populated on the select-options, then the value of OPTION will not be EQ. It will be BT.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can write a small test program which I'm sure will help you understand what is wrong with your code - &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;tables mara.
select-option s_matnr for mara-matnr.

loop at s_matnr.
  write : / s_matnr-sign,
            s_matnr-option,
            s_matnr-low,
            s_matnr-high.       
endloop.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Anand Mandalika.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 30 Jun 2005 08:40:10 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2005-06-30T08:40:10Z</dc:date>
    <item>
      <title>Ranges</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/984999#M72786</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am having a select-option(s_matnr).I want to assign the values in select-option to ranges.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am declaring ranges as below.&lt;/P&gt;&lt;P&gt;ranges r_matnr for mara-matnr.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I want to use the ranges in select statement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Suppose I am entering values 1(s_matnr-low) and 10(s_matnr-high) in selection-screen.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I did the following code.But it is not working as I expected.&lt;/P&gt;&lt;P&gt;loop at s_matnr.&lt;/P&gt;&lt;P&gt;r_matnr-sign = 'I'.&lt;/P&gt;&lt;P&gt;r_matnr-option = 'EQ'.&lt;/P&gt;&lt;P&gt;IF NOT ( s_matnr-low IS INITIAL ).&lt;/P&gt;&lt;P&gt;   r_matnr-low = s_matnr-low.&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;if not ( s_matnr-high is initial ).&lt;/P&gt;&lt;P&gt;  r_matnr-high = s_matnr-high.&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;  append r_matnr.&lt;/P&gt;&lt;P&gt;endloop.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select * from mara into table itab where matnr in r_matnr.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But the result is not same as&lt;/P&gt;&lt;P&gt;select * from mara into table itab where matnr in s_matnr.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Could any one tell how to produce the same result as I am getting in s_matnr?&lt;/P&gt;&lt;P&gt;PS:&lt;/P&gt;&lt;P&gt;I &amp;lt;b&amp;gt;don't&amp;lt;/b&amp;gt; want to assign &lt;/P&gt;&lt;P&gt;r_matnr[] = s_matnr[].&lt;/P&gt;&lt;P&gt;If I did like that , it is producing the same result as that of s_matnr.&lt;/P&gt;&lt;P&gt;But I want to know what is wrong in the code I mentioned.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any useful pointers will be rewarded.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 30 Jun 2005 08:26:14 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/984999#M72786</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-06-30T08:26:14Z</dc:date>
    </item>
    <item>
      <title>Re: Ranges</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/985000#M72787</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Jayanthi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;for one thing, you are not properly manipulating the values for the &amp;lt;b&amp;gt;option&amp;lt;/b&amp;gt; (and possibly the &amp;lt;b&amp;gt;sign&amp;lt;/b&amp;gt; field).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For example, if both high and low are populated on the select-options, then the value of OPTION will not be EQ. It will be BT.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can write a small test program which I'm sure will help you understand what is wrong with your code - &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;tables mara.
select-option s_matnr for mara-matnr.

loop at s_matnr.
  write : / s_matnr-sign,
            s_matnr-option,
            s_matnr-low,
            s_matnr-high.       
endloop.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Anand Mandalika.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 30 Jun 2005 08:40:10 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/985000#M72787</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-06-30T08:40:10Z</dc:date>
    </item>
    <item>
      <title>Re: Ranges</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/985001#M72788</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Doing a 'r_matnr[] = s_matnr[].' shall do.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;cheers,&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 30 Jun 2005 08:46:26 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/985001#M72788</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-06-30T08:46:26Z</dc:date>
    </item>
    <item>
      <title>Re: Ranges</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/985002#M72789</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This should work.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;loop at s_matnr.&lt;/P&gt;&lt;P&gt;r_matnr-sign = s_matnr-sign. "'I'.&lt;/P&gt;&lt;P&gt;r_matnr-option = s_matnr-option. "'EQ'.&lt;/P&gt;&lt;UL&gt;&lt;UL&gt;&lt;UL&gt;&lt;LI level="3" type="ul"&gt;&lt;P&gt;I am not sure why you want to check here that the s_matnr-low field is intial... anyways... does not make a difference...&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;/UL&gt;&lt;/UL&gt;&lt;P&gt;***&lt;/P&gt;&lt;P&gt;IF NOT ( s_matnr-low IS INITIAL ).&lt;/P&gt;&lt;P&gt;r_matnr-low = s_matnr-low.&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;if not ( s_matnr-high is initial ).&lt;/P&gt;&lt;P&gt;r_matnr-high = s_matnr-high.&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;append r_matnr.&lt;/P&gt;&lt;P&gt;endloop.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;or best option is r_matnr[] = s_matnr[].&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Shekhar Kulkarni&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 30 Jun 2005 08:50:26 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/985002#M72789</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-06-30T08:50:26Z</dc:date>
    </item>
    <item>
      <title>Re: Ranges</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/985003#M72790</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for reply.&lt;/P&gt;&lt;P&gt;That is problem in option as Anand pointed out.&lt;/P&gt;&lt;P&gt;Now it's ok.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks Anand.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 30 Jun 2005 08:55:13 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/985003#M72790</guid>
      <dc:creator>jayanthi_jayaraman</dc:creator>
      <dc:date>2005-06-30T08:55:13Z</dc:date>
    </item>
  </channel>
</rss>

