Patent ID: 8200660

Claim:
A computer-implemented method of executing a query plan against a database, comprising: accessing a first subset of rows of a database table using a direct access method, wherein the query plan comprises the direct access method; determining a processing cost of accessing the first subset of rows; modifying the direct access method in response to determining that the processing cost exceeds a specified threshold; and accessing a second subset of rows of the database table using the modified direct access method, wherein the direct access method comprises identifying one or more rows of the first subset, using a first number of columns of an index of the database table, and wherein the index is represented by a balanced tree, wherein the balanced tree comprises index blocks representing the first number of columns of the index, and wherein the modified direct access method comprises identifying one or more rows of the second subset using a second number of columns of the index, wherein a difference between the first number of columns and the second number of columns is one.