on 10-20-2008 8:01 PM
Hi all,
I want to create some conditional logic in Bex formula. The logic I need is:
IF (KeyFigA exists) THEN (use KeyFigA) ELSE IF (KeyFigB exists) THEN (use KeyFigB) ELSE (use KeyFigC)
I am a bit confused on the operators I need to use...Can anyone help?
Thanks
CM
Courtney,
It depends on what you mean by "EXISTS" here. If it means that the value is <> 0, then the logic would be:
( KFA .NE. 0 ) * KFA + (KFA == 0 ) * (KFB .NE. 0 ) * KFB + ( KFA == 0 ) * ( KFB == 0 ) * KFC
Note: ".NE." above will actually be a < followed by >, but this silly editor doesn't like those characters.
Hope this helps...
Bob
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
( KFA <> 0 ) * KFA + (KFA == 0 ) * (KFB <> 0 ) * KFB + ( KFA == 0 ) * ( KFB == 0 ) * KFC
Just as Bob said, however, you need to use the <> symbols for .NE.. You can also select the symbols in the Boolean Logic section.
Brian
I think I know why Bob added the .NE., even though I can see them in my edit screen, they are not showing up in the message after I save it.
Edited by: Brian Anthony on Oct 20, 2008 4:39 PM
This works perfectly. Thank you!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
83 | |
10 | |
10 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.