Data Shaping Query Language allows you to create queries to transform your data.
A query is a series of clauses that allow you to define the output data
to return. It can contain a single block or multiple blocks separated by the UNION ALL
keywords. These allow you to combine the results
of several query blocks.
A query block can be a single SELECT
clause or a combination of a
SELECT
clause and a FROM WHERE
clause, which can
contain UNNEST
clauses, followed by a JOIN
clause if
needed.
The result of a query block can be:
- A single value.
- A record, or object, which contains a sequence of key-value pairs.
- A collection, or array, which can contains several values, records or collections.
When the result is a collection, it can be modified by output modifiers
such as the ORDER BY
clause.