UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = 'znxGbNQ0lePqOLvwWtRB/wh5dIL0hN4qWwT/IVjHbLI='
WHERE
key_id = '8c8ac76a1ebf121dbe8025974e634e70c31e8968e269d63eeec076e963ffb83c'
AND (
token = 'znxGbNQ0lePqOLvwWtRB/wh5dIL0hN4qWwT/IVjHbLI='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)