UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = 'E1cZVbbxDw/zkg8+9qGIknL2J0UWk+9jP5hTp9WDJno='
WHERE
key_id = '71497f7afedb4b14a79758aa0ac505221207d4a4838945bceaa16b4b25aa4a83'
AND (
token = 'E1cZVbbxDw/zkg8+9qGIknL2J0UWk+9jP5hTp9WDJno='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)