mirror of
https://github.com/postgres/postgres.git
synced 2025-07-27 12:41:57 +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:
@ -1,5 +1,5 @@
|
||||
<!--
|
||||
$Header: /cvsroot/pgsql/doc/src/sgml/xindex.sgml,v 1.23 2002/03/27 19:19:23 petere Exp $
|
||||
$Header: /cvsroot/pgsql/doc/src/sgml/xindex.sgml,v 1.24 2002/04/17 20:57:56 tgl Exp $
|
||||
PostgreSQL documentation
|
||||
-->
|
||||
|
||||
@ -280,10 +280,12 @@ SELECT oid FROM pg_am WHERE amname = 'btree';
|
||||
<classname>pg_opclass</classname>:
|
||||
|
||||
<programlisting>
|
||||
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 = 'btree'),
|
||||
'complex_abs_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 = 'complex'),
|
||||
true,
|
||||
0);
|
||||
@ -292,9 +294,9 @@ SELECT oid, *
|
||||
FROM pg_opclass
|
||||
WHERE opcname = 'complex_abs_ops';
|
||||
|
||||
oid | opcamid | opcname | opcintype | opcdefault | opckeytype
|
||||
--------+---------+-----------------+-----------+------------+------------
|
||||
277975 | 403 | complex_abs_ops | 277946 | t | 0
|
||||
oid | opcamid | opcname | opcnamespace | opcowner | opcintype | opcdefault | opckeytype
|
||||
--------+---------+-----------------+--------------+----------+-----------+------------+------------
|
||||
277975 | 403 | complex_abs_ops | 11 | 1 | 277946 | t | 0
|
||||
(1 row)
|
||||
</programlisting>
|
||||
|
||||
|
Reference in New Issue
Block a user