Solved

Create Global Address List using a Recipient Filter with two or more custom Attributes

Posted on 2014-02-06
6
1,299 Views
Last Modified: 2016-08-26
I am trying to create a new Global Address List in Exchange 2010 using a recipient filter with two or more custom attributes.

New-GlobalAddressList -Name "GAL_HSMS" -RecipientFilter {((CustomAttribute1 -like "HSMS") -and (CustomAttribute2 -like "Faculty") -and (CustomAttribute3 -like "Staff"))}

Command executes without an error, however run I run the Update-GlobalAddressList -Identity "GAL_HSMS" it returns 0 users.

Any Help would be appreciative.

thanks,
Scott
0
Comment
Question by:scotth4711
  • 4
6 Comments
 
LVL 31

Expert Comment

by:Gareth Gudger
ID: 39840702
Have you already set these custom attributes on these mailboxes?

For example, Set-Mailbox -CustomAttribute3 "Staff"
0
 

Author Comment

by:scotth4711
ID: 39841748
Yes, all the attributes have been assigned, and works fine if I use a single attribute, just doesn't work if I use multiple attributes.
0
 

Author Comment

by:scotth4711
ID: 39841922
Ok, I know what I was doing wrong, I was writing three And Statements rather than 1 and and 1 or statement.

So I would need Attribute1 = hsms and or attribute2 = faculty or attribute3 = staff.  not sure if this can be done, I may just need to use another attribute as fac_staff.
0
PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

 

Accepted Solution

by:
scotth4711 earned 0 total points
ID: 39841972
Recipients filter:
((CustomAttribute1 -eq 'HSMS') -and (((CustomAttribute2 -eq 'Faculty') -or (CustomAttribute3 -eq 'Staff'))) -and (Alias -ne $null))
0
 

Author Closing Comment

by:scotth4711
ID: 39852796
Kept Playing around till I got it.
0
 

Expert Comment

by:Advizor
ID: 41771531
Hi Guys

Whats the syntax if i need to input variables?
0

Featured Post

NAS Cloud Backup Strategies

This article explains backup scenarios when using network storage. We review the so-called “3-2-1 strategy” and summarize the methods you can use to send NAS data to the cloud

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Follow this checklist to learn more about the 15 things you should never include in an email signature from personal quotes, animated gifs and out-of-date marketing content.
MS Outlook is a world-class email client application that is mainly used for e-communication globally.  In this article, we will discuss the basic idea about MS Outlook, its advanced features, and types of MS Outlook File formats.
In this video we show how to create a User Mailbox in Exchange 2013. We show this process by using the Exchange Admin Center. Log into Exchange Admin Center.: First we need to log into the Exchange Admin Center. Navigate to the Recipients >> Mailb…
In this video we show how to create a Distribution Group in Exchange 2013. We show this process by using the Exchange Admin Center. Log into Exchange Admin Center.: First we need to log into the Exchange Admin Center. Navigate to the Recipients >>…

785 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question