Hi All,
Boolean operators AND, OR, and NOT have different precedence in DataWindow expressions than in PowerScript.
Also, DataWindow expressions have SQL like operators that don't exist in PowerScript.
I advise you always use parenthesis to avoid undesired surprises. Even when you think expression is simple, you may get fooled! Earlier today I fooled myself once more - because I skipped parenthesis.
Environment | PowerScript | DataWindow Expressions |
Boolean and relational operator precedence |
|
|
Example | NOT false OR true | NOT false OR true |
Evaluates as | (NOT false) OR true | NOT(false OR true) |
Result | true | false |
Watch out for operator precedence while you create DataWindow expressions.
HTH /Michael