IP Library Granted Patent US 8,694,524
Granted Patent B1
US 8,694,524 · App. 11/510,930 · Granted Apr 8, 2014

Parsing a query

View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 8,694,524
App. No.
11/510,930
Granted
Apr 8, 2014
Kind
B1
Abstract

In a database system, a mechanism is provided to enable parsing of a query into plural objects stored in respective plural tables. One or more characteristics of the query is modified using content of the plural tables based on one or more predefined rules for the purpose of recomposing the query.

Claims (40)

1. A method for use in a database system, comprising:

parsing, by at least one processor, a received query into plural objects stored in respective plural tables;

modifying, by the at least one processor, one or more characteristics of the received query based on content of the plural tables according to one or more predefined rules; and

recomposing, by the at least one processor, a modified query having the modified one or more characteristics.

2. The method of claim 1 , wherein modifying the one or more characteristics comprises modifying one or more predicates in the received query.

3. The method of claim 2 , wherein modifying the one or more predicates according to the one or more predefined rules comprises modifying the one or more predicates according to a rule to remove redundant predicates.

4. The method of claim 2 , wherein modifying the one or more predicates according to the one or more predefined rules comprises modifying the one or more predicates according to a transitive property rule.

5. The method of claim 1 , wherein modifying the one or more characteristics comprises modifying an expression of the received query according to a′ distributive property rule.

6. The method of claim 1 , further comprising:

identifying invariants in the received query;

indicating boundaries of subqueries in the received query based on the invariants.

7. The method of claim 6 , wherein modifying the one or more characteristics of the received query is in response to user input based on the indicated boundaries of subqueries.

8. The method of claim 6 , further comprising displaying the indicated boundaries of subqueries by using color.

9. The method of claim 1 , wherein modifying the one or more characteristics comprises modifying at least one of the tables.

10. The method of claim 9 , wherein recomposing the modified query is based on the modified at least one table.

11. The method of claim 1 , wherein the parsing, modifying, and recomposing are performed by a parsing engine in the database system.

12. The method of claim 1 , further comprising identifying nesting of subqueries in the received query.

13. The method of claim 12 , further comprising displaying the nested subqueries.

14. An article comprising at least one machine-readable storage medium containing instructions that when executed cause a system to:

parse a received query into plural objects stored in respective plural tables;

modify one or more characteristics of the received query based on content of the plural tables according to one or more predefined rules; and

recompose a modified query having the modified one or more characteristics.

15. The article of claim 14 , wherein modifying the one or more characteristics comprises modifying one or more predicates in the received query.

16. The article of claim 15 , wherein modifying the one or more predicates according to the one or more predefined rules comprises modifying the one or more predicates according to a rule to remove redundant predicates.

17. The article of claim 14 , wherein modifying the one or more characteristics comprises modifying an expression of the received query according to a distributive property rule.

18. The article of claim 14 , wherein modifying the one or more characteristics comprises modifying at least one of the tables.

19. The article of claim 18 , wherein recomposing the modified query is based on the modified at least one table.

20. A database system comprising:

a processor;

a parser executable on the processor to receive a query and to decompose the received query into plural classes of objects;

a modifier executable on the processor to modify at least one characteristic of the received query based on content of the plural classes of objects; and

a composer executable on the processor to recompose a modified query according to the modified at least one characteristic.

21. The database system of claim 20 , further comprising a storage to store plural tables corresponding to the plural classes of objects, wherein information of the decomposed received query is stored in the plural tables,

wherein the modifier is configured to modify at least one of the tables to modify the at least one characteristic, and

wherein the composer recomposes the modified query using the modified at least one table.

22. The method of claim 1 , further comprising outputting the modified query for viewing by a user.

23. The method of claim 1 , wherein parsing the received query comprises parsing a received SQL query, and modifying the one or more characteristics of the received query comprises modifying the one or more characteristics of the received SQL query.

24. The article of claim 14 , wherein the instructions when executed cause the system to output the modified query for viewing by a user.

25. The article of claim 14 , wherein parsing the received query comprises parsing a received SQL query, and modifying the one or more characteristics of the received query comprises modifying the one or more characteristics of the received SQL query.

26. The article of claim 20 , wherein the received query comprises a received SQL query, and the modified query comprises a modified SQL query.

Assignments (2)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Mar 18, 2008
From: NCR CORPORATION
To: TERADATA US, INC.
Reel/Frame 020666/0438 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Aug 28, 2006
From: PHAM, SON; PHAM, THU K.
To: NCR CORPORATION
Reel/Frame 018255/0049 →