1
0
mirror of https://github.com/postgres/postgres.git synced 2025-08-22 21:53:06 +03:00

Opclasses live in namespaces. I also took the opportunity to create

an 'opclass owner' column in pg_opclass.  Nothing is done with it at
present, but since there are plans to invent a CREATE OPERATOR CLASS
command soon, we'll probably want DROP OPERATOR CLASS too, which
suggests that a notion of ownership would be a good idea.
This commit is contained in:
Tom Lane
2002-04-17 20:57:57 +00:00
parent d85a81cbc3
commit 27a54ae282
25 changed files with 445 additions and 170 deletions

View File

@@ -15,7 +15,7 @@
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/nodes/copyfuncs.c,v 1.178 2002/04/16 23:08:10 tgl Exp $
* $Header: /cvsroot/pgsql/src/backend/nodes/copyfuncs.c,v 1.179 2002/04/17 20:57:56 tgl Exp $
*
*-------------------------------------------------------------------------
*/
@@ -1714,8 +1714,7 @@ _copyIndexElem(IndexElem *from)
newnode->name = pstrdup(from->name);
Node_Copy(from, newnode, funcname);
Node_Copy(from, newnode, args);
if (from->class)
newnode->class = pstrdup(from->class);
Node_Copy(from, newnode, opclass);
return newnode;
}

View File

@@ -20,7 +20,7 @@
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/nodes/equalfuncs.c,v 1.126 2002/04/16 23:08:10 tgl Exp $
* $Header: /cvsroot/pgsql/src/backend/nodes/equalfuncs.c,v 1.127 2002/04/17 20:57:56 tgl Exp $
*
*-------------------------------------------------------------------------
*/
@@ -1599,7 +1599,7 @@ _equalIndexElem(IndexElem *a, IndexElem *b)
return false;
if (!equal(a->args, b->args))
return false;
if (!equalstr(a->class, b->class))
if (!equal(a->opclass, b->opclass))
return false;
return true;

View File

@@ -5,7 +5,7 @@
* Portions Copyright (c) 1996-2001, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* $Header: /cvsroot/pgsql/src/backend/nodes/outfuncs.c,v 1.155 2002/04/16 23:08:10 tgl Exp $
* $Header: /cvsroot/pgsql/src/backend/nodes/outfuncs.c,v 1.156 2002/04/17 20:57:56 tgl Exp $
*
* NOTES
* Every (plan) node in POSTGRES has an associated "out" routine which
@@ -217,8 +217,8 @@ _outIndexElem(StringInfo str, IndexElem *node)
_outNode(str, node->funcname);
appendStringInfo(str, " :args ");
_outNode(str, node->args);
appendStringInfo(str, " :class ");
_outToken(str, node->class);
appendStringInfo(str, " :opclass ");
_outNode(str, node->opclass);
}
static void