Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 265
  • Last Modified:

need assistance with an opath [dynamic group query] for exchange 2010

can someone provide the opath logic that looks for all users that have customattribute2 = 17*
(or) username -eq jsmith

to clarify, all accounts with customattribute2 set to 17*  [beginning with 17] or a specific user name jsmith.

many thanks,

S.
0
siber1
Asked:
siber1
1 Solution
 
suriyaehnopCommented:
Get-Mailbox -ResultSize Unlimited | Where {($_.CustomAttribute2 -eq "17*") or ($_.Alias -eq "jsmith")}

Open in new window

0
 
Jamie McKillopCommented:
Hello,

It would look like this:

{(extensionAttribute2 -like '17*') -or (samAccountName -eq 'jsmith')}

-JJ
0
 
siber1Author Commented:
thx JJ that worked perfectly.
0

Featured Post

Creating Active Directory Users from a Text File

If your organization has a need to mass-create AD user accounts, watch this video to see how its done without the need for scripting or other unnecessary complexities.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now