Skip to main content
Routes the test value into one of several branches based on a check, with a required fallback for “none of the above”. Per dated property in the test value, Switch picks the first branch whose check conforms with the value, or falls through to the fallback. Pair with Each when downstream branches should iterate inside a list.

Inputs

  • Test Value — the dated property (or list of them) to route.

Outputs

  • Check — connect one or more nodes whose result decides the branch. The matched branch always carries the original test value onward (with its valid_from intact), not the check node’s own output.
  • Fallback (required) — taken when no Check conforms.
  • Empty — taken when the test input is an empty timeline. Wire a subgraph here to emit a default value when the upstream has no data. If unwired, Switch emits an empty timeline directly.
  • Result — the merged result after routing every dated property.

How conformity is decided

  • Value nodes (Constant, Attribute, Date Today, arithmetic, …) conform when their output equals the test value.
  • Predicate nodes (Equals, Match, Greater Than, Less Than, …) conform when their output is true.
  • An exact value match wins over a passing predicate. More than one match in the winning tier is nondeterministic and errors. A check whose subgraph errors simply doesn’t match.

Ports