<?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/5571001#M1270823</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;thanks everyone i awarded u two the points.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 18 May 2009 11:55:34 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2009-05-18T11:55:34Z</dc:date>
    <item>
      <title>RANGES :</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/5570996#M1270818</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi ABAP Expert.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please see the code below.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;RANGES: COMPANY_CODE FOR VBAK-BUKRS_VF.

COMPANY_CODE-LOW = 2500
COMPANY_CODE-HIGH = 2500

SELECT * FROM VBAK
WHERE VBAK~BUKRS_VF IN COMPANY_CODE&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Compare the above code with below code&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;SELECT * FROM VBAK
WHERE VBAK~BUKRS_VF = 2500&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am getting different results.&lt;/P&gt;&lt;P&gt;Looking for ur reply&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thanks&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 18 May 2009 11:36:29 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/5570996#M1270818</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-05-18T11:36:29Z</dc:date>
    </item>
    <item>
      <title>Re: RANGES :</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/5570997#M1270819</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;Do the following Way,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;TYPES: BEGIN OF ty_vbak,
  bukrs_vf like vbak-bukrs_vf,
  END OF ty_vbak.

RANGES: company_code FOR vbak-bukrs_vf.
DATA: it_vbak type STANDARD TABLE OF ty_vbak WITH HEADER LINE .

company_code-option = 'EQ'. " EQ when only one Value like you are using this time only 2500 if like this Low = 2000 to High = 2500 thna use BT
company_code-sign = 'I'.
company_code-low = '2500'.
company_code-high = '2500'.
APPEND company_code.

SELECT * FROM vbak INTO CORRESPONDING FIELDS OF TABLE it_vbak
WHERE vbak~bukrs_vf IN company_code.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;and &lt;STRONG&gt;Please always use Meaningful Subject Line&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Faisal&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 18 May 2009 11:41:47 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/5570997#M1270819</guid>
      <dc:creator>faisalatsap</dc:creator>
      <dc:date>2009-05-18T11:41:47Z</dc:date>
    </item>
    <item>
      <title>Re: RANGES :</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/5570998#M1270820</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Example for Ranges:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*Ranges declaration for PO Number&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;DATA : r_ebeln TYPE RANGE OF ebeln,
       w_ebeln LIKE LINE  OF r_ebeln.
   MOVE :'I'                     TO w_ebeln-sign,
          'EQ'                    TO w_ebeln-option,
          wa_cdpos-objectid+0(10) TO w_ebeln-low.
    APPEND w_ebeln TO r_ebeln.
    CLEAR: w_ebeln.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 18 May 2009 11:42:24 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/5570998#M1270820</guid>
      <dc:creator>former_member242255</dc:creator>
      <dc:date>2009-05-18T11:42:24Z</dc:date>
    </item>
    <item>
      <title>Re: RANGES :</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/5570999#M1270821</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 is an error in first example...&lt;/P&gt;&lt;P&gt;it should be:&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
COMPANY_CODE-LOW = 2500.
COMPANY_CODE-HIGH = 2500.
COMPANY_CODE-OPTION = 'EQ'
COMPANY_CODE-SIGN = 'I'.
APPEND COMPANY_CODE.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards, darek&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 18 May 2009 11:42:32 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/5570999#M1270821</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-05-18T11:42:32Z</dc:date>
    </item>
    <item>
      <title>Re: RANGES :</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/5571000#M1270822</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Point 1: the RANGES statement is obsolete and should not be used anymore. try using following:&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;Data: company_code type range of bukrs_vf.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Point 2: iu cant see any append when building your range. i guess the first statement gives you ALL records.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 18 May 2009 11:42:45 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/5571000#M1270822</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-05-18T11:42:45Z</dc:date>
    </item>
    <item>
      <title>Re: RANGES :</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/5571001#M1270823</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;thanks everyone i awarded u two the points.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 18 May 2009 11:55:34 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/5571001#M1270823</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-05-18T11:55:34Z</dc:date>
    </item>
    <item>
      <title>Re: RANGES :</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/5571002#M1270824</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;use this code.... it will give you complete result....&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;RANGES: COMPANY_CODE FOR VBAK-BUKRS_VF.
 
COMPANY_CODE-SIGN = 'I'.
COMPANY_CODE-OPTION = 'EQ'.
COMPANY_CODE-LOW = 2500.
APPEND COMPANY_CODE.
 
SELECT * FROM VBAK
WHERE VBAK~BUKRS_VF IN COMPANY_CODE&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Siddarth&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 18 May 2009 11:57:22 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/5571002#M1270824</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-05-18T11:57:22Z</dc:date>
    </item>
    <item>
      <title>Re: RANGES :</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/5571003#M1270825</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;HI Ajay,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;RANGES: r_company_code FOR VBAK-BUKRS_VF.
 
r_company_code-sign   = 'I'.   
r_company_code-option = 'EQ'.  
r_company_code-LOW = 2500
append r_company_code.

SELECT * 
FROM VBAK
WHERE VBAK~BUKRS_VF IN r_company_code&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&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;Sravanthi&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 18 May 2009 12:07:59 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/5571003#M1270825</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-05-18T12:07:59Z</dc:date>
    </item>
    <item>
      <title>Re: RANGES :</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/5571004#M1270826</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;RANGES: COMPANY_CODE FOR VBAK-BUKRS_VF.&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;COMPANY_CODE-LOW = 2500&lt;/P&gt;&lt;P&gt;COMPANY_CODE-HIGH = 2500&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;SELECT * FROM VBAK&lt;/P&gt;&lt;P&gt;WHERE VBAK~BUKRS_VF IN COMPANY_CODE&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Compare the above code with below code&lt;/P&gt;&lt;P&gt;SELECT * FROM VBAK&lt;/P&gt;&lt;P&gt;WHERE VBAK~BUKRS_VF = 2500&lt;/P&gt;&lt;P&gt;-&lt;/P&gt;&lt;HR originaltext="---------------------------------------------------------------------------------------------------------------------------------------" /&gt;&lt;P&gt;There was a difference in both statments. &lt;/P&gt;&lt;P&gt;For the first select query  it will retrieve the data from company code 0000 to 2500. Ranges will creates a Sign, Options, Low and High.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sign = I&lt;/P&gt;&lt;P&gt;Options = BT&lt;/P&gt;&lt;P&gt;Low = 2500&lt;/P&gt;&lt;P&gt;High = 2500&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So your condition is  retrieving the data as a company code input  BT 0001 to 2500. So you gill get the result from 0000 to 2500.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The second select query it will fetches the record only the company code 2500. So you will get the record for only 2500.&lt;/P&gt;&lt;P&gt;Let me know if you have anything.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Thiru&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 18 May 2009 12:13:42 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/5571004#M1270826</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-05-18T12:13:42Z</dc:date>
    </item>
  </channel>
</rss>

