+ Reply to Thread
Results 1 to 2 of 2

Thread: Closing a Database File in CL

  1. #1

    Default Closing a Database File in CL

    On Wednesday, March 03, 1999, 09:08 AM, scott bernard wrote: I am reading in a database file in CL using RCVF. Normally in CL, I process until end of file. In this scenerio, I want to stop reading the file, delete it and end the program. I am receiving an error when I try to delete the file, while it has not been processed to EOF. The file appears to be open and thus cannot be deleted. All documentation that I have found indicates that the file will not be closed until EOF or the job ends. Can I close and delete a DB file in the same CL as the RCVF. Any suggestions would be appreciated. Thanks, Scott
    Have you tried the CL "CLOF" command? David Abramowitz

  2. #2
    Guest.Visitor Guest

    Default Closing a Database File in CL

    You could force EOF by sharing a previous OPNDBF's OPNID, and then in order each of POSDBF *END, RCVF, and CLOF. But most typically what you want requires simply adding before the DLTF, the request to: RCLRSC LVL(*CALLER) OPTION(*NORMAL) Regards, Chuck Comments provided "as is" with no warranties of any kind whatsoever.

+ Reply to Thread

Similar Threads

  1. Replies: 0
    Last Post: 08-18-2005, 09:51 AM
  2. message regarding database file
    By David Abramowitz in forum RPG
    Replies: 2
    Last Post: 03-20-2004, 10:32 AM
  3. closing a file in cl
    By Guest.Visitor in forum CL
    Replies: 6
    Last Post: 06-10-2003, 08:40 AM
  4. Message File to Database File
    By Guest.Visitor in forum IBM i (OS/400, i5/OS)
    Replies: 2
    Last Post: 06-19-2001, 07:03 PM
  5. Copy spool file back from database file
    By Guest.Visitor in forum Analysis
    Replies: 7
    Last Post: 04-03-2000, 12:24 PM

Posting Permissions

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