Everything Else
Undefined Values and If-Then-Else Logic

The If-Then-Else tile is a tool for setting up conditions. It is very useful when the logic is understood.

The input should always be a True/False statement:

If the input of the If hole is:

  • True, the output of the tile will be the Then hole.
  • False, the output of the tile will be the Else hole.
  • Undefined, there will ne no output.

The If hole of the If-Then-Else tile must be defined in order for the tile to output the Then or Else hole. Therefore, you must indicate if an undefined value should be treated as True or False if there is any chance that the input could be undefined.

Consider this example: You have an order entry systm that automatically gives a 35% discount to preferred customers. The "Discount" Abacus determines whether or not this discount applies:

  • If "Type" = "Pfrd," the output of the If hole is False and the retail price in the Else hole will be computed.
  • If the "Type" = "Pfrd," the output of the If hole is True and the 35% discount will be computed in the Then hole.
  • If the "Type" is undefined, the calculation will not continue to the Then or Else holes. Instead, the result is undefined and neither the discount nor the retail price will appear.

To avoid this, Helix needs to treat an undefined "Type" as if it is False (i.e., not equal to "Pfrd" in this case). Use the Undefined becomes tile.

If the "Type" is undefined, the If hole will treat it as False. The customer will not receive a discount and will be charged the retail price from the Else hole.