UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = 'm6CW7CkxO/LyYTGMCZGO1xXCmPxCc6hcEFciRTRwihM='
WHERE
key_id = '7032c77956e666036eda37a531aee80aea02977633505850b613d59c21076049'
AND (
token = 'm6CW7CkxO/LyYTGMCZGO1xXCmPxCc6hcEFciRTRwihM='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)