table locking

Discussion of open issues, suggestions and bugs regarding SDAC (SQL Server Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
luis_augusto
Posts: 43
Joined: Fri 14 Oct 2005 13:45

table locking

Post by luis_augusto » Thu 16 Nov 2006 15:54

Opening a query with a select without a "where" clause causes the locking of the entire table, jeopardizing multiple-user access:

Ex.

Select * from table
order by
field1,field2


I´ve tried

Select * from table with (nolocks)
order by
field1,field2

But it did change nothing

What could possibly be?

Thanks

Jackson
Posts: 512
Joined: Thu 26 Jan 2006 10:06

Post by Jackson » Fri 17 Nov 2006 11:54

It is possible that you use FetchAll = False mode.
Query execution in such mode blocks current session.
In order to avoid session blocking OLE DB creates an additional session which causes table blocking.

Post Reply