× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



SQL doesn't place a lock on the file. I've used insert, update and delete
with SQL while the files have been locked via programs lots of times with
no issues.

Thanks,
Tommy Holden



From:
Jonathan Mason <jonathan.mason@xxxxxxxxxxxxxxxx>
To:
midrange-l@xxxxxxxxxxxx
Date:
02/27/2008 08:26 AM
Subject:
Alternative to CPYF that doesn't apply a lock



Hi List

We have a program that makes use of the CPYF command to copy data from a
work file in QTEMP to a corresponding file in our data library.
Depending on the file being used there can be upwards to 100,000 records
being copied which is starting to cause a problem as the CPYF applies a
lock to the file being copied into.

The help text describes the restriction as:

o During the time a CPYF request is run, the file specified for
the To file (TOFILE) parameter may be locked (similar to an
*EXCL lock with no timeout) so that no access is possible.

Because the file is locked this is causing other programs to fail
CPF4128 and RPG1216 errors. I am thinking about putting in a change to
use an SQL insert instead of the CPYF and was wondering if anybody knows
whether or not using SQL would apply a lock to the receiving file.

Thanks in advance

Jonathan


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.