diff options
author | Robert Haas <rhaas@postgresql.org> | 2017-02-19 15:53:59 +0530 |
---|---|---|
committer | Robert Haas <rhaas@postgresql.org> | 2017-02-19 15:57:55 +0530 |
commit | 0414b26bac09379a4cbf1fbd847d1cee2293c5e4 (patch) | |
tree | 16554f77178d068e27bd53c2404a6f8468c90746 /src/backend/optimizer/path/indxpath.c | |
parent | 16be2fd100199bdf284becfcee02c5eb20d8a11d (diff) | |
download | postgresql-0414b26bac09379a4cbf1fbd847d1cee2293c5e4.tar.gz postgresql-0414b26bac09379a4cbf1fbd847d1cee2293c5e4.zip |
Add optimizer and executor support for parallel index-only scans.
Commit 5262f7a4fc44f651241d2ff1fa688dd664a34874 added similar support
for parallel index scans; this extends that work to index-only scans.
As with parallel index scans, this requires support from the index AM,
so currently parallel index-only scans will only be possible for btree
indexes.
Rafia Sabih, reviewed and tested by Rahila Syed, Tushar Ahuja,
and Amit Kapila
Discussion: http://postgr.es/m/CAOGQiiPEAs4C=TBp0XShxBvnWXuzGL2u++Hm1=qnCpd6_Mf8Fw@mail.gmail.com
Diffstat (limited to 'src/backend/optimizer/path/indxpath.c')
-rw-r--r-- | src/backend/optimizer/path/indxpath.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/backend/optimizer/path/indxpath.c b/src/backend/optimizer/path/indxpath.c index 56eccafd7b0..d92826bcfc9 100644 --- a/src/backend/optimizer/path/indxpath.c +++ b/src/backend/optimizer/path/indxpath.c @@ -1048,9 +1048,9 @@ build_index_paths(PlannerInfo *root, RelOptInfo *rel, /* * If appropriate, consider parallel index scan. We don't allow - * parallel index scan for bitmap or index only scans. + * parallel index scan for bitmap index scans. */ - if (index->amcanparallel && !index_only_scan && + if (index->amcanparallel && rel->consider_parallel && outer_relids == NULL && scantype != ST_BITMAPSCAN) { @@ -1104,7 +1104,7 @@ build_index_paths(PlannerInfo *root, RelOptInfo *rel, result = lappend(result, ipath); /* If appropriate, consider parallel index scan */ - if (index->amcanparallel && !index_only_scan && + if (index->amcanparallel && rel->consider_parallel && outer_relids == NULL && scantype != ST_BITMAPSCAN) { |