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: 

Select Options Invalid Entries FOr Select Statement

Former Member
0 Kudos

Hello All,

I have 4-6 Single value entries in my select options say s_test. And Im using this in select statement, I want to catch the s_test entries where it doesn't find entries in the SELECT Statement. How do i achieve this? I tried searching the forum but didnt get any help.

I'm putting it as

select * from ztable where zfield in s_test.

s_test has like 5-6 entries and if the 4th entry is not there in the table I need to catch that. I dont want to loop around s_test and catch it instead is ther any other easy way.

4 REPLIES 4

Former Member
0 Kudos

What if the fourth entry has a NE or an exclusion or a range?

Rob

0 Kudos

Rob,

It will be always equal to in the Select Option Fields. I just want to post out the ones that are not available in the Table and present in select options.

0 Kudos

Well, the basic concept for SELECT-OPTIONS is to allow all of the entries to be processed together, so if you want to look at individual entries, I don't know of any way other than doing them one at a time.

Rob

kesavadas_thekkillath
Active Contributor
0 Kudos

Hi,

After selecting the data.

loop at select-options and read internal table.

check the sy-subrc value.

But when the select-option has a range then this will not work.