DBAsupport.com Forums - Powered by vBulletin
Page 1 of 2 12 LastLast
Results 1 to 10 of 11

Thread: open cursors

Hybrid View

  1. #1
    Join Date
    Oct 2000
    Posts
    139
    Hi

    I am querying v$open_cursor and it always shows myand other users last SQL statement, does this mean that my last SQL cursor is not closed?

  2. #2
    Join Date
    Jan 2001
    Posts
    61

    Thumbs up

    When you execute your statement it opens a cursor(Implicit Cursor) for you.Once it returns you the result then only that Cursor is closed. Your query showing your statement with OPEN CURSOR AS IT'S WAITING THE RESPONSE FROM THE DATABASE.

  3. #3
    Join Date
    Oct 2000
    Posts
    139
    I did

    select * from emp;

    then I got the results back, now it suppose that if if I query v$open_cursor I must not see anything right? But I am seeing

    select * from emp

    in v$open_cursor

    it´s not closed?

  4. #4
    Join Date
    Oct 2000
    Posts
    139
    hi can anyone help me with this

  5. #5
    Join Date
    Feb 2000
    Location
    Washington DC
    Posts
    1,843

    Arrow

    Iam not sure. But, Definition of View says:

    V$OPEN_CURSOR lists cursors that each user session currently has opened and parsed.

    From my understanding, its showing up cuz, its parsed and its available in shared SQL area. Thats why. Doensn' mean its not closed.

  6. #6
    Join Date
    Nov 2000
    Posts
    212
    try to use V$SESSION_CURSOR_CACHE
    it has field OPEN: NUMBER --Current number of open cursors

  7. #7
    Join Date
    Jun 2000
    Location
    Madrid, Spain
    Posts
    7,447
    hm I dunno neither

    but when I query open from V$SESSION_CURSOR_CACHE

    I get 0? But there are at leats 8 cursors opened :D

  8. #8
    Join Date
    Nov 2000
    Posts
    212

    Red face

    "but when I query open from V$SESSION_CURSOR_CACHE I get 0? But there are at leats 8 cursors opened "
    in the same session?


  9. #9
    Join Date
    Jun 2000
    Location
    Madrid, Spain
    Posts
    7,447
    no in 10 sessions, so that column only displays current session?

  10. #10
    Join Date
    Nov 2000
    Posts
    212
    "no in 10 sessions, so that column only displays current session?"
    from definition (sorry, loose description) it seems so.

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