UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = 'H+mvX/rmgc0e7OAIcmEPmvERS3kxJJ1ACRlCQvxPY1M='
WHERE
key_id = 'f73ca2cecb4417d7267de35737ec856f37cf65283890e135ca0d1ac3f9d847e0'
AND (
token = 'H+mvX/rmgc0e7OAIcmEPmvERS3kxJJ1ACRlCQvxPY1M='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)