MySQL Tutorial/Miscellaneous Functions/IS USED LOCK
IS_USED_LOCK(str): Checks whether the lock named str is in use (that is, locked).
If so, it returns the connection identifier of the client that holds the lock. Otherwise, it returns NULL.
22. 7. IS_USED_LOCK 22. 7. 1. IS_USED_LOCK(str): Checks whether the lock named str is in use (that is, locked).