UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = 'qgmLqlVwih/fD+ZQM1UEtVh3cOn/S+xJQWcRZzONPmE='
WHERE
key_id = '8021045105de06fc583b8692cb629202c03638244e4125460825efa8754446b7'
AND (
token = 'qgmLqlVwih/fD+ZQM1UEtVh3cOn/S+xJQWcRZzONPmE='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)