Report for Local Admin Group does NOT contain specific user
Patrick Garber
Hey all,
I am trying to build out a report that shows me all systems that does not have a specific user in the local admin group. I have many systems out there with local admins, but one in particular MUST be in it. Having trouble getting this to work correctly.
So far I am trying to use:

where <username> would be modified to be the local user I am looking for. This is returning systems that have that user in the local administrators group.
What am I doing wrong?
1
Comments
Hi Patrick,
A couple things come to mind based on your screenshot (at a glance) -
1. If you're wanting to only show machines in the "Online Systems with Server OS" collection, you shouldn't need that first filter. If you're trying to include all machines in your environment and machines in the "Online Systems with Server OS" collection, you'd likely be better served replacing that filter with a Computer -> Online -> Is True (for simplification). Either way, it doesn't look like those two filters together are going to get what you intend.
2. Not All is a fun group filter. Where All means "All these things must be true", Not All does not mean "None of these things can be true". It actually means "If any of these things are false". Try switching that to Not Any and see what your results come back with.
Thanks Ryan. Unfortunately removing the first filter and changing Not All to Not Any didn't do the trick. It is still returning systems with that specific user in the local admin group. I am specifically looking for systems that the user is not a local admin on. The user may exist on the system, but I only want to see systems where the user is not a local admin. There are other users and groups that are local admins, and that is fine.
Try the lower part of this (I don't have your same collection, but used one I knew would show me the results the second part is looking for)
And then since you know the specific username, you'd want equals instead of contains, like you already had.
GrantG,
Thank you! That gave me exactly what I was looking for
Doh! I have my collection laid out just like GrantG, but I totally forgot to mention that in my post.
Sorry about that, but glad you have it working now!