All Questions
Tagged with transaction-isolation t-sql
13 questions
0
votes
1
answer
172
views
How can I verify that my query is causing no locks?
Suppose that I'm having a bad day and my confidence just isn't with me. Suppose also that I've written a query with set transaction isolation level read uncommitted. After it runs for a few minutes, I ...
1
vote
0
answers
143
views
Does Using a Linked Server Affect Isolation Levels
I have a query running on one server (let's call it Server B). It looks something like the below - using a linked server to query data from another server ('Server A')
-- in SERVER B
CREATE PROC [foo]
...
1
vote
1
answer
2k
views
Does the delete operation block any insert into the same table?
I have table A and a stored procedure that deletes all data from that table periodically. All queries in the stored procedure are packed into 1 transaction. But sometimes the stored procedure ...
0
votes
1
answer
391
views
Best suitable transaction isolation level when business rules are not strict
Short version:
I am trying to determine which is the best transaction isolation level for the SQL server in our premises.
Long version:
I am extracting data from API calls and loading it into staging ...
1
vote
0
answers
2k
views
Snapshot isolation transaction failed in database 'tempdb' because the object accessed by the statem
I have set allow_snapshot_isolation and READ_COMMITTED_SNAPSHOT on my application database. I have SP's which use temp tables. In case of concurrent access on of the SP throws below error.
None of the ...
1
vote
1
answer
937
views
Lost update in snapshot vs all the rest isolation levels
Let's suppose we use create new table and enable snapshot isolation for our database:
alter database database_name set allow_snapshot_isolation on
create table marbles (id int primary key, color ...
0
votes
1
answer
2k
views
SSIS data flow task executing before previous task completes its SQL operation
In SSIS I have DataFlowTask1 which will insert the data into TABLE A. The following data flow task will pull the data from TABLE A. But unfortunately, DataFlowTask2 is getting fired before the ...
12
votes
3
answers
43k
views
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 ...
0
votes
1
answer
753
views
Scope of locks when using TRANSACTION ISOLATION LEVEL SERIALIZABLE
The following link describes the serializable transaction isolation level.
http://blogs.msdn.com/b/sqlcat/archive/2011/02/20/concurrency-series-basics-of-transaction-isolation-levels.aspx
Suppose ...
4
votes
1
answer
4k
views
SQL SERVER 2008 R2 Transaction Snapshot Isolation Level Not Working As Expected
I created a database called 'test_isolation' and created a table 'person' with data
name age
---- ---
test1 1
test2 2
test3 3
test4 4
test5 5
test6 6
Now the database is ...
17
votes
2
answers
25k
views
Snapshot isolation transaction aborted due to update conflict
Following statement:
INSERT INTO dbo.Changes([Content], [Date], [UserId], [CompanyId])
VALUES (@1, @2, @3, @4);
SELECT @@identity;
gives me this SQL error 3960:
Snapshot isolation transaction ...
3
votes
3
answers
5k
views
How to handle in an effective way duplicate key insertions w/out throwing an exception
My case scenario passes parameter to a procedure, that only does an insert. But two threads might try to pass the same value.
How to handle this situation w/out throwing an exception and with least ...
2
votes
3
answers
3k
views
How is a T-SQL transaction not thread-safe?
The following (sanitized) code sometimes produces these errors:
Cannot drop the table 'database.dbo.Table', because it does not exist or you do not have permission.
There is already an object ...