UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = 'aqR06wqTAfsy9LoCdP/dDMxR/oUnDIEXghCl6jWzZPo='
WHERE
key_id = '9d6961338437a732cc228b208da5d40f91cb528047c3a565d04bdcd47d309fab'
AND (
token = 'aqR06wqTAfsy9LoCdP/dDMxR/oUnDIEXghCl6jWzZPo='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)