Data Integration-Free and PayGo
- Data Integration-Free and PayGo
- All Products
util:iif(condition,val1,val2)
Argument
| Required/Optional
| Description
|
---|---|---|
condition
| Required
| The condition that you want to evaluate.
You can enter any valid transformation expression that evaluates to TRUE or FALSE.
|
val1
| Required
| The value that you want to return if the condition is TRUE. The return value is always the data type specified by this argument.
You can enter any valid transformation expression, including another iif expression. You can pass any data type except Binary.
|
val2
| Optional
| The value that you want to return if the condition is FALSE.
You can enter any valid transformation expression, including another iif expression. You can pass any data type except Binary.
|
util:iif(SALES > 100, EMP_NAME)
|
|
|
---|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
util:iif(SALES > 100, EMP_NAME, NULL)
|
|
|
---|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
util:iif(SALES < 100, 1, .3333)
util:iif(SALES > 0, util:iif(SALES < 50, SALARY1, util:iif(SALES < 100, SALARY2, util:iif( SALES < 200, SALARY3, BONUS))), 0 )