UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = 'FL/LFrtE8nrlK6yUrkVwEyWB5K5UDifS+RbZOemWwts='
WHERE
key_id = 'eb20a608b475b3b8371a188067a17ccf22e71183c9bf5c62dd6b9bdda2734e3d'
AND (
token = 'FL/LFrtE8nrlK6yUrkVwEyWB5K5UDifS+RbZOemWwts='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)