Hello
In SQL Server
I have two user 1st User_1 and 2nd User_2
At Same Time both user (User_1 & User_2)
User_1
Update Col X=Y (Set X = Y)
User_2
select Col
So what select will select X or Y
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Jignesh TrivediPosted Aug 13, 2015, 11:51 PM
Hi,
It is depending upon Isolation level set to SQL server.
If it is equal or higher than the read committed than SQL server wait until update statement finish it task.
If it is set to read uncommitted than it will show you old (not committed) data.
One more thing you can make select your query as read uncommitted by using nolock keyword.
select * from cols(nolock)
hope this will help you.
Rajeesh MenothPosted Aug 13, 2015, 12:12 PM
Sumit JoshiPosted Aug 13, 2015, 9:23 AM