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: 

CASE Statement

Former Member
0 Kudos

how many WHEN are possible in one CASE statement?

1 ACCEPTED SOLUTION

Former Member
0 Kudos

Any number of WHEN is possible in a case stmt

Arjun

10 REPLIES 10

Former Member
0 Kudos

Any number of WHEN is possible in a case stmt

Arjun

varma_narayana
Active Contributor
0 Kudos

Hi

There is no limit on this.

YOU CAN USE LIKE THIS.

case V_DAY.

WHEN 1 OR 2.

WHEN 3.

WHEN 4.

WHEN OTHERS.

ENDCASE.

reward if helpful.

Former Member
0 Kudos

Hi,

You can use as many as WHEN statments in a CASE statment, there is no restriction

Regrads

Sudheer

former_member188827
Active Contributor
0 Kudos

no restriction

Former Member
0 Kudos

Hi,

there is no limit you can use n number of cases under when statement.

Regards,

Vijay

Former Member
0 Kudos

Hi Prasad,

there is no such limit on when.

did you come across any such prob. pls let me know.

Regards,

Sachin.

Former Member
0 Kudos

There is no such limit to the number of WHEN in a CASE statement.

Example.........

CASE sy-ucomm.

WHEN 'BACK'.

LEAVE TO SCREEN 100.

WHEN 'CANCEL'.

LEAVE SCREEN.

WHEN 'EXIT'.

LEAVE PROGRAM.

.

.

.

.

.

.

WHEN OTHERS.

MESSAGE '...' TYPE 'E'.

ENDCASE.

Regards,

Pavan

Former Member
0 Kudos

Hi,

There is no limit. You can use any no. of times.

Regards,

Asreddy

Former Member
0 Kudos

I Friends,

Thanks for your replies. I got the answer and so I am closing the topic

0 Kudos

This message was moderated.