diff options
author | Teodor Sigaev <teodor@sigaev.ru> | 2016-04-08 21:52:13 +0300 |
---|---|---|
committer | Teodor Sigaev <teodor@sigaev.ru> | 2016-04-08 21:52:13 +0300 |
commit | 8b99edefcab1e82c43139a2c7dc06d31fb27b3e4 (patch) | |
tree | 5428925d16447c4d204e0956e6d2ae1032847585 /src/backend/access/common/indextuple.c | |
parent | 35e2e357cb054dc9e5d890fe754c56f0722f015e (diff) | |
download | postgresql-8b99edefcab1e82c43139a2c7dc06d31fb27b3e4.tar.gz |
Revert CREATE INDEX ... INCLUDING ...
It's not ready yet, revert two commits
690c543550b0d2852060c18d270cdb534d339d9a - unstable test output
386e3d7609c49505e079c40c65919d99feb82505 - patch itself
Diffstat (limited to 'src/backend/access/common/indextuple.c')
-rw-r--r-- | src/backend/access/common/indextuple.c | 31 |
1 files changed, 0 insertions, 31 deletions
diff --git a/src/backend/access/common/indextuple.c b/src/backend/access/common/indextuple.c index 8884c1e56c..274a6c2e70 100644 --- a/src/backend/access/common/indextuple.c +++ b/src/backend/access/common/indextuple.c @@ -19,7 +19,6 @@ #include "access/heapam.h" #include "access/itup.h" #include "access/tuptoaster.h" -#include "utils/rel.h" /* ---------------------------------------------------------------- @@ -442,33 +441,3 @@ CopyIndexTuple(IndexTuple source) memcpy(result, source, size); return result; } - -/* - * Reform index tuple. Truncate nonkey (INCLUDING) attributes. - */ -IndexTuple -index_truncate_tuple(Relation idxrel, IndexTuple olditup) -{ - TupleDesc itupdesc = RelationGetDescr(idxrel); - Datum values[INDEX_MAX_KEYS]; - bool isnull[INDEX_MAX_KEYS]; - IndexTuple newitup; - int indnatts = IndexRelationGetNumberOfAttributes(idxrel); - int indnkeyatts = IndexRelationGetNumberOfKeyAttributes(idxrel); - - Assert(indnatts <= INDEX_MAX_KEYS); - Assert(indnkeyatts > 0); - Assert(indnkeyatts < indnatts); - - index_deform_tuple(olditup, itupdesc, values, isnull); - - /* form new tuple that will contain only key attributes */ - itupdesc->natts = indnkeyatts; - newitup = index_form_tuple(itupdesc, values, isnull); - newitup->t_tid = olditup->t_tid; - - itupdesc->natts = indnatts; - - Assert(IndexTupleSize(newitup) <= IndexTupleSize(olditup)); - return newitup; -} |