Professional Web Applications Themes

stale cursor??? - IBM DB2

Hello All! We have a cursor in an application which fetches some data out of a DB2-DB. Normally it all works kind of well. We inserted a routine at certain places in order to do some perfomance-monitoring . Now we got the problem, that the cursor closes at some point although not all the data has been fetched and then next fetch of the application causes an error. Is there a way to force the cursor to stay open? Thanks for your hints or help in advance! Bye! Oli...

  1. #1

    Default stale cursor???

    Hello All!

    We have a cursor in an application which fetches some data out of a DB2-DB.
    Normally it all works kind of well.
    We inserted a routine at certain places in order to do some
    perfomance-monitoring .
    Now we got the problem, that the cursor closes at some point although not
    all the data has been fetched and then next fetch of the application causes
    an error.
    Is there a way to force the cursor to stay open?

    Thanks for your hints or help in advance!

    Bye!

    Oli


    Oliver Guest

  2. #2

    Default Re: stale cursor???

    If this is cli or jdbc, you should check your auto-commit on in your
    sp/udf (that's what you mean by routine, right)?

    The cursor will stay open until a tx boundary...if you need to commit,
    and leave the cursor open, you can create the cursor 'with hold' but if
    the commit/rollback is happening accidentally, then you need to find out
    where/why.

    Oliver Stratmann wrote:
     

    Sean Guest

  3. #3

    Default Re: stale cursor???

    Sadly this seems not to be the cause of the error.
    The cursor only reads data and performs no commit or rollback.
    The routine/program which was inserted into the code, sends time-based
    information to a programoutside our application which holds these
    information for later ysis. We think that a kind of timeout is performed
    on the cursor.
    We tried the Hold-option which did not solve the problem.

    Thanks for your hint, Sean!
    Have a nice Weekend!

    Bye!
    Oli


    "Sean McKeough" <ca.ibm.com> schrieb im Newsbeitrag
    news:bmoqaf$e1h$torolab.ibm.com... [/ref]
    DB2-DB. [/ref]
    not [/ref]
    causes 
    >[/ref]


    Oliver Guest

  4. #4

    Default Re: stale cursor???

    There's no concept of a cursor timeout...I'd suggest using a statement
    event monitor to see what's being done for that application id (what
    happens after the open, and before the -501 error).

    Oliver Stratmann wrote:
     [/ref]
    >
    > DB2-DB.
    > [/ref]
    >
    > not
    > [/ref]
    >
    > causes

    >>[/ref]
    >
    >[/ref]

    Sean Guest

  5. #5

    Default Re: stale cursor???

    "Oliver Stratmann" <de> wrote in message news:<bmopdl$pjdt7$news.uni-berlin.de>... 


    Is the error -501?

    When a cursor is openened, it is valid for the package
    schema.packageid is was openened in (as can be seen by testing, I do
    not know if this behavior is doented): DB2 UDB LUW when processing
    the fetch, will look at controlinfo in the package addressed at time
    of the fetch. So if a set current packageset has been issued between 2
    fetches, and the schema has changed, the fetch will not find his
    control info he expects to find in <schema at open cursor
    time><packageid> and will return -501 (assuming newschema.packageid
    exists, otherwise it will return -805). This is one occurence I know
    where a -501 can be returned.

    Bernard Dhooghe
    Bernard Guest

Similar Threads

  1. CSS local cache stale with WebDAV connection
    By JasonWoodward in forum Macromedia Contribute General Discussion
    Replies: 1
    Last Post: March 27th, 07:36 PM
  2. NFS file problem: maybe a stale/stuck handle?
    By Theodore W. Hall in forum Linux / Unix Administration
    Replies: 8
    Last Post: February 26th, 09:33 AM
  3. cursor 200-problem on mac but not pc? how to swap cursor image?
    By nickelsock webforumsuser@macromedia.com in forum Macromedia Director Lingo
    Replies: 5
    Last Post: August 2nd, 10:58 AM
  4. Cursor
    By Nikhil in forum Microsoft SQL / MS SQL Server
    Replies: 3
    Last Post: July 21st, 06:23 PM
  5. Change the "web hand" cursor in normal arrow cursor?
    By FB1976 in forum Adobe Dreamweaver & Contribute
    Replies: 1
    Last Post: July 9th, 07:15 PM

Bookmarks

Posting Permissions

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

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139