Core Syntax
A complete reference for SemQL syntax and clauses
SELECT
-- Dimensions (attributes you slice by)
SELECT name, region, created_at FROM customers
-- Measures (pre-aggregated metrics)
SELECT total_revenue, order_count FROM sales
-- With model qualifier (use when field names are ambiguous)
SELECT organizations.name, users.name FROM organizations JOIN users ...
-- Aliases
SELECT name AS organization_name, total_revenue AS revenue FROM organizations
-- Literals
SELECT name, 'active' AS status FROM organizations[active_only]FROM
Applying predefined filters
WHERE
GROUP BY
HAVING
ORDER BY / LIMIT
JOIN
WITH (CTEs)
UNION / UNION ALL
Window Functions
Ranking
Running totals
Period-over-period comparisons
Partitioned windows
Subqueries
What SemQL does NOT support
Supported Functions
Aggregate
Function
Description
Date / Time
Function
Description
String
Function
Description
Math
Function
Description
Geo
Function
Description
Last updated