If you're talking about trying the last code you posted above, that won't work because the only way the condition would be true is if pm.folderid was equal to -1 and to 0. If you wanted to do it that way you'd need an OR (and add parens), like:
Code:
$pms_query_where_clouse .= " AND (pm.folderid = '0' OR pm.folderid = '-1')";
But that's actually equivalent to "AND pm.folderid IN (0, -1)", which is what you get by removing the NOT.