首页> 外国专利> Substituting parameter markers for literals in database query language statement to promote reuse of previously generated access plans

Substituting parameter markers for literals in database query language statement to promote reuse of previously generated access plans

机译:将参数标记替换为数据库查询语言语句中的文字,以促进重用先前生成的访问计划

摘要

A method, computer program product and computing device for promoting reuse of previously generated access plans are disclosed. SQL statements containing literals are amended so as to substitute a parameter marker for each literal. Amended statements are provided to the DBMS along with parameters including the substituted literals and a substitution indicator indicating that the substitution has been performed. The DBMS assesses the soundness of the substitutions that are performed. Soundness may be measured in terms of the semantic correctness of the amended statement and the likelihood that the literal substitution will improve DBMS efficiency. If a substitution is unsound, the DBMS may obtain and optimize the original version of the amended SQL statement. Otherwise, the amended statement is optimized. Advantageously, SQL statements originally differing only in the value of one or more literals may become functionally equivalent, and the reuse of cached, previously generated access plans is thus promoted.
机译:公开了一种用于促进对先前生成的访问计划的重用的方法,计算机程序产品和计算设备。修改包含文字的SQL语句,以便为每个文字替换参数标记。修改后的语句与参数一起提供给DBMS,包括替换文字和表示替换已执行的替换指示符。 DBMS评估执行的替换的正确性。可以根据修改后的语句的语义正确性以及字面替换将提高DBMS效率的可能性来衡量健全性。如果替换不正确,则DBMS可以获得并优化修改后的SQL语句的原始版本。否则,修改后的语句将被优化。有利地,原本仅在一个或多个文字的值上不同的SQL语句可以在功能上等效,并且因此促进了对缓存的先前生成的访问计划的重用。

著录项

相似文献

  • 专利
  • 外文文献
  • 中文文献
获取专利

客服邮箱:kefu@zhangqiaokeyan.com

京公网安备:11010802029741号 ICP备案号:京ICP备15016152号-6 六维联合信息科技 (北京) 有限公司©版权所有
  • 客服微信

  • 服务号