GROUP BY Predicate

GROUP BY Predicate

This content is no longer actively maintained. It is provided as is, for anyone who may still be using these technologies, with no warranties or claims of accuracy with regard to the most recent product version or service release. The Structured Query Language (SQL) GROUP BY predicate organizes the returned recordset according to one or more of the properties specified in the SQLSELECT Statement.

Syntax

GROUP BY "propertyName" [,"propertyName"]  [,"propertyName"]

The parameter propertyName specifies properties selected in your SQL query that you want to group.

Remarks

If you include the visiblecount Field in the SELECT Statement, a count of the occurrences of matching items, as specified by GROUP BY, will be created.

GROUP BY is not supported on Multi-Value properties.

Example

Getting Item Counts with GROUP BY

Send us your feedback about the Microsoft Exchange Server 2003 SDK.

Build: June 2007 (2007.618.1)

© 2003-2006 Microsoft Corporation. All rights reserved. Terms of use.