Formula operators apply if/then/else conditions in Invoca formulas, returning true, false, or a predetermined value.Formula operators let you apply
if/then/else conditions in your formulas. Use operators in your formulas so they return true, false, or a predetermined value.
Formula operators
Calculate the conditional sum
Calculating the conditional sum is useful when you want to see, for example, the total revenue for a product by region. Conditional sum formulas follow this syntax:if (some condition) then (Measure) else 0. You can also use a sum_if formula, for example:
- Create the formula:
This gives you the number of iPads that were bought.
- Create another formula:
This gives you the number of Galaxy tablets that were bought.
- Using nested formulas, combine these two formulas:
- Search using the
f1formula to find the revenue generated by both products.