发明授权
- 专利标题: Techniques of optimizing queries using NULL expression analysis
- 专利标题(中): 使用NULL表达式分析优化查询的技术
-
申请号: US11517969申请日: 2006-09-08
-
公开(公告)号: US07739219B2公开(公告)日: 2010-06-15
- 发明人: Zhen Hua Liu , Muralidhar Krishnaprasad , Hui Joe Chang , Anand Manikutty , James W. Warner , Vikas Arora , Susan Kotsovolos
- 申请人: Zhen Hua Liu , Muralidhar Krishnaprasad , Hui Joe Chang , Anand Manikutty , James W. Warner , Vikas Arora , Susan Kotsovolos
- 申请人地址: US CA Redwood Shores
- 专利权人: Oracle International Corporation
- 当前专利权人: Oracle International Corporation
- 当前专利权人地址: US CA Redwood Shores
- 代理机构: Hickman Palermo Truong & Becker LLP
- 主分类号: G06F17/30
- IPC分类号: G06F17/30
摘要:
A method for optimizing queries is described. A query, which includes a first expression for determining whether each of a set of values evaluates to NULL or NOT NULL, is received. At compile-time, a first representation of the query is generated, where the first representation indicates that the query is to be performed based on the first expression. Based on the first expression, a second expression is determined. The second expression is such that the first expression would evaluate to any NOT NULL value if and only if the second expression would evaluate to any NOT NULL value. The second expression, when evaluated, is much more computationally efficient compared with the evaluation of the first expression. Based on the first representation, a second representation of the query is generated, where the second representation indicates that the query is to be performed based on the second expression. Thereafter, the query is executed based on the second representation.