Include query exclusion logic