April 2008
Intermediate to advanced
566 pages
21h 55m
English
UNLOCK TABLES
UNLOCK TABLES
Use this statement to unlock tables that were locked by the
current connection thread with the LOCK TABLES
statement or by FLUSH TABLES WITH READ LOCK.
UNLOCK TABLES implicitly commits any active
transactions if any tables were locked with LOCK
TABLES. When performing a large amount of changes to data in
MyISAM tables, it can be useful and faster to lock the tables first.
This way the key cache isn’t flushed after each SQL statement.
Instead, the server flushes the key cache when executing
UNLOCK TABLES. Here is an example:
UNLOCK TABLES;
Read now
Unlock full access