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

Writing efficient select statement

Former Member
0 Likes
554

Hi,

We have a function module with 11 import optional parameters. Our requirement is that even if 1 parameter is filled we have to select data based on that. If more that 1 parameter is filled we have to consider all filled parameters.

Is there any good way to do that without putting so many combinations of filled and unfilled parameters?

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
522

Hi,

I think U can use FOR ALL ENTRIES......in the SELECT stmt for this purpose...

It may help U out.

Reward if helpful.

Thanks.

3 REPLIES 3
Read only

Former Member
0 Likes
522

You could use a dynamic where statement - use the F1 help on the Select statement for more information.

Or wait for someone to cut and paste it here for you...

Gareth.

Read only

Former Member
0 Likes
523

Hi,

I think U can use FOR ALL ENTRIES......in the SELECT stmt for this purpose...

It may help U out.

Reward if helpful.

Thanks.

Read only

Former Member
0 Likes
522

Using dynamic select statement solved this problem.