Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

difference b/w select options & Ranges

Former Member
0 Kudos

Hi experts,

Can u explain me wat is the difference b/w select options & Ranges.

Thanks.

1 ACCEPTED SOLUTION

Former Member
0 Kudos

Farook

Select-options will have data from Selection Screen... whereas in Ranges, developer has to fill the data through coding.... Rest is same..

Thanks

Amol Lohade

8 REPLIES 8

Former Member
0 Kudos

Farook

Select-options will have data from Selection Screen... whereas in Ranges, developer has to fill the data through coding.... Rest is same..

Thanks

Amol Lohade

vinod_vemuru2
Active Contributor
0 Kudos

Hi,

Functionally both are same. Select options appears on screen but range won't. Range just acts as normal variable with select option structure.

One limitation is when u use range in select query if u have more than 2000 entries in the range u will get a dump where as this restriction is not there with select option.

Hope it is clear.

thanks,

Vinod.

former_member705122
Active Contributor
0 Kudos

Hi,

Search forum,

Former Member
0 Kudos

Hi Farook,

Both are same for ranges, select-options is for your selection criteria in selection screen to be entered by the user and ranges ( obsolete now) is used in the program itself , its used as a variable in your program .

also refer to the link:

http://www.sap-img.com/abap/difference-between-select-options-ranges.htm

With luck,

Pritam.

Mohamed_Mukhtar
Active Contributor
0 Kudos

Hi Farooqh

[Select opiton and Ranges|]

Regards

Former Member
0 Kudos

Hi,

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 & HIGH. But in case of RANGES, this internal table should be defined explicitly.

hope its helps

Former Member
0 Kudos

Hi Farook,

SELECT-OPTIONS - On the selection screen, you can declare

RANGES on the selection screen.

RANGES - Inside the program, if you want to have variable with RANGES option, use the RANGES variable. You cannot declare and use SELECT-OPTIONS inside the program.

SELECT-OPTIONS: Declare an internal table that is also linked to input fields on a selection screen

RANGES: Declare an internal table with the same structure as in select-options, but without linking it to a selection screen.

Refer the following link:

http://72.14.203.104/search?q=cache:btyoj86smhEJ:www.sap-img.com/abap/difference-between-select-opti...Select-optionsandrangesIN+ABAP&hl=en&gl=in&ct=clnk&cd=1

http://www.sap-img.com/abap/difference-between-select-options-ranges.htm

Hope this will help.

Regards,

Nitin.

Edited by: Nitin Karamchandani on Sep 12, 2008 2:05 PM

Former Member
0 Kudos

They are similar but select-options is a more easy way when you create parameters because you don't need to define range parameters.

Using range you need to fill the structure