Made a huge error at work today and was practically in tears, took lots of people and many hours to resolve, boss sent this vid to me. Thank you for the simple explanation, NEVER AGAIN!!!
Let's look at the timeline (6:15) , you can see I have "two" SQL Server Management Studio's (SSMS) open at the same time. I can say, "having two open SSMS open, is much like having two separate users", do you agree? On your local computer, do you have TWO SSMS open, and are executing the same code at 6:15 in each appropriate window?
hey @pvksmaheeth8816, so, one user has enter a begin trans, and performed an update, but, has not commit; a second user can use the "with (nolock) command, and get the data (could be old or stale), select column_name from table with (nolock) where column_name = 'value'; In the example at 6:15, make this change: select * from product with (nolock) where id=3 at 7:07, I use the (nolock) command. you can either use (nolock) or with (nolock) please let me know if that solved the question you asked.
Made a huge error at work today and was practically in tears, took lots of people and many hours to resolve, boss sent this vid to me. Thank you for the simple explanation, NEVER AGAIN!!!
Hey @stmav01, thanks for leaving a message and glad to hear is video was helpful. What was the problem you encountered?
Thank you for the quick and direct video. Good examples and demonstration.
Hey @rodf1021, I want to thank you for taking the time to leave a comment. Your input is greatly appreciated.
Great video, simple and easy to understand
Excellent
Thanks @afzaalawan for leaving a comment. I hope this video was useful!
God bless you man
Thanks a lot sir , well explained.
Nice explanation! Thank you man!
superuseful thanks
Glad to hear this video was useful, and thanks for taking the time to give me a shout out. Appreciated.
This video is so underrated
It feels great to be appreciated, thanks for the comment.
why didnt you get a deadlock at 6:15, for me its coming
If you are in an open transaction, that will put a lock on the affected rows. Are you using two connections?
@@SoftwareNuggets two connections ? Two different tabs same query?
Let's look at the timeline (6:15) , you can see I have "two" SQL Server Management Studio's (SSMS) open at the same time. I can say, "having two open SSMS open, is much like having two separate users", do you agree? On your local computer, do you have TWO SSMS open, and are executing the same code at 6:15 in each appropriate window?
@@SoftwareNuggets yes I have two users, and I'm getting that error. Is there any function that can stop the table lock while update statement
hey @pvksmaheeth8816, so, one user has enter a begin trans, and performed an update, but, has not commit; a second user can use the "with (nolock) command, and get the data (could be old or stale), select column_name from table with (nolock) where column_name = 'value';
In the example at 6:15, make this change: select * from product with
(nolock) where id=3
at 7:07, I use the (nolock) command. you can either use (nolock) or with (nolock)
please let me know if that solved the question you asked.
how is a 10 minute video 8 minutes too long...
Hey @seangillespie4601, I agree! The video has been trimmed to remove unnecessary segments.