| US 7,599,925 B2 | ||
| Using query expression signatures in view matching | ||
| Per-Ake Larson, Redmond, Wash. (US); David Edward DeHann, Waterloo (Canada); and Jingren Zhou, Redmond, Wash. (US) | ||
| Assigned to Microsoft Corporation, Redmond, Wash. (US) | ||
| Filed on Mar. 31, 2005, as Appl. No. 11/94,924. | ||
| Prior Publication US 2006/0230017 A1, Oct. 12, 2006 | ||
| Int. Cl. G06F 17/30 (2006.01) | ||
| U.S. Cl. 707—4 [707/2; 707/3] | 10 Claims |

| 1. A computer implemented system for optimizing queries against a database, comprising:
at least a processor executing the following components:
a memo structure that encodes a plurality of query expressions frequently encountered in queries as a set of explored operator
trees such that an operator tree comprises at least select, project, join and group-by operators;
a signature mechanism that enables an assignment of the query expressions into equivalence classes, each class access the
same set of base tables, wherein the signature data structure is a synopsis of the plurality of query expressions in the memo
structure and is stored in the memo structure, the signature facilitates identification of at least one query expression from
the memo structure that can be matched and substituted with at least a subset of a given query expression, the identified
query expression is utilized to access a stacked materialized view of the database, wherein each signature for an operator
tree in the memo structure is a tuple comprising at least an indication of whether a root of the corresponding operator tree
is a group-by operator, a set of sources including tables and views used as input for operators with in the operator tree,
and a set of candidate views for the operator tree; and
wherein memory coupled to a processor retains the memo structure or the signature mechanism.
|