Re: dbms_aq.dequeue - FIFO when using Correlation ID

From: Mathias Magnusson <>
Date: Thu, 4 Jun 2009 08:23:58 +0200
Message-ID: <>

My memory on this is foggy. But isn't the recommended (by Oracle) solution to put the message id last in the corr id to make it unique and in the oder of enqueuing? I'm not sure hot to get that value at the time of enqueuing though. So, I may be wrong on how this typically is solved.

Why are you using corr id to specify a queue? Why not just use different queues?

I was under the impression that ordered would still be honored within the set of messages a corr id is valid for. I guess I missed the same passage as you just found.


On Thu, Jun 4, 2009 at 7:16 AM, Steve Baldwin <>wrote:

> Hi,
> I've implemented a dbms_pipe clone using AQ (we're using RAC which doesn't
> support dbms_pipe - long story). Basically I've simulated dbms_pipe message
> queues by using CorrelationID's.
> Unfortunately, it seems that I missed the 'gotcha' in the Oracle
> documentation - (when retrieving a message by CorrelationID) "If more than
> one message satisfies the pattern, then the order of dequeuing is
> undetermined". It is critical in my scenario that messages for a given
> 'queue' (Correlation ID) are dequeued in the order they were enqueued.
> Does anyone have a trick or suggestion to solve my dilemma. We're using
> in case it matters.
> Thanks,
> Steve
> ------------------------
> This email is intended solely for the use of the addressee and may
> contain information that is confidential, proprietary, or both.
> If you receive this email in error please immediately notify the
> sender and delete the email.
> --

Received on Thu Jun 04 2009 - 01:23:58 CDT

Original text of this message