Abstract:
Data in materialized query tables (MQTs) are used as statistics for determining the optimal execution plan for a query. When an MQT is defined, it is examined to determine whether its data provides statistics for determining an optimal execution plan for a query. If so, then the MQT is identified, in the RDBMS, as a source for statistics. Information needed to exploit the MQT data as statistics is cataloged in the RDBMS. This information includes a characterization of the type of statistics provided by the MQT, the table and column distributions represented by those statistics, and a query for later retrieving relevant data from the MQT during the query optimization process. When a query is accepted for execution, the cataloged relevant information about MQTs is examined to determine whether an MQT exists that provides statistics relevant to optimization of the query. If such an MQT exists, then the relevant data is retrieved from the MQT using the cataloged query. Using the retrieved statistics, an optimal execution plan may be determined for the query.
Abstract:
One or more transformation functions can be used in connection or together with one or more compression/decompression techniques. A transformation function can transform data (e.g., a data object) into a form more suitable for compression and/or decompression. As a result, data can be compressed and/or decompressed more effectively. In addition, multiple data objects can be associated with various transformation functions and/or compression/decompression techniques. As a result, different approaches can be taken with respect to compression and decompression of data objects in an effort to find an optimum approach for compression of data objects that may vary significantly from each other and change over time. It will be appreciated that the objects can be associated with transformation functions in a dynamic manner to accommodate changes to data. Also, an extendible and/or extensible system can allow for growth and adaption of new data in forms not currently present or expected.
Abstract:
A method and system are provided for optimizing a query migrated from a source database system to a possibly dissimilar target database system, wherein the execution plan chosen for the migrated query is communicated from the source database system. Explain facilities of the source database system are used to gather information describing the execution plan used in the source database system for the migrated query. The explain information is then used to obtain plan directives for communicating the execution plan to the optimizer of the target system. If the obtained plan directives require auxiliary data structures, the source system catalogs are queried to determine the attributes of these auxiliary structures. These attributes are then used to create equivalent auxiliary structures in the target system. The migrated query is then optimized using the obtained plan directives, thus enabling database migration to preserve the investment made in tuning the execution plan on the source system
Abstract:
One or more transformation functions can be used in connection or together with one or more compression/decompression techniques. A transformation function can transform data (e.g., a data object) into a form more suitable for compression and/or decompression. As a result, data can be compressed and/or decompressed more effectively. In addition, multiple data objects can be associated with various transformation functions and/or compression/decompression techniques. As a result, different approaches can be taken with respect to compression and decompression of data objects in an effort to find an optimum approach for compression of data objects that may vary significantly from each other and change over time. It will be appreciated that the objects can be associated with transformation functions in a dynamic manner to accommodate changes to data. Also, an extendible and/or extensible system can allow for growth and adaption of new data in forms not currently present or expected.
Abstract:
Method, apparatus and computer usable medium tangibly embodying a program of instructions is provided for performing advanced cost/benefit analysis of subplans of a query execution plan, in a computer system having a database software server. Method augments a cost estimation model, obtained from an optimizer of the software server after determination of an optimal query execution plan, with a cost/benefit analysis of operating each subplan of the query execution plan asynchronously. It calculates a subplan elapsed time benefit of making the subplan asynchronous using a set of cost estimates for each subplan operation and knowledge of the execution sequence of the query execution plan operations, all provided by the query optimizer. Set of subplans for asynchronous execution is chosen to form an optimal set of subplans while respecting a resource constraint, for providing a maximal reduction of the total query elapsed time while conserving system resources of the software server.
Abstract:
A method, system, and computer program product to make query processing more robust in the face of optimization errors. The invention validates the statistics and assumptions used for compiling a query as the query is executed and, when necessary, progressively re-optimizes the query in mid-execution based on the knowledge learned during its partial execution. The invention selectively places a number of CHECK operators in a query execution plan to validate the optimizer's cardinality estimates against actual cardinalities. Errors beyond a threshold trigger re-optimization, and the optimizer decides whether the old plan is still optimal and whether to re-use previously computed results. The invention addresses arbitrary SQL queries whose plans can contain sub-queries, updates, trigger checking, and view maintenance operations. The invention can handle concurrent update transactions or updates of common sub-expressions in a query execution plan without compromising consistency and isolation as locking information is tied to the record ID.