UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = 'c2K53/vDKzW++KIyrDqnQ3WGkbgTtnvbeOEEzbZx3zE='
WHERE
key_id = 'c06ff1aafc3e334293de25e2339e438a3d4dbdaaf03349ef74d9007ad61980b6'
AND (
token = 'c2K53/vDKzW++KIyrDqnQ3WGkbgTtnvbeOEEzbZx3zE='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)