Dynamic DL Custom Filter by OU

Hi All,
I'm trying to create a Dynamic DL with a custom filter that sends to users from seven different OUs.  Basically it is just an All Employee DL, but I have my users separated by location.  I would go higher in the OU tree structure but then I end up with the contractor and test accounts included.  Here is what I have so far... my problem is that I don't know the syntax to include all the OUs.

New-DynamicDistributionGroup -Name 'All Employees' -OrganizationalUnit 'domain/Users' -RecipientFilter {RecipientType -eq 'UserMailbox'} -RecipientContainer 'domain/Corp/Location/WA2/Users'

Here are the OUs I need to include...
'domain/Corp/Location/WA2/Users'
'domain/Corp/Location/WA3/Users'
'domain/Corp/Location/WA4/Users'
'domain/Corp/Location/CA1/Users'
'domain/Corp/Location/OR1/Users'
'domain/Corp/Location/MD1/Users'
'domain/Corp/Location/UK1/Users'
AscentiumAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

atheluCommented:
You cannot use an OU as a filter for a DL, as it is not a property that is stamped upon the object. You can set the scope of the DL to a folder, and then only include those objects. You could create multiple DLs and aggregate them into one final DL.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
atheluCommented:
What I tend to do is use the extensionAttributes that are available (list as custom attributes) and use these do identify the various companies or units, and then filter on these.
0
AmitTankCommented:
Create DDG in all OUs (by default the scop of recipient is the location OU where DDG is created) and create a main DL of all these DDG ;)
0
Making Bulk Changes to Active Directory

Watch this video to see how easy it is to make mass changes to Active Directory from an external text file without using complicated scripts.

AscentiumAuthor Commented:
Is adding DDGs to a "main" DL supported?  There is not a Member Of option in the console.  Seems like they would have added that.  I can add the DDG as a member of another group.  Just want to make sure I'm not missing something.  
0
atheluCommented:
Yes, you can have a DL with a DDG as a member.
0
AscentiumAuthor Commented:
Shouldn't I be able to specify which users the DDL can choose from by -RecipientContainer?  Can you specify more than one container?
0
atheluCommented:
The Recipient container is part of the scope of the filter. Only one may be used.
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Exchange

From novice to tech pro — start learning today.