×

SQL execution plan verification

  • US 8,700,608 B2
  • Filed: 08/08/2008
  • Issued: 04/15/2014
  • Est. Priority Date: 10/17/2007
  • Status: Active Grant
First Claim
Patent Images

1. A method comprising:

  • maintaining, at a database server, plan verification data that identifies one or more query execution plans that have been designated as acceptable for use by the database server to execute a database commands, the database command being a query statement that instructs the database server to perform one or more operations on data stored in a database;

    receiving, at the database server, a first request to execute a database command;

    at the database server, identifying a plurality of alternative query execution plans for executing the database command in response to the first request, the plurality of alternative query execution plans including at least a first query execution plan and a second query execution plan that is different than the first query execution plan;

    the database server selecting, from the plurality of alternative query execution plans identified by the database server, a query execution plan to execute the database command in response to the first request, wherein the database server selects the second query execution plan based at least in part on determining;

    a) that the plan verification data indicates that the second query execution plan has been designated as acceptable for executing the database command, and b) that the plan verification data does not yet indicate that the first query execution plan has been designated as acceptable for executing the database command;

    subsequent to responding to the first request, the database server testing actual performance of the first query execution plan by executing the first query execution plan to determine actual performance statistics for the first query execution plan;

    based at least on the determined actual performance statistics, the database server determining to update the plan verification data to designate the first query execution plan as acceptable for executing the database command;

    subsequent to updating the plan verification data to indicate that the first query execution plan has been verified, the database server receiving a second request to execute the same database command;

    at the database server, identifying the plurality of alternative query execution plans for executing the database command in response to the second request; and

    based at least in part on determining that the updated verification data indicates that the first query execution plan has been verified, the database server selecting the first query execution plan to execute the database command in response to the second request;

    wherein the method is performed by one or more computing devices.

View all claims
  • 1 Assignment
Timeline View
Assignment View
    ×
    ×