Not applicable

Query user profile doesn't return anything for the "MemberOf" properties

I'm trying to get "Query user profile" to return the "MemberOf" properties of a user.  When I swap out "MemberOf" with "FirstName" it works.  "MemberOf" doesn't return anything.  I'm storing it into a collection variable and writing it to the log.

Overall, my goal is to find all of the AD Security Groups a user is a member of and then loop through that list to remove them for off boarding.

Thanks,

0 Kudos
Reply
7 Replies
jesse_mchargue
Nintex Employee
Nintex Employee

Re: Query user profile doesn't return anything for the "MemberOf" properties

Hello Dean Pawley​ -

I would check out these threads as it is the same thing you are attempting to get to:Display Group Membership and Nintex Workflow - Ldap security query

Ultimately, try returning sAMAccountName rather than MemberOf if your query is something like:

Hope this helps!

Reply
Not applicable

Re: Query user profile doesn't return anything for the "MemberOf" properties

I tried what you sent and it didn't quite work for me, but it did give me the clues I needed to get what I was looking for.  So, thanks!

Ultimately, here's what I'm doing...

The query user profile is pulling from a person field on the form and placing it into a variable (var_DistinguishedName) as a single line of text.

The query LDAP is using the query (&(objectCategory=group)(member={WorkflowVariable:variable_DistinguidedName})) and putting the list in a collection variable (var_coll_MemberOf)

Then I placed it into the log to check the values, which looked good.

Then I sorted the collection just to make it easier to comparing the list to the Active Directory MemberOf list

The For Each loops the target var_coll_MemberOf and stores it into a variable var_GroupOf.  I'll change the For Each to handle the action of Removing the account from AD.

nintexwfpeople.png

Reply
murphybp2
Nintex Newbie

Re: Query user profile doesn't return anything for the "MemberOf" properties

If you're using the query LDAP, I think the attribute may be case sensitive.  Try "memberOf" with a lowercase "m". 

0 Kudos
Reply
Not applicable

Re: Query user profile doesn't return anything for the "MemberOf" properties

Thanks Brendan,

The above solution works.  I'll detail the whole thing and share it on here if anyone else needs it.

Thanks!

Reply
jesse_mchargue
Nintex Employee
Nintex Employee

Re: Query user profile doesn't return anything for the "MemberOf" properties

Glad you got everything working Dean Pawley​!

Be sure to mark your question as answered so others can quickly find what you did.

0 Kudos
Reply
Not applicable

Re: Query user profile doesn't return anything for the "MemberOf" properties

I created a pdf with screenshots; how can I upload it here?

Reply
jesse_mchargue
Nintex Employee
Nintex Employee

Re: Query user profile doesn't return anything for the "MemberOf" properties

If you open up the response in advance editor:

and then you can add attachments:

Hope this helps!

Reply