Skip to content

Commit

Permalink
distributor use 1M series for id assignment
Browse files Browse the repository at this point in the history
  • Loading branch information
zifeishan authored and netj committed Jan 24, 2017
1 parent 10bed5a commit a92e0e0
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion database/db-driver/greenplum/db-assign_sequential_id
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ done
# Use larger table idstats_distributor to ensure stats are processed by all segments.
# Assuming 1000 rows cover all segments.
# Update (Jan3): 1000 rows sometimes fail to cover all segments after join, increased to 10000
# Update (Jan6): increased to 1M as ~100shards still cause failure
# (see explain analyze)
SQL="$SQL
CREATE TEMP TABLE idstats_rollup AS
Expand All @@ -66,7 +67,7 @@ CREATE TEMP TABLE idstats_bases AS
DISTRIBUTED RANDOMLY;
CREATE TEMP TABLE idstats_distributor as
SELECT generate_series(1, 10000) id
SELECT generate_series(1, 1000000) id
DISTRIBUTED BY (id);
ANALYZE idstats_bases;
Expand Down

0 comments on commit a92e0e0

Please sign in to comment.