sql server - Finding cause of Lock escalation -


while running sql server profiler reached lock:escalations. when searched statements having same spid lock:escalation event realized 1 of delete statements causes this.

is there way find out why lock escalation in such place occurres?

statement like:

delete book_in_library libraryid in (,,,,); <-20 elements ids  create table book_in_library( [libraryid] [bigint] not null, [bookid] [bigint] null, [otherdata] [bigint]null, [otherdata2] [int] null, [otherdata3] [int] not null, primary key clustered ( [libraryid] asc, [bookid] asc )with (pad_index = off, statistics_norecompute = off, ignore_dup_key = off, allow_row_locks = on, allow_page_locks = on) on [primary] ) on [primary] 

you may not need worry lock escalation sql server process query faster. @ same time, blocks range of records (either page level lock or range lock or table level lock), records in these pages blocked other session. other user need access records in these pages have wait till lock released.


Comments

Popular posts from this blog

How to connect android app to App engine -

gcc - MinGW's ld cannot perform PE operations on non PE output file -

Mutual information between two matrices in R -