Unable To Dequeue/Enqueue From/To Aqs In Other Users' Schema Ora-25205 (Doc ID 292478.1)

Last updated on MAY 04, 2017

Applies to:

Oracle Database - Enterprise Edition - Version 9.2.0.5 and later
Information in this document applies to any platform.

Symptoms

Trying to use synonym for queue for enqueue/dequeue fails with error ORA-25205.
Following steps can exhibit the error :

Create queue TEST_Q in the Q_OWNER schema.
User Q_OWNER can enqueue to and dequeue from TEST_Q successfully.

Grant enqueue and dequeue on this TEST_Q to SYN_USER.
(Or grant system previliges : enqueue_any and dequeue_any)

Connect as SYN_USER and create synonym SYN_Q for Q_OWNER.TEST_Q.
(Or create public synonym)

Then, connect as SYN_USER and tried to enqueue to or dequeue from SYN_Q.
For eample :

begin
dbms_aq.enqueue(
queue_name=>'SYN_Q',
.....);
end;
/

It fails with error :

ORA-25205: the QUEUE SYN_USER.SYN_Q does not exist
ORA-06512: at "SYS.DBMS_AQ", line 221
ORA-06512: at line 24

Changes

Created synonym for queue and trying to use it for enqueue/dequeue

Cause

Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms