We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
SELECT distinctを含むクエリのEXPLAIN出力中にあるnrowsの行数が実行のたびに変わってしまう。 再現性が低い現象であったがVACUUM ANALYZEを直前に実行すると100%再現することを確認。
実行計画:
1回目
Sort Output: customer.c_nation, lineorder.lo_orderpriority Sort Key: customer.c_nation, lineorder.lo_orderpriority -> HashAggregate Output: customer.c_nation, lineorder.lo_orderpriority Group Key: customer.c_nation, lineorder.lo_orderpriority -> Custom Scan (GpuPreAgg) on public.lineorder Output: customer.c_nation, lineorder.lo_orderpriority GPU Projection: customer.c_nation, lineorder.lo_orderpriority GPU Scan Quals: (lineorder.lo_shipmode = 'AIR'::bpchar) [rows: 6001260 -> 874784] GPU Join Quals [1]: (lineorder.lo_custkey = customer.c_custkey) ... [nrows: 874784 -> 174724]
2回目
Sort Output: customer.c_nation, lineorder.lo_orderpriority Sort Key: customer.c_nation, lineorder.lo_orderpriority -> HashAggregate Output: customer.c_nation, lineorder.lo_orderpriority Group Key: customer.c_nation, lineorder.lo_orderpriority -> Custom Scan (GpuPreAgg) on public.lineorder Output: customer.c_nation, lineorder.lo_orderpriority GPU Projection: customer.c_nation, lineorder.lo_orderpriority GPU Scan Quals: (lineorder.lo_shipmode = 'AIR'::bpchar) [rows: 6001260 -> 845177] GPU Join Quals [1]: (lineorder.lo_custkey = customer.c_custkey) ... [nrows: 845177 -> 174724]
データ投入
DROP TABLE IF EXISTS customer; CREATE TABLE customer ( c_custkey integer NOT NULL, c_name character varying(25), c_address character varying(25), c_city character(10), c_nation character(15), c_region character(12), c_phone character(15), c_mktsegment character(10) ); DROP TABLE IF EXISTS lineorder; CREATE TABLE lineorder ( lo_orderkey bigint, lo_linenumber integer, lo_custkey integer, lo_partkey integer, lo_suppkey integer, lo_orderdate integer, lo_orderpriority character(15), lo_shippriority character(1), lo_quantity numeric, lo_extendedprice numeric, lo_ordertotalprice numeric, lo_discount numeric, lo_revenue numeric, lo_supplycost numeric, lo_tax numeric, lo_commit_date character(8), lo_shipmode character(10) ); \copy customer FROM PROGRAM './ssbm/dbgen-ssbm -s 1 -X -Tc' DELIMITER '|' \copy lineorder FROM PROGRAM './ssbm/dbgen-ssbm -s 1 -X -Tl' DELIMITER '|'
再現クエリ(VACUUM ANALYZEを直前に実行すると100%再現)
VACUUM ANALYZE; explain (verbose, costs off) SELECT * FROM reference EXCEPT select distinct c_nation, lo_orderpriority from lineorder, customer where lo_custkey = c_custkey and c_region = 'AMERICA' and lo_shipmode = 'AIR' order by c_nation, lo_orderpriority;
The text was updated successfully, but these errors were encountered:
これ、最新版のPG-Stromだと再現しなくなってますね・・・。 (今日、何回かregression testを流しても、ココで引っかからなかった)
Sorry, something went wrong.
No branches or pull requests
SELECT distinctを含むクエリのEXPLAIN出力中にあるnrowsの行数が実行のたびに変わってしまう。
再現性が低い現象であったがVACUUM ANALYZEを直前に実行すると100%再現することを確認。
実行計画:
1回目
2回目
データ投入
再現クエリ(VACUUM ANALYZEを直前に実行すると100%再現)
The text was updated successfully, but these errors were encountered: