0 votes

Is it possible to to get all users with a custom attribute defined?

In PowerShell I'd be doing this:

$s = get-aduser -filter 'Description -like "Sales Engineer"' | Select Name

But Instead of filtering on Description I'd want to filter on adm-CustomAttributeBoolean1

The dream was that this would work:

$s = get-admuser -filter 'adm-CustomAttributeBoolean1 -like "True"' | Select Name

Is this possible?

Thanks for any help or tips!

by (300 points)

1 Answer

0 votes
by (289k points)
selected by
Best answer

Hello Jake,

There is no possibility to use Adaxes custom attributes in LDAP search filters. However, you can use search to find the users you need and then filter search results by the value of the custom attribute you need. For examples, have a look at the following scripts from our repository:
Users whose Adaxes custom attribute is set to a specific value
Users whose Adaxes custom attribute is not empty

Related questions

0 votes
1 answer

Thanks for the info. I'm now grabbing the %adm-ManagerUserName% value, but need to remove the final 21 characters of it so it contains only their username and not our ... this in the PowerShell Script Editor for my business rule, I get the following error:

asked Mar 11, 2021 by mkvidera (60 points)
0 votes
1 answer

Hello. I got a script that when E-mail forwarding is set, it automatically sends an email to the person that will recieve the forwarded emails for 6 months. But I'd like ... what to put in the xxxxxxx so it would take the account that im running command on.

asked Jun 3 by EdgarsABG (110 points)
0 votes
1 answer

Hi, during account creation we store a user/requester DN in field adm-CustomAttributeObject2 If now this requester is disabled, I want to find all users in AD ... field. I found some articles and scripts, but nothing working as expected.

asked Feb 27 by wintec01 (1.5k points)
0 votes
1 answer

Hi, I have a custom attribute for new hire start date with the following configuration : When i retrieve the attribute it is always returned as the day before, as an ... but would like to understand what is going on here, any input would be appreciated.

asked Sep 13, 2019 by digimortal (240 points)
0 votes
1 answer

I have Search configured for one of our web interfaces. One of the fields that can be searched is a custom attribute admCustomAttributeText4 (with a friendly name of ... are definitely some accounts with that attribute populated. Is this behaving as designed?

asked Sep 19, 2018 by sandramnc (870 points)
3,548 questions
3,238 answers
8,232 comments
547,811 users