問題:您想在 Oracle 中顯示開啟的遊標。解決方案我們可以查詢資料字典以確定每個會話中開啟的遊標數量。“V$SESSION”比“V$OPEN_CURSOR”更準確地顯示當前開啟的遊標數量。示例 select a.value , c.username , c.machine , c.sid , c.serial# from v$sesstat a , v$statname b , v$session c where a.statistic# = b.statistic# and c.sid = a.sid and b.name = 'opened cursors current' and a.value != 0 and c.username IS NOT NULL order by 1, 2; OPEN_CURSORS 初始化引數決定會話可以開啟的最大遊標數。閱讀更多