<?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/3515602#M845564</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 refer to the docu below, direct extract from ABAPDOCU&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;RANGES &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Basic form &lt;/P&gt;&lt;P&gt;RANGES sel FOR f. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Addition: &lt;/P&gt;&lt;P&gt;... OCCURS n &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This statement is not allowed in an ABAP Objects context. See Prohibit RANGES. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Effect &lt;/P&gt;&lt;P&gt;Defines an internal table similar to a selection &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;criterion sel defined using the SELECT-OPTIONS sel FOR f statement. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The above statement is identical to: &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: BEGIN OF sel OCCURS 10, &lt;/P&gt;&lt;P&gt;         SIGN(1), &lt;/P&gt;&lt;P&gt;         OPTION(2), &lt;/P&gt;&lt;P&gt;         LOW  LIKE f, &lt;/P&gt;&lt;P&gt;         HIGH LIKE f, &lt;/P&gt;&lt;P&gt;      END   OF sel. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Note &lt;/P&gt;&lt;P&gt;If you use the IN operator in conjunction with SUBMIT, CHECK, IF, WHILE or SELECT, always define the associated internal table using SELECT-OPTIONS or RANGES (never directly). &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Addition &lt;/P&gt;&lt;P&gt;... OCCURS n &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Effect &lt;/P&gt;&lt;P&gt;Changes the OCCURS value 10 to the value of occ. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Sriram Ponna.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 05 Mar 2008 15:33:26 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2008-03-05T15:33:26Z</dc:date>
    <item>
      <title>Ranges</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/3515597#M845559</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Guys,&lt;/P&gt;&lt;P&gt;    Briefly describe about ranges.&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;nagaraju.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 05 Mar 2008 15:24:11 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/3515597#M845559</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-03-05T15:24:11Z</dc:date>
    </item>
    <item>
      <title>Re: Ranges</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/3515598#M845560</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Check this&lt;/P&gt;&lt;P&gt;                                                                                &lt;STRONG&gt;Basic form&lt;/STRONG&gt;    RANGES sel FOR f.                                                                                &lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Addition:*                                                      &lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;               ... OCCURS n                                                                                &lt;/P&gt;&lt;P&gt;This statement is not allowed in an ABAP Objects context. See     &lt;/P&gt;&lt;P&gt;               RANGES not allowed.                                                                                &lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Effect*        Defines an internal table similar to a selection criterion sel &lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;               defined using the SELECT-OPTIONS sel FOR f statement.                                                                                &lt;/P&gt;&lt;P&gt;The above statement is identical to:                                                                                &lt;/P&gt;&lt;P&gt;DATA: BEGIN OF sel OCCURS 10,                                  &lt;/P&gt;&lt;P&gt;                        SIGN(1),                                              &lt;/P&gt;&lt;P&gt;                        OPTION(2),                                            &lt;/P&gt;&lt;P&gt;                        LOW  LIKE f,                                          &lt;/P&gt;&lt;P&gt;                        HIGH LIKE f,                                          &lt;/P&gt;&lt;P&gt;                     END   OF sel.                                                                                &lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Note&lt;/STRONG&gt;          If you use the IN operator in conjunction with SUBMIT, CHECK,  &lt;/P&gt;&lt;P&gt;               IF, WHILE or SELECT, always define the associated internal     &lt;/P&gt;&lt;P&gt;               table using SELECT-OPTIONS or RANGES (never directly).                                                                                &lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Addition&lt;/STRONG&gt;      ... OCCURS n                                                                                &lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Effect&lt;/STRONG&gt;        Changes the OCCURS value 10 to the value of n.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 05 Mar 2008 15:28:00 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/3515598#M845560</guid>
      <dc:creator>santhosh_patil</dc:creator>
      <dc:date>2008-03-05T15:28:00Z</dc:date>
    </item>
    <item>
      <title>Re: Ranges</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/3515599#M845561</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Ranges are similar to select-options which are declared in screen ,&lt;/P&gt;&lt;P&gt;except that these are not shown in the screen.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Ranges have the structure with fields ..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sign &lt;/P&gt;&lt;P&gt;option&lt;/P&gt;&lt;P&gt;low&lt;/P&gt;&lt;P&gt;high&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 05 Mar 2008 15:28:54 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/3515599#M845561</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-03-05T15:28:54Z</dc:date>
    </item>
    <item>
      <title>Re: Ranges</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/3515600#M845562</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Nagaraj,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;RANGES &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Syntax &lt;/P&gt;&lt;P&gt;RANGES rtab FOR dobj [OCCURS n]. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Effect &lt;/P&gt;&lt;P&gt;Obsolete declaration of a Ranges-table. This statement (not allowed in classes) is a short form of the following statement sequence which is also not allowed in classes: &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: BEGIN OF rtab OCCURS {10|n}, &lt;/P&gt;&lt;P&gt;        sign   TYPE c LENGTH 1, &lt;/P&gt;&lt;P&gt;        option TYPE c LENGTH 2, &lt;/P&gt;&lt;P&gt;        low    LIKE dobj, &lt;/P&gt;&lt;P&gt;        high   LIKE dobj, &lt;/P&gt;&lt;P&gt;      END OF rtab. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;An internal table rtab with the structure of a selection table and a header line is declared. Without the addition OCCURS, the initial memory requirement (see DATA - ranges-tables) of the ranges-table is set to ten rows. With the addition OCCURS, you can specify a numeric literal or a numeric constant n to determine a different initial memory requirement. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Note &lt;/P&gt;&lt;P&gt;It is not allowed to declare internal tables with header lines. Due to this, the statement RANGES is not allowed in header lines. To declare a ranges-table in classes, you can use the addition TYPE|LIKE RANGE OF (see TYPES - ranges-table type and DATA - ranges-tables). &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;lt;REMOVED BY MODERATOR&amp;gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Venkat&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: Alvaro Tejada Galindo on Mar 5, 2008 5:50 PM&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 05 Mar 2008 15:29:56 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/3515600#M845562</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-03-05T15:29:56Z</dc:date>
    </item>
    <item>
      <title>Re: Ranges</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/3515601#M845563</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;ASSIGN feld1  TO &amp;lt;fs&amp;gt; RANGE feld2.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This addition explicitly sets the range limits, making it possible to define addresses past field limits, for example to edit repeating groups with the ASSIGN INCREMENT statement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The field limits of field2 are used as the range for &amp;lt;fs&amp;gt;. &lt;/P&gt;&lt;P&gt;In a UP, the limits specified by the RANGE definition must include the range limits that would otherwise result from the rules described above. &lt;/P&gt;&lt;P&gt;If the memory area of field1 is not completely contained in field2, there is a catchable runtime error. &lt;/P&gt;&lt;P&gt;Field field2, which defines the range, may also be deep. Repeating groups with deep types therefore can also be processed.&lt;/P&gt;&lt;P&gt;ASSIGN feld INCREMENT n TO &amp;lt;fs&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The field symbol is incremented by n times the length of field, starting with the position defined by field. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;First the range for the access is defined from the length of field and the INCREMENT definition of the range for the access as defined by ASSIGN fld+n*sizeof[field] (sizeof[fld]) TO &amp;lt;fs&amp;gt;. The addressed range must lie within the range limits. If it is not possible to make the assignment because the range limits were violated, SY-SUBRC is set to &amp;gt; 0 and the field symbol is not changed.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The range limits for ASSIGN field INCREMENT n TO &amp;lt;fs&amp;gt; are defined in exactly the same way as ASSIGN field TO &amp;lt;fs&amp;gt;. The definition of the INCREMENT therefore has no effect on the definition of the range limits. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You use the DEFAULT addition as follows to address the individual components of the first row:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To fill only the LOW field (single field comparison), use:&lt;/P&gt;&lt;P&gt;........DEFAULT &amp;lt;g&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To fill the LOW and HIGH fields (range selection), use:&lt;/P&gt;&lt;P&gt;........DEFAULT &amp;lt;g&amp;gt; TO &amp;lt;h&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To fill the OPTION field, use:&lt;/P&gt;&lt;P&gt;........DEFAULT &amp;lt;g&amp;gt; [to &amp;lt;h&amp;gt;] OPTION &amp;lt;op&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For single field comparisons, &amp;lt;op&amp;gt; can be EQ, NE, GE, GT, LE, LT, CP, or NP. The default value is EQ. For range selections, &amp;lt;op&amp;gt; can be BT or NB. The default value is BT.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To fill the SIGN field, use:&lt;/P&gt;&lt;P&gt;........DEFAULT &amp;lt;g&amp;gt; [to &amp;lt;h&amp;gt;] [OPTION &amp;lt;op&amp;gt;] SIGN &amp;lt;s&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The value of &amp;lt;s&amp;gt; can be I or E. The default value is I.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The input fields of the selection criterion are filled with the default values. The user can accept or change these values.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;REPORT DEMO.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA WA_SPFLI TYPE SPFLI.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT-OPTIONS AIRLINE FOR WA_SPFLI-CARRID&lt;/P&gt;&lt;P&gt;               DEFAULT 'AA'&lt;/P&gt;&lt;P&gt;                    TO 'LH'&lt;/P&gt;&lt;P&gt;                OPTION  NB&lt;/P&gt;&lt;P&gt;                  SIGN  I.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Kevin&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 05 Mar 2008 15:31:12 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/3515601#M845563</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-03-05T15:31:12Z</dc:date>
    </item>
    <item>
      <title>Re: Ranges</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/3515602#M845564</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 refer to the docu below, direct extract from ABAPDOCU&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;RANGES &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Basic form &lt;/P&gt;&lt;P&gt;RANGES sel FOR f. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Addition: &lt;/P&gt;&lt;P&gt;... OCCURS n &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This statement is not allowed in an ABAP Objects context. See Prohibit RANGES. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Effect &lt;/P&gt;&lt;P&gt;Defines an internal table similar to a selection &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;criterion sel defined using the SELECT-OPTIONS sel FOR f statement. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The above statement is identical to: &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: BEGIN OF sel OCCURS 10, &lt;/P&gt;&lt;P&gt;         SIGN(1), &lt;/P&gt;&lt;P&gt;         OPTION(2), &lt;/P&gt;&lt;P&gt;         LOW  LIKE f, &lt;/P&gt;&lt;P&gt;         HIGH LIKE f, &lt;/P&gt;&lt;P&gt;      END   OF sel. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Note &lt;/P&gt;&lt;P&gt;If you use the IN operator in conjunction with SUBMIT, CHECK, IF, WHILE or SELECT, always define the associated internal table using SELECT-OPTIONS or RANGES (never directly). &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Addition &lt;/P&gt;&lt;P&gt;... OCCURS n &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Effect &lt;/P&gt;&lt;P&gt;Changes the OCCURS value 10 to the value of occ. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Sriram Ponna.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 05 Mar 2008 15:33:26 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/3515602#M845564</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-03-05T15:33:26Z</dc:date>
    </item>
    <item>
      <title>Re: Ranges</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/3515603#M845565</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Ranges will just act as select options.&lt;/P&gt;&lt;P&gt;So if u want to compare some range of values(Known) in the select statement then instead of having one dummy select-option we can have range. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT ....&lt;/P&gt;&lt;P&gt;FROM...&lt;/P&gt;&lt;P&gt;INTO TABLE...&lt;/P&gt;&lt;P&gt;WHERE field1 IN r_range1.&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>Wed, 05 Mar 2008 15:37:20 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/3515603#M845565</guid>
      <dc:creator>vinod_vemuru2</dc:creator>
      <dc:date>2008-03-05T15:37:20Z</dc:date>
    </item>
    <item>
      <title>Re: Ranges</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/3515604#M845566</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; Both SELECT-OPTIONS &amp;amp; RANGES works for the same purpose.  They both are used for the range selection from selection screen.  The main diff. between them is, while we use SELECT-OPTIONS system implicitly creates the select options internal table which contains the fields of SIGN,OPTION,LOW &amp;amp; HIGH.  But in case of RANGES, this internal table should be defined explicitly. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Eg. to SELECT-OPTIONS : &lt;/P&gt;&lt;P&gt;-&lt;/P&gt;&lt;HR originaltext="----------------------------------------" /&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;REPORT YARSELECT. &lt;/P&gt;&lt;P&gt;TABLES YTXLFA1. &lt;/P&gt;&lt;P&gt;SELECT-OPTIONS : VENDOR FOR YTXLFA1-LIFNR. &lt;/P&gt;&lt;P&gt;INITIALIZATION. &lt;/P&gt;&lt;P&gt;VENDOR-LOW    =   1000.               " It specifies the range starting value. &lt;/P&gt;&lt;P&gt;VENDOR-HIGH    =   2000.               " It specifies the range ending value. &lt;/P&gt;&lt;P&gt;VENDOR-OPTION  =  'BT'.                " specifies ranges value is in between. &lt;/P&gt;&lt;P&gt;VENDOR-SIGN      = 'I'.                     "specifies both inclussive. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;APPEND VENDOR. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;- - - - &lt;/P&gt;&lt;P&gt;- - - - &lt;/P&gt;&lt;P&gt;SELECT LIFNR LAND1 NAME1 FROM LFA1 INTO TABLE ITAB  &lt;/P&gt;&lt;P&gt;WHERE LIFNR IN VENDOR. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Eg. to RANGES: &lt;/P&gt;&lt;P&gt;-&lt;/P&gt;&lt;HR originaltext="------------------------" /&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;REPORT YARRANGE. &lt;/P&gt;&lt;P&gt;TABLES YTXLFA1. &lt;/P&gt;&lt;P&gt;RANGES: VENDOR FOR YTXFLA1-LIFNR. &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;&lt;P&gt;SELECT LIFNR LAND1 NAME1 FROM LFA1 INTO TABLE ITAB  &lt;/P&gt;&lt;P&gt;WHERE LIFNR IN VENDOR. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here with RANGES  user has to design an internal table with fields -  &lt;/P&gt;&lt;P&gt;SIGN,OPTION,LOW and HIGH EXPLICITLY. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-&lt;/P&gt;&lt;HR originaltext="--------------------------------------------------------------------------------------------------------" /&gt;&lt;P&gt;&amp;gt; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Example: &lt;/P&gt;&lt;P&gt;  &lt;/P&gt;&lt;P&gt;select-options: bukrs for zstock-bukrs. &lt;/P&gt;&lt;P&gt;  &lt;/P&gt;&lt;P&gt;Should the user fill in 'ABFI' in BUKRS on the selection screen, BUKRS will look like this: &lt;/P&gt;&lt;P&gt;  &lt;/P&gt;&lt;P&gt;IEQABFI &lt;/P&gt;&lt;P&gt;  &lt;/P&gt;&lt;P&gt;This is because BUKRS is set as a table as follows: &lt;/P&gt;&lt;P&gt;  &lt;/P&gt;&lt;P&gt;begin of bukrs occurs 0, &lt;/P&gt;&lt;P&gt;  SIGN(1)    type c, &lt;/P&gt;&lt;P&gt;  OPTION(2) type c, &lt;/P&gt;&lt;P&gt;  LOW         like bukrs, &lt;/P&gt;&lt;P&gt;  HIGH         like bukrs, &lt;/P&gt;&lt;P&gt;end of bukrs. &lt;/P&gt;&lt;P&gt;  &lt;/P&gt;&lt;P&gt;Now, when you create the following range, it will have the exact same fields set inside its table: &lt;/P&gt;&lt;P&gt;  &lt;/P&gt;&lt;P&gt;Ranges: bukrs for zstock-bukrs. &lt;/P&gt;&lt;P&gt;  &lt;/P&gt;&lt;P&gt;The difference is, because ranges doesn't show on the selection screen, you will have to fill it yourself, meaning you will have to fill bukrs-sign, bukrs-option, bukrs-low &amp;amp; bukrs-high all manually. &lt;/P&gt;&lt;P&gt;  &lt;/P&gt;&lt;P&gt;Some tips: &lt;/P&gt;&lt;P&gt;Sign is always I (for Include) or E (for Exclude) &lt;/P&gt;&lt;P&gt;Option can be a whole range, which includes: &lt;/P&gt;&lt;P&gt;EQ        (Equal)  &lt;/P&gt;&lt;P&gt;BT        (Between))  &lt;/P&gt;&lt;P&gt;CP        (Contain Pattern) &lt;/P&gt;&lt;P&gt;So let's say you want to have the range check for all company codes not starting with AB, you will set your code as follow: &lt;/P&gt;&lt;P&gt;  &lt;/P&gt;&lt;P&gt;ranges: bukrs for zstock-bukrs. &lt;/P&gt;&lt;P&gt;  &lt;/P&gt;&lt;P&gt;bukrs-sign = 'E'.             "Exclude &lt;/P&gt;&lt;P&gt;bukrs-option = 'CP'.        "Pattern &lt;/P&gt;&lt;P&gt;bukrs-low = 'AB*'.            "Low Value &lt;/P&gt;&lt;P&gt;bukrs-high = ''.                "High Value &lt;/P&gt;&lt;P&gt;append bukrs. &lt;/P&gt;&lt;P&gt;  &lt;/P&gt;&lt;P&gt;Always remember to APPEND your range when you fill it, as the WHERE clause checks against the lines of the range table, not against the header line&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&amp;amp;Regards,&lt;/P&gt;&lt;P&gt;Chaithanya.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 06 Mar 2008 06:12:27 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/ranges/m-p/3515604#M845566</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-03-06T06:12:27Z</dc:date>
    </item>
  </channel>
</rss>

