how to find open cursors
DBAsupport.com Forums - Powered by vBulletin
Results 1 to 7 of 7

Thread: how to find open cursors

  1. #1
    Join Date
    Dec 2000
    Posts
    255
    HI All

    Can anyone tell me how to find the No. of Cursors which are Open and their details. The no. of rows in view V$OPEN_CURSOR are more than my limit set in init.ora file so I guess its incorrect. Can Anyone tell me how to find correct no. of actuall OPEN Cursors.

    Amol

  2. #2
    Join Date
    Oct 2000
    Posts
    467

    Hi

    I think the open_cursors init.ora parameter is a value set for a particular session and not a total for all sessions. The value in v$open_cursors is based on a particular session (sid, username) and it should not exceed the value set in init.ora. Can anyone pls correct me if I'm wrong ?

    Cheers,
    Vinit

  3. #3
    Join Date
    Jun 2000
    Location
    Madrid, Spain
    Posts
    7,447
    it is per session, also v$open_cursor dooes not show all open cursors. it shows more than that, the best option to find the number of open cursors is from v$sysstat

    select * from v$sysstat where statistic#=3

  4. #4
    Join Date
    Oct 2000
    Posts
    467

    Difference

    Pando,
    there seems to b a lot of difference between the values in v$open_cursors and the value of open_cursors current in v$systat. Now which one is correct, I think it is from v$open_cursors.

    Regards,
    Vinit
    Vinit

  5. #5
    Join Date
    Jun 2000
    Location
    Madrid, Spain
    Posts
    7,447
    no, the one in sysstat is correct, v$open_cursor shows more than open cursors, in plsql v2 the cursors are not closed once they are used, they are kind of cached. Also v$sysstat shows cursors that are opened but not parsed whereas v$open_cursor shows cursors that are opend and parsed

  6. #6
    Join Date
    Oct 2000
    Posts
    467

    thanx

    Thanx for the clarification, Pando..!!

    Cheers
    Vinit

  7. #7
    Join Date
    Jun 2001
    Location
    Helsinki. Finland
    Posts
    3,938

    Re: thanx

    You may increase OPEN_CURSORS in order to reduce waits!


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Click Here to Expand Forum to Full Width