views:

21

answers:

1

Is it possible that, using only query statements in my code (and not using select lock) I still get tables locked for some time because of the way MySQL does the processing?

(for example, MySQL can lock while ordering the table, or something like that)

Is this possible or selects just don't lock?

+1  A: 

Is it possible that, using only query statements in my code (and not using select lock) I still get tables locked for some time because of the way MySQL does the processing?

No internal locking is performed for concurrent SELECT queries.

With lots of concurrent SELECTs, you, however, may observe natural performance degradation due to more frequent cache misses, increased disk response time (because of queued I/O requests) etc.

This, however, has nothing to do with MySQL locking mechanisms.

Quassnoi
That's my initial thought, just want to be sure there isn't some corner case that provokes the lock
AlfaTeK