IF wicket=1 THEN
************* QlikView Help **************** if(condition , then , else) The three parameters condition, then and else are all expressions. The first one, condition, is interpreted logically. The two other ones, then and else, can be of any type. They should preferably be of the same type. If condition is true, the function returns the value of the expression then. If condition is false, the function returns the value of the expression else. Example: if( Amount>= 0, 'OK', 'Alarm' )
The expression "if(wicket=1,[run])" is not a statement - it is a function. Hence, if the condition (wicket=1) is evaluated as true, then the function returns the field value of [run], else it returns NULL.
Optionally, you can use a third parameter also, to define what the function should return in the "else" case.
There is also an IF statement in QlikView that can be used a s control statement:
IF <condition> THEN
However, this is used "outside" the Load statement, whereas the if-function is used "inside" the Load statement. (Or whenever you have an expression that needs the if to return a value.)