Skip to content

Commit

Permalink
Fixes greenplum db-driver's assign_sequential_id
Browse files Browse the repository at this point in the history
when run with many segments that showed PL/Python error by forcing
nested loop join algorithm
  • Loading branch information
netj committed Jan 24, 2017
1 parent 97c6df5 commit 80fbe11
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion database/db-driver/greenplum/db-assign_sequential_id
Original file line number Diff line number Diff line change
Expand Up @@ -67,12 +67,17 @@ CREATE TEMP TABLE idstats_bases AS
DISTRIBUTED RANDOMLY;
CREATE TEMP TABLE idstats_distributor as
SELECT generate_series(1, 1000000) id
SELECT generate_series(1, 100000) id
DISTRIBUTED BY (id);
ANALYZE idstats_bases;
ANALYZE idstats_distributor;
-- Have GP lay down data in a safe way for seqassign()
SET enable_hashjoin=off;
SET enable_mergejoin=off;
SET enable_nestloop=off;
SELECT seqassign(gpsid, true, pids, offsets)
FROM idstats_bases a, idstats_distributor b
WHERE a.gpsid = b.gp_segment_id;
Expand Down

0 comments on commit 80fbe11

Please sign in to comment.