Application Development and Automation 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: 
Read only

How exclude multiple values which are not in sequence ( range )

Former Member
0 Likes
6,956

Hi Abapers,

My Requiremnt is to exclude multiple values which are not in sequence in selection screen.

I want to restrict some values .

please provide sample code.

thanks & regards,

Hari priya

4 REPLIES 4
Read only

Former Member
0 Likes
2,518

hi Hari Priya

use select options Multiple selection Box

there you can you single value/range of value and with Include or Exclude Function

Regards

Deva

Read only

Former Member
0 Likes
2,518

Hi,

Go through the below coding. Here in the selection screen you can exclude the all the PO number which starts from series 72.

SELECT-OPTIONS : s_ebeln FOR ekko-ebeln .

s_ebeln-low = '72*'.

s_ebeln-sign = 'E'.

s_ebeln-option = 'CP'.

append s_ebeln.

clear s_ebeln.

Read only

kesavadas_thekkillath
Active Contributor
0 Likes
2,518

Explain Clearly !!!

Read only

former_member585060
Active Contributor
0 Likes
2,518

SELECT-OPTIONS : s_matnr FOR mara-matnr.

INITILIZATION.

s_matnr-sign = 'E'. " E means Excluding.

s_matnr-option = 'EQ'.

s_matnr-low = '1000'.

append s_matnr.

s_matnr-sign = 'E'.

s_matnr-option = 'EQ'.

s_matnr-low = '1500'.

append s_matnr.

s_matnr-sign = 'E'.

s_matnr-option = 'BT'.

s_matnr-low = '2000'.

s_matnr-high = '3000'.

append s_matnr.

START_OF_SELECTION.

SELECT * FROM MARA INTO TABLE itab WHERE mara IN s_matnr.

the above s_matnr has values 1000,1500, 2000 - 3000.

so the above code fetches all the values excluding 1000,1500 and between 2000 and 3000.

Regards

Bala Krishna