FILE LOCKING IN QTP (long)

Pablo Grim grim@gorge.net
Tue, 23 Jun 1998 10:18:56 -0700


Hello,

I've been reading the QTP (vms) reference manual trying to figure out file
locking without much success.  A number of terms are either not defined or
ambiguously defined.

My situation is this:  We have a 'central' application (payroll/HR) with a
number of spinoff ancilliary applications that have read and write access
to the files in payroll.  When payroll is processing, we generally lockout
the ancilliary apps to prevent the payroll qtps from crashing due to file
locking conflicts.  My customers would like the ability to leave the
ancilliary apps open during payroll processing.  Our QTPs contain the
statement SET LOCK RECORD UPDATE, and usually multiple SET FILE X OPEN
UPDATE SHARE.  READ SHARE, UPDATE SEMIEXCLUSIVE etc.  Rarely if ever an
EXCLUSIVE open.

Our ancilliary apps open most files as REFERENCE files in Quick, usually
with an explicit OPEN READ.   There are one or two files that are opened in
Quick for update.  Ancilliary batch file access is not an issue here (just
interactive).

Here's where I am confused:  What does the SET LOCK RECORD UPDATE actually
do?  The manual says, "locks a file for concurrent write".  Does this apply
to every file in the run?  Is the lock exclusive?  Does the lock apply to
all files or just output files?  What is meant by 'concurrent write'?

Also, how does this statement work with the SET FILE X OPEN UPDATE SHARE
type of statements?  Does it overide it?  Or visa versa?

What i would like to happen is to have everything shareable or at least
semi-exclusive so that QTPs and QUICK can access the same files at the same
time.  QTP should lock files during update, but only for the duration of
the update.

many thanks

paul  (OVMS, RMS, PH6.20)


= = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
Subscribe: "subscribe powerh-l" in message body to majordomo@lists.swau.edu
Unsubscribe: "unsubscribe powerh-l" in message to majordomo@lists.swau.edu
powerh-l@lists.swau.edu is gatewayed one-way to bit.listserv.powerh-l
This list is closed, thus to post to the list, you must be a subscriber.