Grouped Item Queries

FindItem surfaces two mutually exclusive elements that we have deftly passed over until now. These elements enable you to indicate that the results of a FindItem operation should be returned in groups rather than as a flat list of items. The group that a given item will be returned in is dictated by the attributes in the grouping element. For instance, if you perform a FindItem against your Mailbox and group the results by sender, you should expect to get a group back for each unique sender in your Mailbox. Each group would contain the items sent by the sender represented by that group. Example 15-7 shows the structure of the grouping elements within the FindItem request type as defined in messages.xsd.

Example 15-7. Grouping ...

Get Inside Microsoft® Exchange Server 2007 Web Services now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.