UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = 'TjIj+Pk+gP/HNi7uYaHKN0WoG0NzdHLTWoeZbj09//M='
WHERE
key_id = '62c75447f736c859a7f32227baec61ef136785b1667bdd48f7d93c538aaf1b01'
AND (
token = 'TjIj+Pk+gP/HNi7uYaHKN0WoG0NzdHLTWoeZbj09//M='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)