big mans right here explained 1 hour worth of content on locks in 8 mins
@Jose-xh3tz2 жыл бұрын
Lol, that's really helping my exam preparation. Thanks! Just a question popped out, why Charlie doesn't have to wait for Alice since he's acquiring an exclusive lock...is it simply bcz that part of Alice is not involved? Thanks!
@maxdenusenko8989 Жыл бұрын
same question
@winfle Жыл бұрын
he aquire an exclusive lock not on table, but on row
@northeastpaintingservice45104 жыл бұрын
Nice video brother 👍
@developerfoe2 жыл бұрын
what an explanation... superb
@ayazahamed8254 Жыл бұрын
Very Well Explained.
@kaustubhkhare40864 жыл бұрын
Suppose I have 200k rows to update which might take around 10 minutes. At the same time I need to read some of the records. What would be the best way to do that?
@hnasr4 жыл бұрын
Kaustubh Khare it really depends do you care if others modified or read those rows while you are reading it in those 10 minutes? Will it lead to inconsistencies? If you don’t want others writing or reading then use isolation level serializable (2 phase lock) If you want people reading and writing while you are but you don’t to see their changes while they are writing use isolation level repeatable read If you dont care if you read others changes use read committed isolation level The 3 operations are ordered from slowest /highest consistently and isolation to the fastest but least isolation and consistency Hope that helps
@kaustubhkhare40864 жыл бұрын
Hussein Nasser Thanks
@hdtube994 жыл бұрын
Why not just call them as READ lock and WRITE lock?
@hnasr4 жыл бұрын
James Yu I agree easier names, engineers love to complicate things.
@Timba2463 жыл бұрын
because shared means it can be shared and exclusive means it cant be shared, thats intuitive we cant say this about read and write
@vyshnavramesh93053 жыл бұрын
Maybe because there is this another lock 'Update lock. Its used for SELECT statements which can be followed by any write statement on the selected data.
@Yaxoi2 жыл бұрын
My professors at university actually call them that
@basheeral-momani20322 жыл бұрын
thanks for putting this video for all
@devmatrix63733 жыл бұрын
Can u suggest a book for database design That has staff like lock and advanced topics
@freddyv53532 жыл бұрын
"Database Internals" by Alex Petrov
@ergis8004 Жыл бұрын
MongoDB doesn't have shared lock in transactions sadly, with what I've researched. You have to use application locks or use some manual "locked" field or some sort.