MQT optimization choices
The MQTOptimizationChoices group defines a set of elements that can be used to influence materialized query table (MQT) optimization. In particular, these elements can be used to enable or disable consideration of MQT substitution, or to specify the complete set of MQTs that are to be considered by the optimizer.
XML Schema
<xs:group name="MQTOptimizationChoices">
<xs:choice>
<xs:element name="MQTOPT" minOccurs="0" maxOccurs="1">
<xs:complexType>
<xs:attribute name="OPTION" type="optionType" use="optional"/>
</xs:complexType>
</xs:element>
<xs:element name="MQT" minOccurs="0" maxOccurs="unbounded">
<xs:complexType>
<xs:attribute name="NAME" type="xs:string" use="required"/>
</xs:complexType>
</xs:element>
</xs:choice>
</xs:group>
Description
The MQTOPT element is used to enable or disable consideration of MQT optimization. The OPTION attribute can take the value ENABLE (default) or DISABLE.
The NAME attribute of an MQT element identifies an MQT that is to be considered by the optimizer. The rules for forming a reference to an MQT in the NAME attribute are the same as those for forming references to exposed table names. If one or more MQT elements are specified, only those MQTs are considered by the optimizer. The decision to perform MQT substitution using one or more of the specified MQTs remains a cost-based decision.
Examples
<OPTGUIDELINES>
<MQTOPT OPTION='DISABLE'/>
</OPTGUIDELINES>
<OPTGUIDELINES>
<MQT NAME='Samp.PARTSMQT'/>
<MQT NAME='COLLEGE.STUDENTS'/>
</OPTGUIDELINES>