Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to Select UNCOMMITTED rows only in SQL Server?

I am working on DW project where I need to query live CRM system. The standard isolation level negatively influences performance. I am tempted to use no lock/transaction isolation level read uncommitted. I want to know how many of selected rows are identified by dirty read.

like image 875
BI Dude Avatar asked Mar 07 '14 08:03

BI Dude


1 Answers

Maybe you can do this:

SELECT * FROM T WITH (SNAPSHOT)
EXCEPT
SELECT * FROM T WITH (READCOMMITTED, READPAST)

But this is inherently racy.

like image 124
usr Avatar answered Sep 22 '22 08:09

usr