Emits a Pivot (PLAN §11.12) as
<input>->select(~[<rows>, <column>, <aggregated>])->pivot(~<column>, [<values>], ~cube_pivot: x|… : y|…)->cast(@Relation<(…)>)->rename(…)…:
the select keeps the row columns only, since every column the pivot
doesn't consume makes rows; the static pivot makes one column per value,
typed Relation<Any>, so the cast names each as the node's schema types
it; then each is renamed to its column name. The emitter checks the columns
come out as the node's inferred schema, so a mismatch fails in Cube.
Emits a Pivot (PLAN §11.12) as
<input>->select(~[<rows>, <column>, <aggregated>])->pivot(~<column>, [<values>], ~cube_pivot: x|… : y|…)->cast(@Relation<(…)>)->rename(…)…: theselectkeeps the row columns only, since every column the pivot doesn't consume makes rows; the static pivot makes one column per value, typedRelation<Any>, so thecastnames each as the node's schema types it; then each is renamed to its column name. The emitter checks the columns come out as the node's inferred schema, so a mismatch fails in Cube.