should be it
This commit is contained in:
29
external/duckdb/benchmark/tpch_plan_cost/queries/q16.sql
vendored
Normal file
29
external/duckdb/benchmark/tpch_plan_cost/queries/q16.sql
vendored
Normal file
@@ -0,0 +1,29 @@
|
||||
SELECT
|
||||
p_brand,
|
||||
p_type,
|
||||
p_size,
|
||||
count(DISTINCT ps_suppkey) AS supplier_cnt
|
||||
FROM
|
||||
partsupp,
|
||||
part
|
||||
WHERE
|
||||
p_partkey = ps_partkey
|
||||
AND p_brand <> 'Brand#45'
|
||||
AND p_type NOT LIKE 'MEDIUM POLISHED%'
|
||||
AND p_size IN (49, 14, 23, 45, 19, 3, 36, 9)
|
||||
AND ps_suppkey NOT IN (
|
||||
SELECT
|
||||
s_suppkey
|
||||
FROM
|
||||
supplier
|
||||
WHERE
|
||||
s_comment LIKE '%Customer%Complaints%')
|
||||
GROUP BY
|
||||
p_brand,
|
||||
p_type,
|
||||
p_size
|
||||
ORDER BY
|
||||
supplier_cnt DESC,
|
||||
p_brand,
|
||||
p_type,
|
||||
p_size;
|
||||
Reference in New Issue
Block a user