LOCK_TIMEOUT specifies the number of milliseconds a statement should wait for a lock to be released, for example:
LOCK_TIMEOUT
SET LOCK_TIMEOUT 1000 --Wait one second