diff options
author | Marc G. Fournier <scrappy@hub.org> | 1996-08-26 06:32:06 +0000 |
---|---|---|
committer | Marc G. Fournier <scrappy@hub.org> | 1996-08-26 06:32:06 +0000 |
commit | a2740a455f558a1b8b9cd1962f92980efa4a984a (patch) | |
tree | 6f52d29248743f100fa40c32cef2cd48043c43f5 /src/backend/commands/defind.c | |
parent | fe87dbb1403c557bee85115ebe12b69f9ee92ed3 (diff) | |
download | postgresql-a2740a455f558a1b8b9cd1962f92980efa4a984a.tar.gz postgresql-a2740a455f558a1b8b9cd1962f92980efa4a984a.zip |
There, now we support GiST...now what? :)
Diffstat (limited to 'src/backend/commands/defind.c')
-rw-r--r-- | src/backend/commands/defind.c | 28 |
1 files changed, 22 insertions, 6 deletions
diff --git a/src/backend/commands/defind.c b/src/backend/commands/defind.c index e350927da0b..48d1aa4f873 100644 --- a/src/backend/commands/defind.c +++ b/src/backend/commands/defind.c @@ -7,7 +7,7 @@ * * * IDENTIFICATION - * $Header: /cvsroot/pgsql/src/backend/commands/Attic/defind.c,v 1.3 1996/08/19 01:53:38 scrappy Exp $ + * $Header: /cvsroot/pgsql/src/backend/commands/Attic/defind.c,v 1.4 1996/08/26 06:30:23 scrappy Exp $ * *------------------------------------------------------------------------- */ @@ -86,8 +86,9 @@ DefineIndex(char *heapRelationName, Datum *parameterA = NULL; FuncIndexInfo fInfo; List *cnfPred = NULL; - - + bool lossy = FALSE; + List *pl; + /* * Handle attributes */ @@ -123,7 +124,19 @@ DefineIndex(char *heapRelationName, /* * Handle parameters * [param list is now different (NOT USED, really) - ay 10/94] + * + * WITH clause reinstated to handle lossy indices. + * -- JMH, 7/22/96 */ + foreach(pl, parameterList) { + int count; + char *ptr; + ParamString *param = (ParamString*)lfirst(pl); + + if (!strcasecmp(param->name, "islossy")) + lossy = TRUE; + } + /* @@ -167,9 +180,10 @@ DefineIndex(char *heapRelationName, index_create(heapRelationName, indexRelationName, - &fInfo, accessMethodId, + &fInfo, NULL, accessMethodId, numberOfAttributes, attributeNumberA, - classObjectId, parameterCount, parameterA, (Node*)cnfPred); + classObjectId, parameterCount, parameterA, (Node*)cnfPred, + lossy); }else { attributeNumberA = (AttrNumber *)palloc(numberOfAttributes * @@ -182,8 +196,10 @@ DefineIndex(char *heapRelationName, classObjectId, relationId); index_create(heapRelationName, indexRelationName, NULL, + ((IndexElem*)lfirst(attributeList))->tname, accessMethodId, numberOfAttributes, attributeNumberA, - classObjectId, parameterCount, parameterA, (Node*)cnfPred); + classObjectId, parameterCount, parameterA, (Node*)cnfPred, + lossy); } } |