[Date Prev][Date Next][Thread Prev][Thread Next]
[Author Index] [Date Index] [Thread Index]
[SQR-USERS Info] [SQRUG Home Page]

Re: Lock Syntax on Begin-Select



Huey,

For DB2 we used 'with UR' with the from clause, this ensured that the table
was read without lock
eg.
BEGIN-SELECT ON-ERROR=CANNOT-SELECT
IFS.SUBCUST_USE_SW
  let $subcust_use_sw = rtrim(&ifs.subcust_use_sw,' ')
from PS_INSTALLATION_FS IFS with UR
END-SELECT

There should a similar command for Sybase. check your sybase documentation.



-----Original Message-----
From: Discussion of SQR, Brio Technology's database reporting language
[mailto:SQR-USERS@list.iex.net]On Behalf Of htreadwell(contr-comp)
Sent: Tuesday, January 04, 2000 11:17 AM
To: SQR-USERS@list.iex.net
Subject: Lock Syntax on Begin-Select


We have an SQR program running against a Sybase database that is locking out
another process .  To resolve the lock, we attempted to make the SQR query
read only by using the following syntax:

        Begin-Select -LOCK RO

The syntax is correct based on the manual, however, when we tried to compile
the SQR program, we got a 3721 error - Bad param found on 'BEGIN-SELECT'
line.

Is the syntax database dependent?  Can we use a " For Read Only " statement
somehow (we tried this, but still got the lock)?  Any suggestions on how to
affect the isolation level for Sybase within the SQR program?

Many thanks,
Huey