[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



> 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

Others have told you that this isn't gonna fly against the Sybase server.
True enough.

To accomplish what you need... try "set transaction isolation level 0" as
part of a
Begin-SQL command.  Run the Begin-SELECT part of the report, and when
finished, set the
trans isolation level back to 3.

Alternately try something like: "select title from titles at isolation read
uncommitted",
which accomplishes the same thing for the duration of the SELECT.  You might
have to
play with this a bit, probably by using a Begin-SQL for your main SELECT and
dumping retrieved
values into variables, rather than using Begin-SELECT statement blocks.

Try it and let us know, willya?

-Chris