Microsoft Exchange 2003 – Query Based Distribution Groups

Introduction to Exchange 2003’s Query-based Distribution Groups

The principle of Query-based distribution groups is that emails are sent to recipients based on a dynamic LDAP query, for example, everyone whose department = production.  To take advantage of this new feature you must switch Exchange 2003 server into native mode.

Topics for Query-based Distribution Groups in Exchange 2003

 ♠

How Query-based Distribution Groups work

In Exchange 2003 server, there is more than one way to enable users to send emails to just the right audience.  In addition to creating regular distribution groups, Exchange 2003 can now create a new dynamic distribution list.  There is often resistance to new features, however I believe that LDAP queries in general and Query-based Distribution Groups in particular, are the way of the future.

The word query in Query-based Distribution Group, refers to an LDAP statement. The idea is that instead of using static groups, a Query-based distribution group dynamically generates the membership list, for example, accounts that have a value of Production in the Department attribute.

Using Query-based distribution rewards methodical administrators who keep the user properties up-to-date.  However, the Exchange server has to work harder, because every time that an email message is sent to a Query-based Distribution Group, an LDAP query has to calculate who is in the group.

Creating Query-based Distribution Groups*Query-based distribution group Exchange 2003

* Note: Query-based Distribution Groups are only available if you not only have Exchange 2003 but also its been switched to native mode.

To build your Query-based Distribution Group, first launch Active Directory Users and Computer, then expand the OU where you wish to create your dynamic group.  right-click and provided Exchange 2003 is in native mode you should see the Query-based Distribution Group on the short cut menu.

The secret of effective Query-based distribution groups is choosing a suitable criteria, for example, the Department or Office attribute.  However, the system will only work if you make sure that each user’s property sheet has the correct value for that Department.

Guy Recommends:  SolarWinds’ Free Bulk Mailbox Import ToolFree Download Bulk Mailbox Import Tool

Import users from a spreadsheet, complete with their mailbox.  Just provide a list of the users with the fields in the top row, and save as .csv file.  Then launch this FREE utility, match your Exchange fields with AD’s attributes, click and import the users.  Optionally, you can provide the name of the OU where the new mailboxes will be born.

There are also two bonus tools in the free download, and all 3 have been approved by Microsoft:

  1. Bulk-import new users and mailboxes into Active Directory.
  2. Seek and zap unwanted user accounts.
  3. Find inactive computers.

Download your FREE bulk mailbox import tool.

Building the LDAP QueryQuery-based distribution group custom search

When you create a Query-based Distribution Group in Active Directory, the object has a distinctive icon.  So there is no trouble in distinguishing these dynamic groups from the rest of the objects.

The Find Wizard provides numerous standard LDAP queries, however you can customize the LDAP code if you are familiar with the syntax.

The only draw back that I have found is that the queries only work with Distribution Groups.  Sooner or later you may think, ‘These dynamic groups would be great for permissions’.  Sorry, as the name suggests, Query-based Distribution Groups do not work with any of the Security groups.

Engineer's Toolset v10Guy Recommends: SolarWinds Engineer’s Toolset v10

This Engineer’s Toolset v10 provides a comprehensive console of 50 utilities for troubleshooting computer problems.  Guy says it helps me monitor what’s occurring on the network, and each tool teaches me more about how the underlying system operates.

There are so many good gadgets; it’s like having free rein of a sweetshop.  Thankfully the utilities are displayed logically: monitoring, network discovery, diagnostic, and Cisco tools.  Try the SolarWinds Engineer’s Toolset now!

Download your fully functional trial copy of the Engineer’s Toolset v10

Summary

Investing in Query-based Distribution Groups will save you administrative effort.  The group membership is created on-the-fly.  An LDAP query is run every time an email is sent to this dynamic distribution list.  Query-based distribution groups are one of the best, but under-used new features in Exchange 2003 server.

Knowledge of LDAP queries transfers to and from other areas, for example Saved Queries in Active Directory Users and Computers.

See Also