Skip to content

Row Concatenation ​

The | operator creates sibling row sections. Here occupation and education appear as separate row groups stacked vertically.

Interactive Example ​

Try It
TABLE ROWS (occupation | education) COLS gender * income.sum;
Dataset:samplesoccupation, education, gender, income
Try Variations

Query Breakdown ​

  • TABLE - Declares a crosstab table statement
  • ROWS (occupation | education) - Row concatenation: occupation rows appear first, then education rows below as a separate section
  • COLS gender - Column dimension: gender values become column headers
  • income.sum - Measure: sum of income values for each cell

The | operator creates independent row sections that are stacked vertically, unlike * which nests dimensions hierarchically.

Powered by Malloy and DuckDB