Creating Queues and Queue tables
To determine whether there are user-enqueued
events in a queue, the queue table for the queue can be queried.
The following SQL statements show the messages in the buffered
queues:
show_buffered_queues.sql
--
*************************************************
-- Copyright © 2005 by Rampant TechPress
-- This script is free for non-commercial
purposes
-- with no warranties. Use at your own
risk.
--
-- To license this script for a commercial
purpose,
-- contact
rtp AT rampant.cc
--
*************************************************
COLUMN QUEUE_SCHEMA HEADING
'Queue Owner' FORMAT A15
COLUMN QUEUE_NAME HEADING
'Queue Name' FORMAT A15
COLUMN MEM_MSG HEADING 'LCRs
in Memory' FORMAT 99999999
COLUMN SPILL_MSGS HEADING
'Spilled LCRs' FORMAT 99999999
COLUMN NUM_MSGS HEADING 'Total
Captured LCRs|in Buffered Queue'
FORMAT 99999999
SELECT QUEUE_SCHEMA,
QUEUE_NAME,
(NUM_MSGS - SPILL_MSGS) MEM_MSG,
SPILL_MSGS, NUM_MSGS
FROM
V$BUFFERED_QUEUES
/