VALUES
Applies to: ✅ Data Cloud SQL ✅ Tableau Hyper API
VALUES
retrieves a set of rows hardcoded in the SQL query. You can use VALUES
to provide a set of constant rows as a subquery in a larger
SELECT
query. You can use VALUES
as a top-level command or as a space-saving syntax variant in parts of complex queries.
Only these operators and clauses are supported.
- UNION, INTERSECT, EXCEPT
- ORDER BY
- LIMIT, OFFSET, and FETCH clauses can be used with TABLE.
VALUES
doesn’t support the WHERE clause and aggregation. For more information on clauses and operations, see Clauses.
The columns produced by the VALUES
query are named column1
, column2
, and so on.
Return a single row, containing two columns.
The VALUES
clause can also contain arbitrarily complex expressions:
To return multiple rows from a VALUES
clause, use multiple
comma-separated bracketed lists:
You can also use ORDER BY
, OFFSET
, and LIMIT
on a VALUES
clause.