Search type Search syntax
Tags [tag]
Exact "words here"
Author user:1234
user:me (yours)
Score score:3 (3+)
score:0 (none)
Answers answers:3 (3+)
answers:0 (none)
isaccepted:yes
hasaccepted:no
inquestion:1234
Views views:250
Sections title:apples
body:"apples oranges"
URL url:"*.example.com"
Favorites infavorites:mine
infavorites:1234
Status closed:yes
duplicate:no
migrated:no
wiki:no
Types is:question
is:answer
Exclude -[tag]
-apples
For more details on advanced search visit our help page
Results tagged with Search options user 708

A mechanism for managing concurrent access to shared data or resources by granting temporarily exclusive access to the processes requesting the lock.

6
votes
locks from the point of view of concurrency (will the new CTEs create more contention due to locking?) then I would recommend investigating deploying snapshot isolation. …
answered May 22 '12 by Remus Rusanu
13
votes
I recommend you read Understanding how SQL Server executes a query, it has an explanation of how reads and writes work and how locking works. The 10000ft view goes as follows: read operators … level options). This allow operators to lock entire tables w/o locking every individual row lock lifetime and range locks are used to enforce higher isolation levels This is really just the tip of the …
answered Jan 20 '14 by Remus Rusanu
6
votes
Application locks. They are arbitrary locks held by the engine on behalf of the app. Acquired with sp_getapplock and released with sp_releaselock (if needed). Shared, Update, Exclusive and intent mode …
answered Jun 16 '17 by Remus Rusanu
12
votes
? Yes. If that would not be true, then your own 'locking' would only be scoped to other similar 'locking' and not interact with the engine own locking. So you would lock a row in a table so that it … cannot be locked by another application in the same manner, but your lock would be ignored by the engine itself. These semantics are seldom desired. Most of the time an application locking a row means …
answered Jan 23 '14 by Remus Rusanu
9
votes
Have you considered using snapshot isolation? Enabling read_committed_snapshot in the database will cause all reads (selects) to be lock free: alter database [...] set read_committed_snapshot on; N …
answered Mar 15 '12 by Remus Rusanu
3
votes
Your simplified repro simplified the problem beyond the point it repro... create TABLE dbo.Users (Id int NOT NULL IDENTITY PRIMARY KEY) create TABLE dbo.Transfers ( Id int NOT NULL IDENTITY PRIM …
answered Aug 3 '12 by Remus Rusanu
4
votes
The lock granularity (ie. row vs. page vs. table) is part of the lock strategy which is determined upfront when a statement starts execution. there are several factors that determine the granularity, …
answered Mar 24 '17 by Remus Rusanu
30
votes
If your report blocks updates that your DBA is right: you should absolutely not use NOLOCK. The very fact that there are conflicts is a clear indication that if you would use dirty reads you would get …
answered Jan 13 '12 by Remus Rusanu
3
votes
The underlying OS is capable of detecting all the above mentioned possible disconnects and break the communication channel (TCP, net pipe etc). This will result in the rollback. Don't try to outsmart …
answered Mar 3 '15 by Remus Rusanu
3
votes
some (most) X locks are recorded in the log, see How to read and interpret the SQL Server log. You can see what xact acquired them and how long the xact lasted (see the link). You won't find the confl …
answered Mar 10 '14 by Remus Rusanu
4
votes
the machine has 48GB memory and only ~14GB is used. SQL Server is configured to use a max of 2,147,483,647MB of memory. This does not tell wether the locks memory is exhausted or not. SQL Server …
answered Apr 6 '17 by Remus Rusanu
5
votes
ReadUncommitted isolation level does acquire locks. Schema stability locks prevent the objects being queries from being altered while the query executes. This locks are acquired under all isolation le …
answered Dec 1 '11 by Remus Rusanu
6
votes
Minimal hit. The cost of evaluating the blocked process list is already there since this is how deadlocks are detected. The cost of generating and writing an event in the server side log is quite low …
answered May 30 '13 by Remus Rusanu
12
votes
My recommendation would be to do a best effort try/catch. Handle the duplicate case explicitly, as appropriate, eg. ignore it... The real question: why is DDL running on-demand, from multiple xacts? …
answered Mar 10 '14 by Remus Rusanu
7
votes
Transaction Processing: Concepts and Techniques. Readings in Database Systems Principles of Transaction Processing While product specific books do a great job at explaining how to use the products …
answered Feb 13 '12 by Remus Rusanu

15 30 50 per page