⌘K ctrl+k
Search Shortcut cmd + k | ctrl + k
DuckDB 2.0 ドキュメント 全文検索
per page, with , order by , clip by
Results of 1 - 1 of about 1 for Bachelor (0.000 sec.)
GROUPING SETS 9414
GROUPING SETS , ROLLUP and CUBE can be used in the GROUP BY clause to perform a grouping over multiple dimensions within the same query. Note that this syntax is not compatible with GROUP BY ALL . Examples Compute the average income along t ... n a single query. CREATE TABLE students (course VARCHAR, type VARCHAR); INSERT INTO students (course, type) VALUES ('CS', 'Bachelor'), ('CS', 'Bachelor'), ('CS', 'PhD'), ('Math', 'Masters'), ('CS', NULL), ('CS', NULL), ('Math', NULL); SELECT course, type ... ts GROUP BY GROUPING SETS ((course, type), course, type, ()); course type count_star() Math NULL 1 NULL NULL 7 CS PhD 1 CS Bachelor 2 Math Masters 1 CS NULL 2 Math NULL 2 CS NULL 5 NULL NULL 3 NULL Masters 1 NULL Bachelor 2 NULL PhD 1 In the above query, ...
https://man.mtool.work/duckdb/2.0/sql/query_syntax/grouping_sets.html
PREV 1 NEXT
DuckDB 2.0 Documentation / man.mtool.work