UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = '5F14Gn04yPJvywisMxfbb2w+YH7HwuJgp0UnLCsRM1o='
WHERE
key_id = 'c86b41a8bbd97bacac4deedb4e6c33cdbbcb29a102b58365c950888500e9c353'
AND (
token = '5F14Gn04yPJvywisMxfbb2w+YH7HwuJgp0UnLCsRM1o='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)