UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = '2u+yZG+3RqpWGUCU60SYgrITL/J8n8KD5UvClkVo/ts='
WHERE
key_id = 'da900e28637af1955458895ec3063dd3835860a12e36e41e86ec5c82d29b1f00'
AND (
token = '2u+yZG+3RqpWGUCU60SYgrITL/J8n8KD5UvClkVo/ts='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)