UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = 'rHQphDM2ph93i7k+ulISXodR9G7h/3PqxzEQCU9MxWc='
WHERE
key_id = '354f92657619e2fdd40c561339d12edff107daeb394e28ba0b0521c74538b41d'
AND (
token = 'rHQphDM2ph93i7k+ulISXodR9G7h/3PqxzEQCU9MxWc='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)