Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: inter references from one schema to another
On Tue, 21 Sep 2004 16:19:21 -0400, "Mark C. Stock" <mcstockX_at_Xenquery .com>
wrote:
>| grant references to schema2.tableA to schema1;
>
>yes, and yes -- but grant must be done when connected as 'schema2' (owner of
>object) and grant must be made directly to the user (schema) creating the FK
>constraint (i.e., not granted via a role)
You can't grant a "references" privilege to a role anyway - it makes no sense, so Oracle blocks it.
SQL> grant references on t to testrole;
grant references on t to testrole
*
ERROR at line 1:
ORA-01931: cannot grant REFERENCES to a role
-- Andy Hassall / <andy@andyh.co.uk> / <http://www.andyh.co.uk> <http://www.andyhsoftware.co.uk/space> Space: disk usage analysis toolReceived on Tue Sep 21 2004 - 15:37:37 CDT