US20080215536A1 - Autonomically generating a query implementation that meets a defined performance specification - Google Patents
Autonomically generating a query implementation that meets a defined performance specification Download PDFInfo
- Publication number
- US20080215536A1 US20080215536A1 US12/108,027 US10802708A US2008215536A1 US 20080215536 A1 US20080215536 A1 US 20080215536A1 US 10802708 A US10802708 A US 10802708A US 2008215536 A1 US2008215536 A1 US 2008215536A1
- Authority
- US
- United States
- Prior art keywords
- query
- access plan
- performance specification
- performance
- stored
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Abandoned
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/20—Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
- G06F16/24—Querying
- G06F16/245—Query processing
- G06F16/2452—Query translation
- G06F16/24524—Access plan code generation and invalidation; Reuse of access plans
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/20—Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
- G06F16/24—Querying
- G06F16/245—Query processing
- G06F16/2453—Query optimisation
- G06F16/24534—Query rewriting; Transformation
- G06F16/24542—Plan optimisation
Definitions
- computers Since the dawn of the computer age, computers have evolved and become more and more powerful. In our present day, computers have become indispensable in many fields of human endeavor including engineering design, machine and process control, information storage and retrieval, and office computing.
- One of the primary uses of computers is for information storage and retrieval.
- Database systems have been developed that allow a computer to store a large amount of information in a way that allows a user to search for and retrieve specific information in the database.
- an insurance company may have a database that includes all of its policy holders and their current account information, including payment history, premium amount, policy number, policy type, exclusions to coverage, etc.
- a database system allows the insurance company to retrieve the account information for a single policy holder among the thousands and perhaps millions of policy holders in its database.
- a query usually specifies conditions that apply to one or more columns of the database, and may specify relatively complex logical operations on multiple columns.
- the database is searched for records that satisfy the query, and those records are returned as the query result.
- Queries that are frequently run may be optimized to enhance system performance.
- One known way to optimize a query is to build an access plan the first time a query is run, then reuse the access plan for subsequent executions of the same query. Note, however, that the performance of the query may be fine at the point in time when the access plan was generated, but due to changes in the database, software, etc., the same access plan may experience a marked slowdown in query performance.
- the initial access plan is based on an estimate of performance instead of on actual execution time, the initial access plan may not be a very efficient implementation of the query. In the prior art, there is no way for the database optimizer to detect when an access plan performs poorly.
- a database query optimizer allows specifying a performance specification for a query.
- the actual performance for executing the query using the access plan is determined and compared to the performance specification for the query. If the actual performance does not satisfy the performance specification for the query, the query optimizer autonomically generates a different access plan to see if the performance improves. If an access plan that meets the performance specification is generated, the new access plan is stored in the access plan cache for the query. If no access plan can be generated that meets the performance specification for the query, the access plan that provided the best performance is selected and stored in the access plan cache for the query.
- FIG. 1 is a block diagram of an apparatus in accordance with the preferred embodiments
- FIG. 2 is a block diagram showing the details of the query access plan cache 127 shown in FIG. 1 ;
- FIG. 4 is a flow diagram of a method in accordance with the preferred embodiments for autonomically detecting when query performance degrades and for generating a different query implementation that improves the performance of executing the query;
- FIG. 5 shows a sample query for illustrating the concepts of the preferred embodiments
- FIG. 6 shows three sample tables with sample data that represent the tables referenced in the query of FIG. 5 ;
- FIG. 7 is a block diagram of an entry in the access plan cache in FIG. 2 in accordance with the preferred embodiments.
- FIG. 8 is a block diagram of the entry in FIG. 7 after the query optimizer performs method 400 in FIG. 4 to generate a better query implementation
- RDB relational database
- a database query is an expression that is evaluated by a database manager.
- the expression may contain one or more predicate expressions that are used to retrieve data from a database. For example, let's assume there is a database for a company that includes a table of employees, with columns in the table that represent the employee's name, address, phone number, gender, and salary. With data stored in this format, a query could be formulated that would retrieve the records for all female employees that have a salary greater than $40,000. Similarly, a query could be formulated that would retrieve the records for all employees that have a particular area code or telephone prefix.
- SQL Structured Query Language
- FIG. 5 One sample SQL query is shown in FIG. 5 .
- the “select count(*)” statement tells the database query processor to count the occurrence of data values
- the “from X, Y, Z” statement identifies three database tables, namely X, Y and Z, to search
- the “where” clause specifies expressions (or predicates) that must be satisfied for a record to be included in the resulting dataset.
- X.j 1 means column j 1 in table X.
- Y.j 1 means column j 1 in table Y
- X.j 2 means column j 2 in table X
- Z.j 2 means column j 2 in table Z.
- Sample database tables X, Y, Z with arbitrary sample data is shown in FIG. 6 .
- An access plan is one way that the database manager may process the query.
- An access plan represents one possible implementation for executing a query.
- the access plan may be stored in an access plan cache, which is represented as 310 in FIG. 3 .
- the access plan cache 310 contains one or more queries 125 with their corresponding access plans 320 .
- query A 125 A has a corresponding access plan 320 A
- query B 125 B has a corresponding access plan 320 B
- query N 125 N has a corresponding access plan 320 N.
- FIG. 1 access plan cache 310 shown in FIG.
- the access plan that is selected to run the query the first time is typically stored in the access plan cache.
- the access plan is selected based on estimates of performance.
- Access plans may be rebuilt by the optimizer when certain changes to the database occur.
- the new access plan is still based on an estimated performance, not on actual run-time performance.
- the prior art does not monitor the run-time performance of queries.
- the end result with the prior art is the use of access plans that may have run-time performance that is grossly inefficient compared to their estimated performance.
- the present invention avoids the problems discussed above in the prior art by storing a query performance specification with each access plan stored in the access plan cache.
- This query performance specification allows the database manager to detect when the performance of the query becomes unacceptable. Should the performance of the stored access plan become unacceptable (i.e., it no longer satisfies the query performance specification), the query optimizer may generate other access plans in an attempt to generate one that satisfies the query performance specification. If no access plan can be generated that satisfies the query performance specification, the access plan that provided the best performance may be selected. In this manner, the query optimizer dynamically and autonomically detects when query performance becomes unacceptable, and makes appropriate corrections to keep the database performance as high as possible.
- a computer system 100 is one suitable implementation of an apparatus in accordance with the preferred embodiments of the invention.
- Computer system 100 is an IBM eServer iSeries computer system.
- IBM eServer iSeries computer system As shown in FIG. 1 , computer system 100 comprises a processor 110 , a main memory 120 , a mass storage interface 130 , a display interface 140 , and a network interface 150 . These system components are interconnected through the use of a system bus 160 .
- Mass storage interface 130 is used to connect mass storage devices, such as a direct access storage device 155 , to computer system 100 .
- mass storage devices such as a direct access storage device 155
- One specific type of direct access storage device 155 is a readable and writable CD RW drive, which may store data to and read data from a CD RW 195 .
- Main memory 120 in accordance with the preferred embodiments contains data 121 , an operating system 122 , a database 123 , a database manager 124 , one or more database queries 125 , and a database query optimizer 126 .
- Data 121 represents any data that serves as input to or output from any program in computer system 100 .
- Operating system 122 is a multitasking operating system known in the industry as iSeries; however, those skilled in the art will appreciate that the spirit and scope of the present invention is not limited to any one operating system.
- Database 123 is any suitable database, whether currently known or developed in the future. Database 123 preferably includes one or more tables.
- Database manager 124 provides an interface to database 123 , processing queries and returning the query results.
- Database query 125 is a query in a format compatible with the database 123 that allows retrieval of information stored in the database 123 that satisfies the database query 125 .
- Database query optimizer 126 processes database query 125 to optimize database query 125 .
- Database query optimizer 126 includes an access plan cache 127 that stores access plans and corresponding query performance specifications in accordance with the preferred embodiments. Details of the access plan cache 127 in FIG. 1 are shown in FIG. 2 . Each entry in the access plan cache 127 includes the query 125 , a performance specification for the query 210 , and a stored access plan 220 .
- the query optimizer may use the query implementation generation mechanism 128 ( FIG. 1 ) to autonomically generate a different access plan that provides improved performance in executing the query.
- the query implementation generation mechanism 128 generates one or more different access plans in an attempt to generate an access plan that meets the performance specification for the query. Should the query implementation generation mechanism 128 fail to generate a query implementation (or access plan) that meets the performance specification for the query, the query implementation generation mechanism 128 may select the query implementation that yielded the best performance.
- the query implementation generation mechanism 128 may change the query performance specification if no query implementation is generated that satisfies the query performance specification.
- One suitable way to change the query performance specification is to use the best performance to generate a suitable query performance specification.
- database query optimizer 126 is shown in FIG. 1 to be separate from the other items in main memory 120 , it is also within the scope of the preferred embodiments to include the database query optimizer 126 as part of the database manager 124 , or as part of any other computer program.
- the access plan cache 127 may be part of the query optimizer 126 , or may be separate from the query optimizer 126 .
- Computer system 100 utilizes well known virtual addressing mechanisms that allow the programs of computer system 100 to behave as if they only have access to a large, single storage entity instead of access to multiple, smaller storage entities such as main memory 120 and DASD device 155 . Therefore, while data 121 , operating system 122 , database 123 , database manager 124 , database query 125 , and database query optimizer 126 are shown to reside in main memory 120 , those skilled in the art will recognize that these items are not necessarily all completely contained in main memory 120 at the same time. It should also be noted that the term “memory” is used herein to generically refer to the entire virtual memory of computer system 100 , and may include the virtual memory of other computer systems coupled to computer system 100 .
- Processor 110 may be constructed from one or more microprocessors and/or integrated circuits. Processor 110 executes program instructions stored in main memory 120 . Main memory 120 stores programs and data that processor 110 may access. When computer system 100 starts up, processor 110 initially executes the program instructions that make up operating system 122 . Operating system 122 is a sophisticated program that manages the resources of computer system 100 . Some of these resources are processor 110 , main memory 120 , mass storage interface 130 , display interface 140 , network interface 150 , and system bus 160 .
- computer system 100 is shown to contain only a single processor and a single system bus, those skilled in the art will appreciate that the present invention may be practiced using a computer system that has multiple processors and/or multiple buses.
- the interfaces that are used in the preferred embodiment each include separate, fully programmed microprocessors that are used to off-load compute-intensive processing from processor 110 .
- processor 110 processors 110
- the present invention applies equally to computer systems that simply use I/O adapters to perform similar functions.
- Display interface 140 is used to directly connect one or more displays 165 to computer system 100 .
- These displays 165 which may be non-intelligent (i.e., dumb) terminals or fully programmable workstations, are used to allow system administrators and users to communicate with computer system 100 . Note, however, that while display interface 140 is provided to support communication with one or more displays 165 , computer system 100 does not necessarily require a display 165 , because all needed interaction with users and other processes may occur via network interface 150 .
- Network interface 150 is used to connect other computer systems and/or workstations (e.g., 175 in FIG. 1 ) to computer system 100 across a network 170 .
- the present invention applies equally no matter how computer system 100 may be connected to other computer systems and/or workstations, regardless of whether the network connection 170 is made using present-day analog and/or digital techniques or via some networking mechanism of the future.
- many different network protocols can be used to implement a network. These protocols are specialized computer programs that allow computers to communicate across network 170 .
- TCP/IP Transmission Control Protocol/Internet Protocol
- a method 400 in accordance with the preferred embodiments begins by selecting a query in an access plan cache (step 410 ).
- the execution time for the query using the access plan is determined (step 420 ).
- the execution time may be an estimate, but is preferably the actual execution time for an execution of the query.
- step 460 NO
- Method 400 may be performed at any suitable time within the scope of the preferred embodiments. For example, different query implementations could be run during a calibration run of the database. In the alternative, method 400 may be performed at any time, or even every time a query is executed.
- the query optimizer To execute the query in FIG. 5 , the query optimizer must decide on a join order for the tables.
- the join order for the tables in the access plan is X->Y->Z, as shown in the access plan cache entry in FIG. 7 .
- the performance specification is 30 time units, where a time unit is defined as the time required to probe the database.
- step 440 in FIG. 4 NO
- the query optimizer generates other access plans to see if an access plan can be generated that meets the performance specification of 30 time units.
- the join order X->Z->Y is then generated in an access plan in step 470 of FIG. 4 .
- the execution time for the new access plan is then determined in step 420 .
- an access plan that satisfies the performance specification for the query is generated, it is stored as the access plan for the query in the access plan cache (step 450 ). If no access plan is generated that satisfies the performance specification for the query, the access plan with the best performance is stored as the access plan for the query in the access plan cache (step 480 ).
- the performance specification for a query may be specified in any suitable units of measurement. Examples of some suitable units of measurement are shown in FIGS. 8-12 by way of example.
- the unit of measurement for the performance specification is “time units”, which are defined as probes to the database.
- the unit of measurement for the performance specification in FIG. 9 is an absolute time measurement in seconds, such as 100 ms.
- the unit of measurement for the performance specification in FIG. 10 is specified in processor cycles.
- the unit of measurement for the performance specification in FIG. 11 is specified in bus cycles.
- the unit of measurement for the performance specification in FIG. 12 is specified in disk I/Os.
- FIG. 13 presents an interesting case of a “sliding scale” where the value of the performance specification depends on the value of a target execution time for the query.
- the “target time” is abbreviated in FIG. 13 as TT.
- the performance specification is 10 times the target time. If the target time is between 100 ms and 10 seconds, the performance specification is 3 times the target time. If the target time is between 10 seconds and eight hours, the performance specification is 2 times the target time. If the target time is over eight hours, the performance specification is 1.5 times the target time.
- the sliding scale shown in FIG. 13 allows specifying different performance specifications for a query depending on the target time for executing the query.
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Computational Linguistics (AREA)
- Data Mining & Analysis (AREA)
- Databases & Information Systems (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Operations Research (AREA)
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
Abstract
A database query optimizer allows specifying a performance specification for a query. When an access plan is created, the actual performance for executing the query using the access plan is determined and compared to the performance specification for the query. If the actual performance does not satisfy the performance specification for the query, the query optimizer autonomically generates a different access plan to see if the performance improves. If an access plan that meets the performance specification is generated, the new access plan is stored in the access plan cache for the query. If no access plan can be generated that meets the performance specification for the query, the access plan that provided the best performance is selected and stored in the access plan cache for the query.
Description
- This patent application is a continuation of a “Apparatus and Method for Autonomically Generating a Query Implementation that Meets a Defined Performance Specification,” U.S. Ser. No. 10/860,402 filed on Jun. 3, 2004, which is incorporated herein by reference.
- 1. Technical Field
- This invention generally relates to computer systems, and more specifically relates to apparatus and methods for optimizing the run-time performance of a database query.
- 2. Background Art
- Since the dawn of the computer age, computers have evolved and become more and more powerful. In our present day, computers have become indispensable in many fields of human endeavor including engineering design, machine and process control, information storage and retrieval, and office computing. One of the primary uses of computers is for information storage and retrieval.
- Database systems have been developed that allow a computer to store a large amount of information in a way that allows a user to search for and retrieve specific information in the database. For example, an insurance company may have a database that includes all of its policy holders and their current account information, including payment history, premium amount, policy number, policy type, exclusions to coverage, etc. A database system allows the insurance company to retrieve the account information for a single policy holder among the thousands and perhaps millions of policy holders in its database.
- Retrieval of information from a database is typically done using queries. A query usually specifies conditions that apply to one or more columns of the database, and may specify relatively complex logical operations on multiple columns. The database is searched for records that satisfy the query, and those records are returned as the query result.
- Queries that are frequently run may be optimized to enhance system performance. One known way to optimize a query is to build an access plan the first time a query is run, then reuse the access plan for subsequent executions of the same query. Note, however, that the performance of the query may be fine at the point in time when the access plan was generated, but due to changes in the database, software, etc., the same access plan may experience a marked slowdown in query performance. In addition, because the initial access plan is based on an estimate of performance instead of on actual execution time, the initial access plan may not be a very efficient implementation of the query. In the prior art, there is no way for the database optimizer to detect when an access plan performs poorly. Without a way to specify desired performance for a query and autonomically generate a new access plan when the current access plan no longer satisfies the desired performance, the database industry will continue to suffer from undue performance penalties by continually reusing access plans that provide poor performance in executing a query.
- According to the preferred embodiments, a database query optimizer allows specifying a performance specification for a query. When an access plan is created, the actual performance for executing the query using the access plan is determined and compared to the performance specification for the query. If the actual performance does not satisfy the performance specification for the query, the query optimizer autonomically generates a different access plan to see if the performance improves. If an access plan that meets the performance specification is generated, the new access plan is stored in the access plan cache for the query. If no access plan can be generated that meets the performance specification for the query, the access plan that provided the best performance is selected and stored in the access plan cache for the query.
- The foregoing and other features and advantages of the invention will be apparent from the following more particular description of preferred embodiments of the invention, as illustrated in the accompanying drawings.
- The preferred embodiments of the present invention will hereinafter be described in conjunction with the appended drawings, where like designations denote like elements, and:
-
FIG. 1 is a block diagram of an apparatus in accordance with the preferred embodiments; -
FIG. 2 is a block diagram showing the details of the queryaccess plan cache 127 shown inFIG. 1 ; -
FIG. 3 is a block diagram of a prior art access plan cache; -
FIG. 4 is a flow diagram of a method in accordance with the preferred embodiments for autonomically detecting when query performance degrades and for generating a different query implementation that improves the performance of executing the query; -
FIG. 5 shows a sample query for illustrating the concepts of the preferred embodiments; -
FIG. 6 shows three sample tables with sample data that represent the tables referenced in the query ofFIG. 5 ; -
FIG. 7 is a block diagram of an entry in the access plan cache inFIG. 2 in accordance with the preferred embodiments; -
FIG. 8 is a block diagram of the entry inFIG. 7 after the query optimizer performsmethod 400 inFIG. 4 to generate a better query implementation; and -
FIGS. 9-14 each show different ways to specify a query performance specification for a query in the access plan cache of the preferred embodiments. - The present invention relates to optimizing database queries. For those not familiar with databases or queries, this Overview section will provide background information that will help to understand the present invention.
- Known Databases and Database Queries
- There are many different types of databases known in the art. The most common is known as a relational database (RDB), which organizes data in tables that have rows that represent individual entries or records in the database, and columns that define what is stored in each entry or record.
- To be useful, the data stored in databases must be able to be efficiently retrieved. The most common way to retrieve data from a database is to generate a database query. A database query is an expression that is evaluated by a database manager. The expression may contain one or more predicate expressions that are used to retrieve data from a database. For example, let's assume there is a database for a company that includes a table of employees, with columns in the table that represent the employee's name, address, phone number, gender, and salary. With data stored in this format, a query could be formulated that would retrieve the records for all female employees that have a salary greater than $40,000. Similarly, a query could be formulated that would retrieve the records for all employees that have a particular area code or telephone prefix.
- One popular way to define a query uses Structured Query Language (SQL). SQL defines a syntax for generating and processing queries that is independent of the actual structure and format of the database. One sample SQL query is shown in
FIG. 5 . The “select count(*)” statement tells the database query processor to count the occurrence of data values, the “from X, Y, Z” statement identifies three database tables, namely X, Y and Z, to search, and the “where” clause specifies expressions (or predicates) that must be satisfied for a record to be included in the resulting dataset. For this particular example, the “where” clause states: “where X.j1=Y.j1 and X.j2=Z.j2. The term X.j1 means column j1 in table X. In similar fashion, the term Y.j1 means column j1 in table Y, the term X.j2 means column j2 in table X, and the term Z.j2 means column j2 in table Z. Sample database tables X, Y, Z with arbitrary sample data is shown inFIG. 6 . Thus, the query ofFIG. 5 will count the number of records where X.j1=Y.j1 and X.j2=Z.j2. Note that the query ofFIG. 5 is expressed in terms of columns X.j1, X.j2, Y.j 1, and Z.j2, which are columns defined on the database tables X, Y and Z as shown inFIG. 6 . Information about the internal storage of the data is not required as long as the query is written in terms of expressions that relate to values in columns from tables. - We assume the query of
FIG. 5 is executed. The first time the query is executed, an access plan for the query is generated. An access plan is one way that the database manager may process the query. An access plan represents one possible implementation for executing a query. The access plan may be stored in an access plan cache, which is represented as 310 inFIG. 3 . Theaccess plan cache 310 contains one ormore queries 125 with their corresponding access plans 320. Thus, query A 125A has acorresponding access plan 320A;query B 125B has acorresponding access plan 320B; and queryN 125N has acorresponding access plan 320N. In the prior artaccess plan cache 310 shown inFIG. 3 , the access plan that is selected to run the query the first time is typically stored in the access plan cache. Note, however, that the access plan is selected based on estimates of performance. Experience has shown that such estimates are not always accurate, and the run-time performance of a query using a selected access plan may be orders of magnitude greater than the estimated performance. Access plans may be rebuilt by the optimizer when certain changes to the database occur. However, the new access plan is still based on an estimated performance, not on actual run-time performance. Herein lies two fundamental problems with the prior art. First, the prior art does not monitor the run-time performance of queries. Second, even if the prior art did monitor the run-time performance of queries, it would have no way of knowing whether the run-time performance is acceptable or not. The end result with the prior art is the use of access plans that may have run-time performance that is grossly inefficient compared to their estimated performance. - The present invention avoids the problems discussed above in the prior art by storing a query performance specification with each access plan stored in the access plan cache. This query performance specification allows the database manager to detect when the performance of the query becomes unacceptable. Should the performance of the stored access plan become unacceptable (i.e., it no longer satisfies the query performance specification), the query optimizer may generate other access plans in an attempt to generate one that satisfies the query performance specification. If no access plan can be generated that satisfies the query performance specification, the access plan that provided the best performance may be selected. In this manner, the query optimizer dynamically and autonomically detects when query performance becomes unacceptable, and makes appropriate corrections to keep the database performance as high as possible.
- Referring to
FIG. 1 , acomputer system 100 is one suitable implementation of an apparatus in accordance with the preferred embodiments of the invention.Computer system 100 is an IBM eServer iSeries computer system. However, those skilled in the art will appreciate that the mechanisms and apparatus of the present invention apply equally to any computer system, regardless of whether the computer system is a complicated multi-user computing apparatus, a single user workstation, or an embedded control system. As shown inFIG. 1 ,computer system 100 comprises aprocessor 110, amain memory 120, amass storage interface 130, adisplay interface 140, and anetwork interface 150. These system components are interconnected through the use of asystem bus 160.Mass storage interface 130 is used to connect mass storage devices, such as a directaccess storage device 155, tocomputer system 100. One specific type of directaccess storage device 155 is a readable and writable CD RW drive, which may store data to and read data from aCD RW 195. -
Main memory 120 in accordance with the preferred embodiments containsdata 121, anoperating system 122, adatabase 123, adatabase manager 124, one or more database queries 125, and adatabase query optimizer 126.Data 121 represents any data that serves as input to or output from any program incomputer system 100.Operating system 122 is a multitasking operating system known in the industry as iSeries; however, those skilled in the art will appreciate that the spirit and scope of the present invention is not limited to any one operating system.Database 123 is any suitable database, whether currently known or developed in the future.Database 123 preferably includes one or more tables.Database manager 124 provides an interface todatabase 123, processing queries and returning the query results.Database query 125 is a query in a format compatible with thedatabase 123 that allows retrieval of information stored in thedatabase 123 that satisfies thedatabase query 125. Database query optimizer 126processes database query 125 to optimizedatabase query 125.Database query optimizer 126 includes anaccess plan cache 127 that stores access plans and corresponding query performance specifications in accordance with the preferred embodiments. Details of theaccess plan cache 127 inFIG. 1 are shown inFIG. 2 . Each entry in theaccess plan cache 127 includes thequery 125, a performance specification for thequery 210, and a storedaccess plan 220. Thus,access plan cache 127 includes anentry 125A that corresponds to Query A, theperformance specification 210A for query A, and the storedaccess plan 220A for query A. In similar fashion, anentry 125B that corresponds to Query B includes aperformance specification 210B for query B, and the storedaccess plan 220B for query B. Other queries may also be stored in theaccess plan cache 127, as shown byentry 125N that corresponds to Query N that includes aperformance specification 210N for query N, and the storedaccess plan 220N for query N. Note that the main difference between theaccess plan cache 127 of the preferred embodiments and the prior artaccess plan cache 310 shown inFIG. 3 is the presence of the query performance specification for each entry in theaccess plan cache 127 inFIG. 2 . This difference allows the query optimizer to autonomically determine when the performance of the stored access plan becomes unacceptable. Once the query optimizer determines that the stored access plan in the access plan cache does not meet the query performance specification, the query optimizer may use the query implementation generation mechanism 128 (FIG. 1 ) to autonomically generate a different access plan that provides improved performance in executing the query. The queryimplementation generation mechanism 128 generates one or more different access plans in an attempt to generate an access plan that meets the performance specification for the query. Should the queryimplementation generation mechanism 128 fail to generate a query implementation (or access plan) that meets the performance specification for the query, the queryimplementation generation mechanism 128 may select the query implementation that yielded the best performance. In addition, the queryimplementation generation mechanism 128 may change the query performance specification if no query implementation is generated that satisfies the query performance specification. One suitable way to change the query performance specification is to use the best performance to generate a suitable query performance specification. - While
database query optimizer 126 is shown inFIG. 1 to be separate from the other items inmain memory 120, it is also within the scope of the preferred embodiments to include thedatabase query optimizer 126 as part of thedatabase manager 124, or as part of any other computer program. In addition, theaccess plan cache 127 may be part of thequery optimizer 126, or may be separate from thequery optimizer 126. -
Computer system 100 utilizes well known virtual addressing mechanisms that allow the programs ofcomputer system 100 to behave as if they only have access to a large, single storage entity instead of access to multiple, smaller storage entities such asmain memory 120 andDASD device 155. Therefore, whiledata 121,operating system 122,database 123,database manager 124,database query 125, anddatabase query optimizer 126 are shown to reside inmain memory 120, those skilled in the art will recognize that these items are not necessarily all completely contained inmain memory 120 at the same time. It should also be noted that the term “memory” is used herein to generically refer to the entire virtual memory ofcomputer system 100, and may include the virtual memory of other computer systems coupled tocomputer system 100. -
Processor 110 may be constructed from one or more microprocessors and/or integrated circuits.Processor 110 executes program instructions stored inmain memory 120.Main memory 120 stores programs and data thatprocessor 110 may access. Whencomputer system 100 starts up,processor 110 initially executes the program instructions that make upoperating system 122.Operating system 122 is a sophisticated program that manages the resources ofcomputer system 100. Some of these resources areprocessor 110,main memory 120,mass storage interface 130,display interface 140,network interface 150, andsystem bus 160. - Although
computer system 100 is shown to contain only a single processor and a single system bus, those skilled in the art will appreciate that the present invention may be practiced using a computer system that has multiple processors and/or multiple buses. In addition, the interfaces that are used in the preferred embodiment each include separate, fully programmed microprocessors that are used to off-load compute-intensive processing fromprocessor 110. However, those skilled in the art will appreciate that the present invention applies equally to computer systems that simply use I/O adapters to perform similar functions. -
Display interface 140 is used to directly connect one ormore displays 165 tocomputer system 100. Thesedisplays 165, which may be non-intelligent (i.e., dumb) terminals or fully programmable workstations, are used to allow system administrators and users to communicate withcomputer system 100. Note, however, that whiledisplay interface 140 is provided to support communication with one ormore displays 165,computer system 100 does not necessarily require adisplay 165, because all needed interaction with users and other processes may occur vianetwork interface 150. -
Network interface 150 is used to connect other computer systems and/or workstations (e.g., 175 inFIG. 1 ) tocomputer system 100 across anetwork 170. The present invention applies equally no matter howcomputer system 100 may be connected to other computer systems and/or workstations, regardless of whether thenetwork connection 170 is made using present-day analog and/or digital techniques or via some networking mechanism of the future. In addition, many different network protocols can be used to implement a network. These protocols are specialized computer programs that allow computers to communicate acrossnetwork 170. TCP/IP (Transmission Control Protocol/Internet Protocol) is an example of a suitable network protocol. - At this point, it is important to note that while the present invention has been and will continue to be described in the context of a fully functional computer system, those skilled in the art will appreciate that the present invention is capable of being distributed as a program product in a variety of forms, and that the present invention applies equally regardless of the particular type of computer-readable signal bearing media used to actually carry out the distribution. Examples of suitable computer-readable signal bearing media include: recordable type media such as floppy disks and CD RW (e.g., 195 of
FIG. 1 ), and transmission type media such as digital and analog communications links. - Referring to
FIG. 4 , amethod 400 in accordance with the preferred embodiments begins by selecting a query in an access plan cache (step 410). The execution time for the query using the access plan is determined (step 420). Note that the execution time may be an estimate, but is preferably the actual execution time for an execution of the query. The execution time is then compared with the performance specification for the query that is stored in the access plan cache (step 430). If the performance specification for the query is satisfied (step 440=YES), the access plan is stored in the access plan cache in the entry corresponding to the query (step 450). If the actual performance of the new access plan is considerably better than the current performance specification, the performance specification for the query could also optionally be updated (step 452) to reflect the better performance of the newly-generated access plan. At this point,method 400 is done. If the performance specification is not satisfied (step 440=NO), and if there are more access plans to try (step 460=YES), a new access plan is generated for the query (step 470), andmethod 400 then loops back tostep 420. This process continues until either the performance specification is satisfied (step 440=YES), or the performance specification is not satisfied (step 440=NO) and there are no more access plans to try (step 460=NO). Note thatstep 460 does not imply that every conceivable access plan must be generated (or tried). If the optimizer can determine that the remaining access plans that could be generated will be more inefficient than those already generated, the optimizer may determine that there are no more access plans to try (step 460=NO), even if there remain access plans for the query that have not yet been generated. If the performance specification is not satisfied (step 440=NO) and there are no more access plans to try (step 460=NO), the access plan with the best performance is stored in the access plan cache (step 480). In addition, the best performance may be used to generate a new performance specification for the query (step 490). Note thatstep 490 is optional, and therefore need not necessarily be performed. -
Method 400 may be performed at any suitable time within the scope of the preferred embodiments. For example, different query implementations could be run during a calibration run of the database. In the alternative,method 400 may be performed at any time, or even every time a query is executed. - An example now follows that will illustrate the concepts of the present invention. Refer to the query in
FIG. 5 and the corresponding tables inFIG. 6 . To execute the query inFIG. 5 , the query optimizer must decide on a join order for the tables. We assume for this example that the join order for the tables in the access plan is X->Y->Z, as shown in the access plan cache entry inFIG. 7 . We also assume for this example that the performance specification is 30 time units, where a time unit is defined as the time required to probe the database. Suppose the access plan for a join order of X —>Y->Z as shown in the access plan cache entry inFIG. 7 takes 10 “X probes” which requires 20 “Y probes”, each of which looks at Z once, for a total of 50 probes or time units. Because the execution time for the query using the access plan shown inFIG. 7 requires 50 time units, and because the performance specification for the query inFIG. 7 is 30 time units (step 440 in FIG. 4=NO), the query optimizer generates other access plans to see if an access plan can be generated that meets the performance specification of 30 time units. We assume that the join order X->Z->Y is then generated in an access plan instep 470 ofFIG. 4 . The execution time for the new access plan is then determined instep 420. For a join order of X->Z->Y, there are 10 “X probes”, but for each X probe there is only one look into Z for a total of 20 time units, and Y is never touched. The 20 time units for the newly-generated access plan with a join order of X->Z->Y satisfies the performance specification of 30 time units (step 440=YES), so the new access plan is stored in the entry in the access plan cache corresponding to the query, as shown inFIG. 8 . This simple example demonstrates that the query optimizer is able to detect when an existing access plan for a query will violate the performance specification for the query, and can autonomically generate other access plans. If an access plan that satisfies the performance specification for the query is generated, it is stored as the access plan for the query in the access plan cache (step 450). If no access plan is generated that satisfies the performance specification for the query, the access plan with the best performance is stored as the access plan for the query in the access plan cache (step 480). - The performance specification for a query may be specified in any suitable units of measurement. Examples of some suitable units of measurement are shown in
FIGS. 8-12 by way of example. InFIG. 8 , the unit of measurement for the performance specification is “time units”, which are defined as probes to the database. The unit of measurement for the performance specification inFIG. 9 is an absolute time measurement in seconds, such as 100 ms. The unit of measurement for the performance specification inFIG. 10 is specified in processor cycles. The unit of measurement for the performance specification inFIG. 11 is specified in bus cycles. The unit of measurement for the performance specification inFIG. 12 is specified in disk I/Os.FIG. 13 presents an interesting case of a “sliding scale” where the value of the performance specification depends on the value of a target execution time for the query. The “target time” is abbreviated inFIG. 13 as TT. Thus, if the target time is less than 100 ms, the performance specification is 10 times the target time. If the target time is between 100 ms and 10 seconds, the performance specification is 3 times the target time. If the target time is between 10 seconds and eight hours, the performance specification is 2 times the target time. If the target time is over eight hours, the performance specification is 1.5 times the target time. In essence, the sliding scale shown inFIG. 13 allows specifying different performance specifications for a query depending on the target time for executing the query. -
FIG. 14 presents another interesting case of a performance specification that evolves as the database changes. The performance specification can be the arithmetic mean (or average) of the last N executions, where N is some suitable integer. If the query performance gradually degrades over time due to growth of the size of a table, for example, the performance specification can also gradually change to reflect the change in the database. Note that the examples inFIGS. 8-14 are merely examples, and are not limiting of the invention. The preferred embodiments expressly extend to any and all ways of specifying a performance specification, regardless of units of measurement or heuristic used. For example, certain thresholds could be set that specify that the execution time for a query was X % worse than the query performance specification. In the alternative, other metrics could be computed such as standard deviation of execution times that would cause the query optimizer to only generate new query implementations when something is really wrong (i.e., when the execution time for a query is outside one or two standard deviations of past execution times). - One skilled in the art will appreciate that many variations are possible within the scope of the present invention. Thus, while the invention has been particularly shown and described with reference to preferred embodiments thereof, it will be understood by those skilled in the art that these and other changes in form and details may be made therein without departing from the spirit and scope of the invention. For example, while the performance specification is shown herein to be a dedicated entry in the access plan cache for the query, a performance specification could be stored elsewhere. For example, a single algorithmic performance specification such as that shown in
FIG. 13 orFIG. 14 could be defined for the database manager that allows on-the-fly computation for all queries without storing values in each entry in the access plan cache.
Claims (3)
1. A method for optimizing a query, the method comprising the steps of:
(A) storing a performance specification for the query and an access plan for the query in an access plan cache, the access plan cache including a plurality of entries each entry including a performance specification for a corresponding query and an access plan for the corresponding query the stored performance specification specifying a desired maximum execution time for the query;
(B) determining time required to execute the query using an access plan stored in the access plan cache;
(C) comparing the time required to execute the query in step (B) with the stored performance specification for the query;
(D) generating a new access plan if the time required to execute the query using the access plan stored for the query exceeds the stored performance specification for the query;
(E) determining time for executing the new access plan;
(F) if a new access plan is generated in step (D) that has a time in step (E) that satisfies the performance specification for the query, storing the new access plan in an entry in the access plan cache that corresponds to the query and updating the performance specification for the query; and
(G) if a new access plan is not generated in step (D) that has a time determined in step (E) that satisfies the corresponding stored performance specification for the query, selecting a new access plan that had the best time in step (E), storing the new access plan in the entry in the access plan cache that corresponds to the query, and using the best time in step (E) to generate a new stored performance specification for the query.
2. The method of claim 1 wherein the performance specification comprises a heuristic expression.
3. A method for optimizing a query, the method comprising the steps of:
(A) storing a performance specification for the query and an access plan for the query in an access plan cache, the access plan cache including a plurality of entries, each entry including a performance specification for a corresponding query and an access plan for the corresponding query, the stored performance specification specifying a desired maximum bus cycles for the query that comprises an average of bus cycles over the last N executions of the query, where N is a predetermined positive integer;
(B) determining a number of bus cycles required to execute the query using an access plan stored in the access plan cache;
(C) comparing the number of bus cycles required to execute the query in step (B) with the stored performance specification for the query;
(D) generating a new access plan if the number of bus cycles required to execute the query using the access plan stored for the query exceeds the stored performance specification for the query;
(E) determining number of bus cycles for executing the new access plan;
(F) if a new access plan is generated in step (D) that has a number of bus cycles in step (E) that satisfies the performance specification for the query, storing the new access plan in an entry in the access plan cache that corresponds to the query and updating the performance specification corresponding to the query; and
(G) if a new access plan is not generated in step (D) that has a number of bus cycles determined in step (E) that satisfies the corresponding stored performance specification for the query, selecting a new access plan that had the best number of bus cycles in step (E), storing the new access plan in the entry in the access plan cache that corresponds to the query, and storing the best number of bus cycles in step (E) as a new stored performance specification corresponding to the query.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
US12/108,027 US20080215536A1 (en) | 2004-06-03 | 2008-04-23 | Autonomically generating a query implementation that meets a defined performance specification |
Applications Claiming Priority (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
US10/860,402 US8161037B2 (en) | 2004-06-03 | 2004-06-03 | Method for autonomically generating a query implementation that meets a defined performance specification |
US12/108,027 US20080215536A1 (en) | 2004-06-03 | 2008-04-23 | Autonomically generating a query implementation that meets a defined performance specification |
Related Parent Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
US10/860,402 Continuation US8161037B2 (en) | 2004-06-03 | 2004-06-03 | Method for autonomically generating a query implementation that meets a defined performance specification |
Publications (1)
Publication Number | Publication Date |
---|---|
US20080215536A1 true US20080215536A1 (en) | 2008-09-04 |
Family
ID=35515199
Family Applications (3)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
US10/860,402 Expired - Fee Related US8161037B2 (en) | 2004-06-03 | 2004-06-03 | Method for autonomically generating a query implementation that meets a defined performance specification |
US12/108,027 Abandoned US20080215536A1 (en) | 2004-06-03 | 2008-04-23 | Autonomically generating a query implementation that meets a defined performance specification |
US12/107,938 Expired - Fee Related US9135298B2 (en) | 2004-06-03 | 2008-04-23 | Autonomically generating a query implementation that meets a defined performance specification |
Family Applications Before (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
US10/860,402 Expired - Fee Related US8161037B2 (en) | 2004-06-03 | 2004-06-03 | Method for autonomically generating a query implementation that meets a defined performance specification |
Family Applications After (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
US12/107,938 Expired - Fee Related US9135298B2 (en) | 2004-06-03 | 2008-04-23 | Autonomically generating a query implementation that meets a defined performance specification |
Country Status (1)
Country | Link |
---|---|
US (3) | US8161037B2 (en) |
Cited By (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20080033907A1 (en) * | 2006-08-02 | 2008-02-07 | Johannes Woehler | Business object search using multi-join indexes and extended join indexes |
US20090106306A1 (en) * | 2007-10-17 | 2009-04-23 | Dinesh Das | SQL Execution Plan Baselines |
US8341178B2 (en) * | 2007-09-18 | 2012-12-25 | Oracle International Corporation | SQL performance analyzer |
US8903801B2 (en) * | 2007-09-14 | 2014-12-02 | Oracle International Corporation | Fully automated SQL tuning |
US9935812B1 (en) * | 2009-09-10 | 2018-04-03 | New Relic, Inc. | Performance evaluation of applications that access external resources |
US10621064B2 (en) | 2014-07-07 | 2020-04-14 | Oracle International Corporation | Proactive impact measurement of database changes on production systems |
US11327932B2 (en) | 2017-09-30 | 2022-05-10 | Oracle International Corporation | Autonomous multitenant database cloud service framework |
US11386058B2 (en) | 2017-09-29 | 2022-07-12 | Oracle International Corporation | Rule-based autonomous database cloud service framework |
Families Citing this family (19)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US8161037B2 (en) | 2004-06-03 | 2012-04-17 | International Business Machines Corporation | Method for autonomically generating a query implementation that meets a defined performance specification |
US8161038B2 (en) * | 2004-10-29 | 2012-04-17 | International Business Machines Corporation | Maintain optimal query performance by presenting differences between access plans |
US8032522B2 (en) * | 2006-08-25 | 2011-10-04 | Microsoft Corporation | Optimizing parameterized queries in a relational database management system |
US20080065590A1 (en) * | 2006-09-07 | 2008-03-13 | Microsoft Corporation | Lightweight query processing over in-memory data structures |
US7870123B2 (en) * | 2006-12-01 | 2011-01-11 | Teradata Us, Inc. | Database optimizer plan validation and characterizations |
US9087102B2 (en) * | 2007-10-09 | 2015-07-21 | International Business Machines Corporation | Adaptive query processing infrastructure |
US8645406B2 (en) * | 2008-04-11 | 2014-02-04 | Microsoft Corporation | Exploiting conditions to optimize expensive database queries |
US8312007B2 (en) * | 2008-05-08 | 2012-11-13 | International Business Machines Corporation | Generating database query plans |
US9189047B2 (en) | 2008-05-08 | 2015-11-17 | International Business Machines Corporation | Organizing databases for energy efficiency |
US8621482B1 (en) * | 2008-09-05 | 2013-12-31 | Teradata Us, Inc. | Deciding whether to cache a generic plan for executing a request based on a system performance metric |
US8892544B2 (en) * | 2009-04-01 | 2014-11-18 | Sybase, Inc. | Testing efficiency and stability of a database query engine |
US8818991B2 (en) | 2009-12-23 | 2014-08-26 | Pivotal Software, Inc. | Apparatus and method for analyzing query optimizer performance |
US8914353B2 (en) * | 2011-12-20 | 2014-12-16 | Sap Se | Many-core algorithms for in-memory column store databases |
US9727609B2 (en) * | 2012-09-28 | 2017-08-08 | Oracle International Corporation | Triggering hard parses |
US8812489B2 (en) * | 2012-10-08 | 2014-08-19 | International Business Machines Corporation | Swapping expected and candidate affinities in a query plan cache |
US9292568B2 (en) * | 2012-10-10 | 2016-03-22 | Dell Products L.P. | Method and system for dynamically optimizing client queries to read-mostly servers |
US11748350B2 (en) * | 2020-02-21 | 2023-09-05 | Microsoft Technology Licensing, Llc | System and method for machine learning for system deployments without performance regressions |
US20220300513A1 (en) * | 2021-03-19 | 2022-09-22 | International Business Machines Corporation | Asynchronous query optimization using spare hosts |
US11941029B2 (en) | 2022-02-03 | 2024-03-26 | Bank Of America Corporation | Automatic extension of database partitions |
Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US5794229A (en) * | 1993-04-16 | 1998-08-11 | Sybase, Inc. | Database system with methodology for storing a database table by vertically partitioning all columns of the table |
US5819255A (en) * | 1996-08-23 | 1998-10-06 | Tandem Computers, Inc. | System and method for database query optimization |
US6353818B1 (en) * | 1998-08-19 | 2002-03-05 | Ncr Corporation | Plan-per-tuple optimizing of database queries with user-defined functions |
US20020198867A1 (en) * | 2001-06-06 | 2002-12-26 | International Business Machines Corporation | Learning from empirical results in query optimization |
US20030182276A1 (en) * | 2002-03-19 | 2003-09-25 | International Business Machines Corporation | Method, system, and program for performance tuning a database query |
US20030212668A1 (en) * | 2002-05-13 | 2003-11-13 | Hinshaw Foster D. | Optimized database appliance |
US20040210579A1 (en) * | 2003-04-17 | 2004-10-21 | International Business Machines Corporation | Rule application management in an abstract database |
Family Cites Families (21)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US3530284A (en) * | 1968-03-25 | 1970-09-22 | Sperry Rand Corp | Shift counter having false mode suppression |
NL8800390A (en) * | 1988-02-17 | 1989-09-18 | Philips Nv | COUNTER CIRCUIT WITH ERROR DETECTION, AND A CIRCUIT CONTAINING SUCH A COUNTER CIRCUIT. |
US5960428A (en) * | 1997-08-28 | 1999-09-28 | International Business Machines Corporation | Star/join query optimization |
US6026391A (en) * | 1997-10-31 | 2000-02-15 | Oracle Corporation | Systems and methods for estimating query response times in a computer system |
US6366901B1 (en) * | 1998-12-16 | 2002-04-02 | Microsoft Corporation | Automatic database statistics maintenance and plan regeneration |
US6360214B1 (en) * | 1998-12-16 | 2002-03-19 | Microsoft Corporation | Automatic database statistics creation |
US6321218B1 (en) * | 1999-02-24 | 2001-11-20 | Oracle Corporation | Automatically determining data that is best suited for index tuning |
US6466931B1 (en) * | 1999-07-30 | 2002-10-15 | International Business Machines Corporation | Method and system for transparently caching and reusing query execution plans efficiently |
US6615222B2 (en) * | 1999-09-22 | 2003-09-02 | International Business Machines Corporation | System and process for evaluating the performance of a database system |
JP2002246895A (en) * | 2001-02-16 | 2002-08-30 | Mitsubishi Electric Corp | Counter circuit |
US7007009B2 (en) * | 2001-03-15 | 2006-02-28 | International Business Machines Corporation | Representation for data used in query optimization |
US7499907B2 (en) * | 2001-10-12 | 2009-03-03 | Teradata Us, Inc. | Index selection in a database system |
US8140568B2 (en) * | 2001-12-13 | 2012-03-20 | International Business Machines Corporation | Estimation and use of access plan statistics |
CA2382714A1 (en) * | 2002-04-19 | 2003-10-19 | Ibm Canada Limited-Ibm Canada Limitee | Substituting parameter markers for literals in a database query language statement to promote reuse of previously generated access plans |
US7099858B2 (en) * | 2003-01-30 | 2006-08-29 | International Business Machines Corporation | Data management system that provides intelligent access plan caching |
US7031958B2 (en) * | 2003-02-06 | 2006-04-18 | International Business Machines Corporation | Patterned based query optimization |
US20050065928A1 (en) * | 2003-05-02 | 2005-03-24 | Kurt Mortensen | Content performance assessment optimization for search listings in wide area network searches |
US7213012B2 (en) * | 2003-05-09 | 2007-05-01 | Oracle International Corporation | Optimizer dynamic sampling |
US8161037B2 (en) | 2004-06-03 | 2012-04-17 | International Business Machines Corporation | Method for autonomically generating a query implementation that meets a defined performance specification |
US8346761B2 (en) * | 2004-08-05 | 2013-01-01 | International Business Machines Corporation | Method and system for data mining for automatic query optimization |
US20060085375A1 (en) * | 2004-10-14 | 2006-04-20 | International Business Machines Corporation | Method and system for access plan sampling |
-
2004
- 2004-06-03 US US10/860,402 patent/US8161037B2/en not_active Expired - Fee Related
-
2008
- 2008-04-23 US US12/108,027 patent/US20080215536A1/en not_active Abandoned
- 2008-04-23 US US12/107,938 patent/US9135298B2/en not_active Expired - Fee Related
Patent Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US5794229A (en) * | 1993-04-16 | 1998-08-11 | Sybase, Inc. | Database system with methodology for storing a database table by vertically partitioning all columns of the table |
US5819255A (en) * | 1996-08-23 | 1998-10-06 | Tandem Computers, Inc. | System and method for database query optimization |
US6353818B1 (en) * | 1998-08-19 | 2002-03-05 | Ncr Corporation | Plan-per-tuple optimizing of database queries with user-defined functions |
US20020198867A1 (en) * | 2001-06-06 | 2002-12-26 | International Business Machines Corporation | Learning from empirical results in query optimization |
US20030182276A1 (en) * | 2002-03-19 | 2003-09-25 | International Business Machines Corporation | Method, system, and program for performance tuning a database query |
US20030212668A1 (en) * | 2002-05-13 | 2003-11-13 | Hinshaw Foster D. | Optimized database appliance |
US20040210579A1 (en) * | 2003-04-17 | 2004-10-21 | International Business Machines Corporation | Rule application management in an abstract database |
Cited By (17)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20080033907A1 (en) * | 2006-08-02 | 2008-02-07 | Johannes Woehler | Business object search using multi-join indexes and extended join indexes |
US9734200B2 (en) | 2007-09-14 | 2017-08-15 | Oracle International Corporation | Identifying high risk database statements in changing database environments |
US9720941B2 (en) | 2007-09-14 | 2017-08-01 | Oracle International Corporation | Fully automated SQL tuning |
US8903801B2 (en) * | 2007-09-14 | 2014-12-02 | Oracle International Corporation | Fully automated SQL tuning |
US8341178B2 (en) * | 2007-09-18 | 2012-12-25 | Oracle International Corporation | SQL performance analyzer |
US8335767B2 (en) | 2007-10-17 | 2012-12-18 | Oracle International Corporation | Maintaining and utilizing SQL execution plan histories |
US8600977B2 (en) | 2007-10-17 | 2013-12-03 | Oracle International Corporation | Automatic recognition and capture of SQL execution plans |
US8700608B2 (en) | 2007-10-17 | 2014-04-15 | Oracle International Corporation | SQL execution plan verification |
US20090106219A1 (en) * | 2007-10-17 | 2009-04-23 | Peter Belknap | SQL Execution Plan Verification |
US9189522B2 (en) | 2007-10-17 | 2015-11-17 | Oracle International Corporation | SQL execution plan baselines |
US20090106321A1 (en) * | 2007-10-17 | 2009-04-23 | Dinesh Das | Maintaining and Utilizing SQL Execution Plan Histories |
US20090106306A1 (en) * | 2007-10-17 | 2009-04-23 | Dinesh Das | SQL Execution Plan Baselines |
US10229158B2 (en) | 2007-10-17 | 2019-03-12 | Oracle International Corporation | SQL execution plan verification |
US9935812B1 (en) * | 2009-09-10 | 2018-04-03 | New Relic, Inc. | Performance evaluation of applications that access external resources |
US10621064B2 (en) | 2014-07-07 | 2020-04-14 | Oracle International Corporation | Proactive impact measurement of database changes on production systems |
US11386058B2 (en) | 2017-09-29 | 2022-07-12 | Oracle International Corporation | Rule-based autonomous database cloud service framework |
US11327932B2 (en) | 2017-09-30 | 2022-05-10 | Oracle International Corporation | Autonomous multitenant database cloud service framework |
Also Published As
Publication number | Publication date |
---|---|
US20080215535A1 (en) | 2008-09-04 |
US8161037B2 (en) | 2012-04-17 |
US20060004695A1 (en) | 2006-01-05 |
US9135298B2 (en) | 2015-09-15 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US9135298B2 (en) | Autonomically generating a query implementation that meets a defined performance specification | |
US7392266B2 (en) | Apparatus and method for monitoring usage of components in a database index | |
US7343367B2 (en) | Optimizing a database query that returns a predetermined number of rows using a generated optimized access plan | |
US8386463B2 (en) | Method and apparatus for dynamically associating different query execution strategies with selective portions of a database table | |
US7987200B2 (en) | Method and apparatus for predicting selectivity of database query join conditions using hypothetical query predicates having skewed value constants | |
US7457797B2 (en) | Method and apparatus for associating logical conditions with the re-use of a database query execution strategy | |
US7203685B2 (en) | Apparatus and method for estimating cardinality when data skew is present | |
US10599692B2 (en) | Modification of a saved database query based on a change in the meaning of a query value over time | |
US7877377B2 (en) | Dropping tautological predicates from SQL queries for reusability | |
US7213014B2 (en) | Apparatus and method for using a predefined database operation as a data source for a different database operation | |
US20060173852A1 (en) | Apparatus and method for highlighting discrepancies between query performance estimates and actual query performance | |
US8838573B2 (en) | Autonomic index creation | |
US20230153286A1 (en) | Method and system for hybrid query based on cloud analysis scene, and storage medium | |
US7313553B2 (en) | Apparatus and method for using values from a frequent values list to bridge additional keys in a database index | |
US7136848B2 (en) | Apparatus and method for refreshing a database query | |
US20080215539A1 (en) | Data ordering for derived columns in a database system | |
US20060235819A1 (en) | Apparatus and method for reducing data returned for a database query using select list processing | |
US7925642B2 (en) | Apparatus and method for reducing size of intermediate results by analyzing having clause information during SQL processing |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
STCB | Information on status: application discontinuation |
Free format text: ABANDONED -- FAILURE TO RESPOND TO AN OFFICE ACTION |