发明授权
- 专利标题: Handling null values in SQL queries over object-oriented data
- 专利标题(中): 在面向对象数据的SQL查询中处理空值
-
申请号: US835113申请日: 1997-04-04
-
公开(公告)号: US5905982A公开(公告)日: 1999-05-18
- 发明人: Michael James Carey , Gerald George Kiernan
- 申请人: Michael James Carey , Gerald George Kiernan
- 申请人地址: NY Armonk
- 专利权人: International Business Machines Corporation
- 当前专利权人: International Business Machines Corporation
- 当前专利权人地址: NY Armonk
- 主分类号: G06F17/30
- IPC分类号: G06F17/30
摘要:
A method, apparatus, and article of manufacture for handling NULL values in SQL queries over object oriented data. A two-phase method is used to enable a query evaluator in a two-valued logic environment to properly handle occurrences of NULL values for predicates that involve subqueries, i.e., basic subquery predicates and/or quantified subquery predicates. For basic subquery predicates, negation reduction is performed by applying logical equivalence rules and inverting basic comparators (e.g., transforming =) to eliminate NOTs. Then, transformations are employed for the resulting positive predicates to include NULL value testing, i.e., NULL protection. For quantified subquery predicates, in addition to performing negation reduction, quantified subqueries are converted into existential subqueries. In most cases, this yields a predicate that can be handled using NULL protection transformations for positive predicates. The exception (i.e., a "NOT EXISTS" resulting from the conversion step of a universally quantified subquery) is handled using NULL protection transformations for negative predicates. The evaluation of the NULL tested positive and negative predicates ensures that if a predicate has a NULL value, it is not included in the query result.
公开/授权文献
信息查询