aboutsummaryrefslogtreecommitdiff
path: root/contrib/intarray
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2002-04-17 20:57:57 +0000
committerTom Lane <tgl@sss.pgh.pa.us>2002-04-17 20:57:57 +0000
commit27a54ae282d74ee471a5b34d136fe3d4f894a9de (patch)
tree59aedb6b78d8b4ff8f26f6a945799a443dd6d571 /contrib/intarray
parentd85a81cbc384614eec525ca19e1cf48687643725 (diff)
downloadpostgresql-27a54ae282d74ee471a5b34d136fe3d4f894a9de.tar.gz
postgresql-27a54ae282d74ee471a5b34d136fe3d4f894a9de.zip
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.
Diffstat (limited to 'contrib/intarray')
-rw-r--r--contrib/intarray/_int.sql.in8
1 files changed, 6 insertions, 2 deletions
diff --git a/contrib/intarray/_int.sql.in b/contrib/intarray/_int.sql.in
index 61f2cbd3f6f..60a4972984b 100644
--- a/contrib/intarray/_int.sql.in
+++ b/contrib/intarray/_int.sql.in
@@ -144,10 +144,12 @@ CREATE FUNCTION g_int_same(_int4, _int4, opaque) RETURNS opaque
-- register the default opclass for indexing
-INSERT INTO pg_opclass (opcamid, opcname, opcintype, opcdefault, opckeytype)
+INSERT INTO pg_opclass (opcamid, opcname, opcnamespace, opcowner, opcintype, opcdefault, opckeytype)
VALUES (
(SELECT oid FROM pg_am WHERE amname = 'gist'),
'gist__int_ops',
+ (SELECT oid FROM pg_namespace WHERE nspname = 'pg_catalog'),
+ 1, -- UID of superuser is hardwired to 1 as of PG 7.3
(SELECT oid FROM pg_type WHERE typname = '_int4'),
true,
0);
@@ -300,10 +302,12 @@ CREATE FUNCTION g_intbig_same(_int4, _int4, opaque) RETURNS opaque
AS 'MODULE_PATHNAME' LANGUAGE 'c';
-- register the opclass for indexing (not as default)
-INSERT INTO pg_opclass (opcamid, opcname, opcintype, opcdefault, opckeytype)
+INSERT INTO pg_opclass (opcamid, opcname, opcnamespace, opcowner, opcintype, opcdefault, opckeytype)
VALUES (
(SELECT oid FROM pg_am WHERE amname = 'gist'),
'gist__intbig_ops',
+ (SELECT oid FROM pg_namespace WHERE nspname = 'pg_catalog'),
+ 1, -- UID of superuser is hardwired to 1 as of PG 7.3
(SELECT oid FROM pg_type WHERE typname = '_int4'),
false,
0);