Hi All,
I have a requirement as mentioned below.
If Dept_no=100 Or Dept_no=101 Or Dept_no=102 Or Dept_no=103 Then 1203.24 Else If Dept_no=104 Then 12345.89 Else 0
Can any one of you please tell me how to use Case Structures in place of Nested If Conditions.
Thanks in Advance.
How to use Case Structures in place of nested if
Moderators: chulett, rschirm, roy
How to use Case Structures in place of nested if
Last edited by Team_2007 on Mon Jul 30, 2007 5:39 am, edited 1 time in total.
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
Not possible in a derivation or constraint expression, which yours appears to be.
It is possible in a routine, but yours does not have the form of a set of nested IF statements (containing assignment statements) that one would expect to find in a routine.
It is possible in a routine, but yours does not have the form of a set of nested IF statements (containing assignment statements) that one would expect to find in a routine.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.