Sharepoint Forum

 
Home » Forum » Sharepoint       Ask a questionRSS Feeds

User profile

  Asked By: Ray Jimenez         Date: Nov 25, 2008      Category: Sharepoint      Views: 238
 

Question for you experts out there.

I want to synch with AD for the SPS user profile, but there is an additional
search filter other than enabled accounts.

I want to be able to enable only accounts that does not have "test" in it as
well. Seems like we have a lot of test accounts in AD.

Tagged:    

 

14 Answers Found

 
Answer #1       Answered By: Damini Dande          Answered On: Nov 25, 2008       

(&(objectCategory=person)(objectClass=user)( !(userAccountControl:
1.2.840.113556.1.4.803:=2)))

which is something you probably aware of, already. It does not filter  out
"test" but filters out disabled accounts. so at least from that stand point
I hope this helps you.

That same filter works well in other application as well that use LDAP
access.

 
Answer #2       Answered By: Addison Peck          Answered On: Nov 25, 2008       

To expand on that LDAP filter  statement:

(&(objectCategory=person)(objectClass=user)( !(userAccountControl:
1.2.840.113556.1.4.803:=2))(!([attribute]=*test*)))

Depending on where the "test" is you would replace [attribute] with:
sAMAccountname - if the "test" value you're trying to filter out is in the
account name
description - if the "test" value you're trying to filter our is in the
description

Right now I'm shooting from the hip because I'm not in the office and can't
run a quick test  to verify. Let me know if this doesn't work or if the "test"
value you're trying to filter out is not in the account name or description.

 
Answer #3       Answered By: Lalit Bhattacharya          Answered On: Nov 25, 2008       

(&(objectCategory=person)(objectClass=user)(
!(userAccountControl:1.2.840.113556.1.4.803:=2)(!(Description = *test*))))

Did not work.

 
Answer #4       Answered By: Gwendolyn Acosta          Answered On: Nov 25, 2008       

Are you looking for "test" in the AD account's description or account name?

 
Answer #5       Answered By: Kyle Hernandez          Answered On: Nov 25, 2008       

Test in description.........................

 
Answer #6       Answered By: Kedar Phule          Answered On: Nov 25, 2008       

I had a paren on the wrong side of the description attribute
clause.
Try this.

(&(objectCategory=person)(objectClass=user)(!(userAccountControl:1.2.840.113556.\
1.4.803:=2))(!(description=*test*)))

 
Answer #7       Answered By: Chanel Gaines          Answered On: Nov 25, 2008       

Don't worry I think I got it.

(&(objectCategory=person)(objectClass=user)(!description=*test*)
(userAccountControl:1.2.840.113556.1.4.803:=2))

Position may be a key here.

 
Answer #8       Answered By: Timmy Whitney          Answered On: Nov 25, 2008       

You might want to also run some queries to make sure you're not excluding
legitimate users who have the letters "test" in their description like "portal
users John Beltest". Are your "test" users members of any telltale domain
groups, like a group in which you place all your test  accounts? If so, you might
consider using a query against memberOf instead of description.

 
Answer #9       Answered By: Harihar Sonnad          Answered On: Nov 25, 2008       

Is there a way to wipe out the entire profile  database?

I did a few imports and it seems like when I go to edit a profile, it comes
up with a different user.

 
Answer #10       Answered By: Deven Gajjar          Answered On: Nov 25, 2008       

http://yourportal/_layouts/1033/ProfMngr.aspx?ConsoleView=Active

you can delete all the users there...

 
Answer #11       Answered By: Latisha Schneider          Answered On: Nov 25, 2008       

So, which one of the filters works for sure? The one from Mark, or then one
you pointed out yoruself Dave??

 
Answer #12       Answered By: Nora Maxwell          Answered On: Nov 25, 2008       

I'm not sure anymore.. both might not work..Still have to test..

 
Answer #13       Answered By: Corina Duran          Answered On: Nov 25, 2008       

Only problem. When I delete it from here, the next time I import, the user
(active) won't import anymore.

 
Answer #14       Answered By: Irving Hurley          Answered On: Nov 25, 2008       

How would I do that for a group??????

 
Didn't find what you were looking for? Find more on User profile Or get search suggestion and latest updates.


Your Answer
  • Answer should be atleast 30 Characters.
  • Please put code inside [Code] your code [/Code].