+ Reply to Thread
Results 1 to 4 of 4

Thread: SQL Cursor Closing Without Issuing CLOSE

  1. #1
    Guest.Visitor Guest

    Default SQL Cursor Closing Without Issuing CLOSE

    On occasion in our nightly batch processing our applications will encounter an SQL -501 on a FETCH statement. Conditional logic is specified to only attempt a FETCH if the OPEN received a 0 error code. The high-level language we are using is COBOL. Are there any reasons why an SQL cursor inside COBOL would close without issuing a CLOSE statement?

  2. #2
    Guest.Visitor Guest

    Default SQL Cursor Closing Without Issuing CLOSE

    I encountered the same problem before. I found out that data types of my FETCH variables differ from the data types of the file I am selecting. Try checking this thing.....

  3. #3
    Guest.Visitor Guest

    Default SQL Cursor Closing Without Issuing CLOSE

    My only experience with COBOL/DB2 is in Pig-Iron mainframes, but how are you handling end of file?

  4. #4
    Guest.Visitor Guest

    Default SQL Cursor Closing Without Issuing CLOSE

    By monitoring for SQLCODE = 100

+ Reply to Thread

Similar Threads

  1. Issuing an EndJob for a Prestart Job
    By Guest.Visitor in forum CL
    Replies: 1
    Last Post: 03-22-2007, 05:01 AM
  2. closing a file in cl
    By Guest.Visitor in forum CL
    Replies: 6
    Last Post: 06-10-2003, 08:40 AM
  3. MC Closing: Is This A Trend?
    By frankgw@adelphia.net in forum Shooting the Breeze
    Replies: 0
    Last Post: 07-30-2002, 06:34 AM
  4. Midrange Closing??
    By Guest.Visitor in forum IBM i (OS/400, i5/OS)
    Replies: 1
    Last Post: 07-31-2001, 06:25 AM
  5. Closing a Database File in CL
    By David Abramowitz in forum Programming
    Replies: 1
    Last Post: 03-04-1999, 11:30 AM

Posting Permissions

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