How to find all results that do not match a condition
A common use of IQ is to look for all results that do not meet a certain condition. Many users write these queries using the "Not Equal To" condition, but that will not return correct results. Instead, you need to use a sub-query. Note: "Is Not Equal" Does Not Match Blank Fields.
Use a Sub Query to Find all Results That Do Not Match a Condition
If you need an introduction to subqueries, see this knowledge base article:
How to create sub-queries in IQ
We will be using the "Not in Sub Query" condition. In this case, we are looking for all families who are not found in workgroup servers. The condition will be the field that is guaranteed to be unique for each family, (Family DUID).
You should use the DUID for the category you are searching: Member DUID for members, Contribution DUID for contributions, and so on.
Then, select the "not in subquery" condition:
To define the sub-query, click on the edit sub-query link.
In this Edit sub-query window, define a condition that you want to exclude. Because the condition is "not in sub query" the sub query needs to match the people you do NOT want in your list.
In our example, that is the members of the Church Cleanup family workgroup. So we write the following condition:
This query will give you what you are looking for: a list of every single family who is not part of the Servers family workgroup.
Even though the query condition is only finding Family DUIDs, you will be able to include all family information in the result columns. IQ will return results for the records that match the Family DUIDs returned in the result.
Updated