UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = 'XlmSK3p2ZlEBSI+kPXdlyaiCJ/UGqUVrrnqAuP7fkmM='
WHERE
key_id = '3ebef8ba4d5c9fd47a81ed75c355c3563d1b6f62079356d1bf16a2dbe832a753'
AND (
token = 'XlmSK3p2ZlEBSI+kPXdlyaiCJ/UGqUVrrnqAuP7fkmM='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)