Method and system for performing query optimization using a hybrid execution plan
    51.
    发明授权
    Method and system for performing query optimization using a hybrid execution plan 有权
    使用混合执行计划执行查询优化的方法和系统

    公开(公告)号:US08903805B2

    公开(公告)日:2014-12-02

    申请号:US12860294

    申请日:2010-08-20

    IPC分类号: G06F17/30

    CPC分类号: G06F17/30469

    摘要: An improved method, system, and computer program product is disclosed that provides a hybrid approach to optimization which allows different subsets of data accessed by a query to be optimized with different access paths and execution approaches. Transformations may be performed to re-write the query, which restructures the query in a way that facilitates the hybrid optimization process. Multiple transformations may be interleaved to produce an efficient re-written query.

    摘要翻译: 公开了一种改进的方法,系统和计算机程序产品,其提供了优化的混合方法,其允许通过不同的访问路径和执行方法来优化由查询访问的不同的数据子集。 可以执行转换以重新编写查询,其以促进混合优化过程的方式重新构建查询。 可以交织多个变换以产生有效的重写查询。

    Executing alternative plans for a SQL statement
    52.
    发明授权
    Executing alternative plans for a SQL statement 有权
    执行SQL语句的替代计划

    公开(公告)号:US07877373B2

    公开(公告)日:2011-01-25

    申请号:US11484108

    申请日:2006-07-10

    申请人: Mohamed Zait

    发明人: Mohamed Zait

    IPC分类号: G06F7/00 G06F17/00

    CPC分类号: G06F17/30463

    摘要: Under automated alternate plan analysis, a query optimizer generates candidate execution plans. The candidate execution plans are selected as alternate execution plans for the query and execution. Output describing characteristics of each alternate execution plan and/or its execution is generated and/or compared. From this information, it may be determined, for example, whether results returned by any of the alternate execution plans are the same and whether the least cost execution plan is actually the most efficiently executed.

    摘要翻译: 在自动替代计划分析下,查询优化器生成候选执行计划。 选择候选执行计划作为查询和执行的备用执行计划。 生成和/或比较描述每个替代执行计划的特征的输出和/或其执行。 根据该信息,可以例如确定任何替代执行计划返回的结果是否相同以及最低成本执行计划是否实际上是最有效地执行的。

    COMPUTING SELECTIVITIES FOR GROUP OF COLUMNS AND EXPRESSIONS
    53.
    发明申请
    COMPUTING SELECTIVITIES FOR GROUP OF COLUMNS AND EXPRESSIONS 审中-公开
    用于组和表达组的计算选择

    公开(公告)号:US20100030728A1

    公开(公告)日:2010-02-04

    申请号:US12181994

    申请日:2008-07-29

    IPC分类号: G06F17/30

    CPC分类号: G06F16/24545

    摘要: Techniques are described herein for estimating selectivities of query predicates that reference more than one column and predicates that include column expressions. Virtual columns are defined based on column groups and column expressions. Statistics are gathered on the virtual columns and are used to estimate the selectivities of query predicates that include column groups or expressions. Query predicates that include column groups are mapped to virtual columns on which statistics are gathered, based on similarities between the column groups in the query predicates and the column groups on which the virtual columns are defined. Virtual columns are defined for column groups and expressions are specified by users or a workload analyzer that analyzes query predicates.

    摘要翻译: 这里描述了用于估计引用多于一个列的查询谓词的选择性以及包括列表达式的谓词的技术。 虚拟列是基于列组和列表达式定义的。 在虚拟列上收集统计信息,并用于估计包含列组或表达式的查询谓词的选择性。 根据查询谓词中的列组与定义了虚拟列的列组之间的相似性,将列组映射到收集统计信息的虚拟列的查询谓词。 为列组定义虚拟列,表达式由用户或分析查询谓词的工作负载分析器指定。

    SQL Execution Plan Baselines
    54.
    发明申请
    SQL Execution Plan Baselines 有权
    SQL执行计划基准

    公开(公告)号:US20090106306A1

    公开(公告)日:2009-04-23

    申请号:US12188678

    申请日:2008-08-08

    IPC分类号: G06F17/30

    CPC分类号: G06F17/30469 G06F17/30463

    摘要: Approaches, techniques, and mechanisms are disclosed for maintaining a set of baseline query plans for a database command. Except in rare circumstances, a database server may only execute a command according to a baseline plan, even if the database server predicts that a different plan has a lower cost. The set of baseline plans are plans that, for one reason or another, have been determined to provide acceptable actual performance in at least one execution context. When the database server receives a request to execute a particular command, the database server, if possible, always executes the command according to the lowest predicted cost baseline plan. The database server may evolve the plan baseline to include additional plans by generating and testing new plans in response to new requests to execute the database command, or as part of a query optimization or tuning process.

    摘要翻译: 披露了用于维护数据库命令的一组基线查询计划的方法,技术和机制。 除极少数情况下,数据库服务器只能根据基准线执行命令,即使数据库服务器预测不同的计划成本较低。 一组基准计划是由于某种原因决定在至少一个执行环境中提供可接受的实际绩效的计划。 当数据库服务器接收到执行特定命令的请求时,如果可能,数据库服务器总是根据最低预测成本基线计划执行该命令。 数据库服务器可以通过生成和测试新计划以响应执行数据库命令的新请求,或作为查询优化或调整过程的一部分,来演进计划基准以包括额外的计划。

    ADAPTIVE CURSOR SHARING
    55.
    发明申请
    ADAPTIVE CURSOR SHARING 有权
    自适应光标共享

    公开(公告)号:US20090037405A1

    公开(公告)日:2009-02-05

    申请号:US11831952

    申请日:2007-07-31

    IPC分类号: G06F7/04

    摘要: Techniques for sharing cursors are provided. When a new query is issued, a database server determines whether the new query is semantically equivalent to a previous query. If so, then database server computes statistics associated with the new query. Based on the statistics, the database server determines whether compiling the new query would produce an execution plan that satisfies certain criteria. If so, then the cursor is used to execute the new query. In another approach, one cursor sharing technique (CST) is used to determine which cursor to use to execute a first set of semantically-equivalent queries. Statistics are gathered during execution of the first set of queries. The database server determines, based on the statistics, when to switch from using the first CST to a different CST. The different CST is used to determine which cursor to use to execute a second set of queries that are semantically-equivalent to the first set.

    摘要翻译: 提供了共享光标的技术。 当发出新的查询时,数据库服务器确定新查询在语义上等同于先前的查询。 如果是这样,则数据库服务器计算与新查询关联的统计信息。 基于统计信息,数据库服务器确定是否编译新查询将生成满足特定条件的执行计划。 如果是这样,那么游标用于执行新的查询。 在另一种方法中,使用一个游标共享技术(CST)来确定用于执行第一组语义等效查询的游标。 在第一组查询执行期间收集统计信息。 数据库服务器根据统计信息确定何时从使用第一个CST切换到另一个CST。 不同的CST用于确定哪个游标用于执行第二组查询语义上等同于第一组查询。