diff options
author | Teodor Sigaev <teodor@sigaev.ru> | 2018-04-12 16:37:22 +0300 |
---|---|---|
committer | Teodor Sigaev <teodor@sigaev.ru> | 2018-04-12 16:37:22 +0300 |
commit | c266ed31a8a3beed3533e6a78faeca78234cbd43 (patch) | |
tree | 7e84de64e37a2a7f17739fb28fcbcded62f704ff /src/backend/utils/adt/selfuncs.c | |
parent | 08ea7a2291db21a618d19d612c8060cda68f1892 (diff) |
Cleanup covering infrastructure
- Explicitly forbids opclass, collation and indoptions (like DESC/ASC etc) for
including columns. Throw an error if user points that.
- Truncated storage arrays for such attributes to store only key atrributes,
added assertion checks.
- Do not check opfamily and collation for including columns in
CompareIndexInfo()
Discussion: https://www.postgresql.org/message-id/5ee72852-3c4e-ee35-e2ed-c1d053d45c08@sigaev.ru
Diffstat (limited to 'src/backend/utils/adt/selfuncs.c')
-rw-r--r-- | src/backend/utils/adt/selfuncs.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/backend/utils/adt/selfuncs.c b/src/backend/utils/adt/selfuncs.c index fe606d72798..4b08cdb721a 100644 --- a/src/backend/utils/adt/selfuncs.c +++ b/src/backend/utils/adt/selfuncs.c @@ -7437,6 +7437,8 @@ gincost_pattern(IndexOptInfo *index, int indexcol, int32 searchMode = GIN_SEARCH_MODE_DEFAULT; int32 i; + Assert(indexcol < index->nkeycolumns); + /* * Get the operator's strategy number and declared input data types within * the index opfamily. (We don't need the latter, but we use |