2008 Jul 10 7:32 AM
hi everybody,
why we r going for the "select-options with no intervals and no extension" when we have the "Parameters" option.In which Case we go for the "select-options with no intervals and no extension".
2008 Jul 10 7:37 AM
hi,
good question.
if u r using parameters option and u didnt pass any value and execute it the sy-subrc value will be 4.
if u r using select-options with no intervals and no extension then even if u didnt pass nay value and execute u will get all values.
for example we use this in case of company code where u want details of only 1 company code for that we use these kind of options.
2008 Jul 10 7:35 AM
hi,
There are many restrictions on parameters.
Plz refer to this link.
[http://www.allinterview.com/showanswers/66055.html]
[http://www.allinterview.com/showanswers/56597.html]
Hope this will help.
Regards
Sumit Agarwal
2008 Jul 10 7:37 AM
hi,
good question.
if u r using parameters option and u didnt pass any value and execute it the sy-subrc value will be 4.
if u r using select-options with no intervals and no extension then even if u didnt pass nay value and execute u will get all values.
for example we use this in case of company code where u want details of only 1 company code for that we use these kind of options.
2008 Jul 10 7:40 AM
There are differences when we use parameter and select-option with no extension and no intervals.
1) parameter if you use and do no pass any value means in select statement it will search for a space value and space is not there means it will fail. Meanwhile select-option low value is not passed means it will fetch all the records. So initial check is important based on requirement. this makes one difference.
2) Select-option with no interval and no extension, will give only low value in selection screen. if you double click on that you will get the pop-up with comparison operators.. <low value. > low value etc are still possible with this option
Hope this helps
2008 Jul 10 7:47 AM
Hi Pavan,
You can use it according to your requirement. But the advantage in using select-options with no extension and no-intervals is that you can have many single values in your select-options and you can have either include or exclude options to those values . This feature is not there in parameters.
Regards,
Swapna.
2008 Jul 10 7:52 AM
hi swapna,
thanx for ur reply.Is there any other diff ?I want in which scenarios select-options without extension and intervals will be used?
2008 Jul 10 8:20 AM
Pavan,
Just try this.
tables:
mara.
data :
t_mara like standard table of mara.
data :
fs_mara like line of t_mara.
select-options :
s_matnr for mara-matnr no-extension no intervals.
initialization.
s_matnr-low = '1232'.
s_matnr-sign = 'I'.
append s_matnr.
start-of-selection.
select matnr
from mara
into corresponding fields of table t_mara
where matnr eq s_matnr-low.
loop at t_mara into fs_mara.
write 😕 fs_mara-matnr.
endloop.
Regards,
Swapna.
2008 Jul 10 7:49 AM
HI Pavan,
Checkthe following links which give the differences between parameters and select- options:
http://www.sap-basis-abap.com/abap/difference-between-select-options-and-parameters.htm
Hope this helps you.
Regards,
Chandra Sekhar
2008 Jul 10 7:50 AM
hiiiii
if you use parameters in your selection screen then its compulsary for you to enter any value or else it will consider value as SPACE in parameter & it will give output as per SPACE value only..
while Select option will perform even if you have not entered any values in it.it will cosider as all the values & will give you output as per that only.
Select option with no interval means user can only specify a single comparison in the first line in the selection table on the selection screen.while dialog box for multiple selections still allows interval selections.so you will not see second input box on screen.
select option with no extension means user can not access the dialog box for multiple selection on screen. so they cannot edit selection tables containing several lines means you will not get push button for multiple selection here.
regards
twinkal
2008 Jul 10 7:58 AM
Hello pavan,
The advantage of using select-options as a screen element is that we can go for complex selection criteria like include/exclude a particular value .
Moreover , if you are using a select-option with no extension and no interval though you are not allowed to give ranges but you can give multiple single values and retrieve data for more than one entry which is not possible with parameters because parameters only take one value at a time and even does not have the facility of complex criteria.
The only selection criteria you have with parameters is ' = ' .
Also a space in case of select-option retrieves all data while in case of parameters retrieves no data.
Hope this answers your question.
Best of luck,
Bhumika
2008 Jul 10 8:01 AM
Hi,
select-option is an internal table which has fields sign,option,low & high
with no-extension & no-intervals high field will be blank..
still u hav sign filed & option..
go thru this code..
REPORT ztest2 . "IDES Textpool
TABLES kna1.
SELECT-OPTIONS name FOR kna1-kunnr NO INTERVALS NO-EXTENSION.
PARAMETER p_name TYPE kna1-kunnr.
name-sign = 'E'.
MODIFY name INDEX 1.
SELECT SINGLE * FROM kna1 WHERE kunnr = '0000003511'.
SELECT SINGLE * FROM kna1 WHERE kunnr IN name.
SELECT SINGLE * FROM kna1 WHERE kunnr = p_name.
keep break point at each seelct statement & observe contents of kna1...
2008 Jul 10 8:05 AM
Hi Pavan.
The basic difference is that we can make select-options behave like paramenters by using
additon "no intervals" and "No extensions", but vice versa is not possible.
On the "Multiple Selection" screen, you can also enter ranges for selection options with " NO INTERVALS".
By combining this addition with " NO-EXTENSION", you can restrict the user to entry of a single value for the selection option, but with the possibility of also choosing single value options like 'Greater than' or 'Less than or equal'.
By using the addition " NO INTERVALS" with SELECTION-SCREEN BEGIN OF BLOCK, you can activate the simplified display for all selection options in a block.
hence, The Select-option has a multi-operational feature,
The Parameter function is one of the important feature.
Good Luck.
Harsh.