I have the following simple scenario.
Three computers will be updating a cinema booking table. Should I lock the whole table or lock the rows corresponding to seats that will be updates? Can I consider optimistic concurrency control here?
I was just searching about optimistic and pessimistic concurrency control and stumbled about different locks and was wondering which would be the most suitable for which scenarios.