UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = 'Vg/YL/SNgGA6PTjFXlQE1gdOue2KUbRDrfQmOPmtF4U='
WHERE
key_id = 'a93c62c2267bb771e5fdbcc1cbd48eecfa98b583593e14397de8b74a5ed1f84a'
AND (
token = 'Vg/YL/SNgGA6PTjFXlQE1gdOue2KUbRDrfQmOPmtF4U='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)