UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = 'JrW0ACinU/ZE7Qt1u7SjEg68PXK1EV6w1/DofRxNqxI='
WHERE
key_id = '53e7cbf807220e3c1d7e8981a2833169d3165d5bc4920e8dd2e0fdf1e5785e44'
AND (
token = 'JrW0ACinU/ZE7Qt1u7SjEg68PXK1EV6w1/DofRxNqxI='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)