This excludes children of "/example/" (/example/ has id of 1006)
$results = $pages->find("title|summary~=$q")->not("has_parent=1006");
… and this will exclude them too
$results = $pages->find("title|summary~=$q, has_parent!=/example/");
… but this won't
$results = $pages->find("title|summary~=$q")->not("has_parent=/example/");
And … is there any difference using not() and != ?