IP Library › Granted Patent US 7,392,239
Granted Patent B2
US 7,392,239 · App. 10/413,244 · Granted Jun 24, 2008

System and method for querying XML streams

Assignee: International Business Machines Corporation
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 7,392,239
App. No.
10/413,244
Granted
Jun 24, 2008
Kind
B2
Abstract

A system and method for querying a stream of XML data in a single pass using standard XQuery expressions. The system comprises: an expression parser that receives a query and generates a parse tree; a SAX events API that receives the stream of XML data and generates a stream of SAX events; an evaluator that receives the parse tree and stream of SAX events and buffers fragments from the stream of SAX events that meet an evaluation criteria; and a tuple constructor that joins fragments to form a set of tuple results that satisfies the query for the stream of XML data.

Claims (23)

1. A method of querying a stream of mark-up language data, comprising:

receiving a query comprising a plurality of variables and generating a parse tree;

receiving the stream of mark-up language data and generating a stream of events;

evaluating the parse tree and stream of events, and buffering fragments from the stream of events that meet an evaluation criteria, each fragment corresponding to one of the plurality of variables;

joining fragments to form a set of tuple results that satisfies the query for the stream of mark-up language data, each tuple result including a fragment for each of the plurality of variables; and

storing the set of tuple results in a tangible recordable medium.

2. The method of claim 1 , wherein the parse tree includes:

a set of nodes corresponding to node tests in the query; and

edges corresponding to relationships between node tests in the query.

3. The method of claim 2 , wherein at least one of the nodes comprises an output node corresponding to a bound-out variable from the query.

4. The method of claim 2 , wherein at least one of the nodes comprises a set of predicate parse trees.

5. The method of claim 2 , wherein the evaluating step includes the step of generating a work array for storing evaluation data for the stream of events, wherein the evaluation data tracks matches between nodes and events.

6. The method of claim 5 , wherein the evaluating step includes the step of generating a set of output buffers to store fragments that meet the evaluation criteria.

7. The method of claim 5 , wherein the evaluating step includes:

generating a set of predicate buffers to store the content of nodes participating in predicate expressions; and

evaluating predicate expressions.

8. The method of claim 1 , wherein the step of joining fragments includes the steps of:

providing a buffer queue for each bound-out variable specified in the query; and

identifying correct tuples by processing a cross-product of the buffer queues.

9. The method of claim 1 , comprising the further steps of:

identifying buffers that can be deleted; and

deleting identified buffers.

10. The method of claim 1 , wherein the mark-up language data comprises XML.

Assignments (3)
CHANGE OF NAME Recorded Oct 2, 2017
From: GOOGLE INC.
To: GOOGLE LLC
Reel/Frame 044101/0610 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Sep 13, 2011
From: INTERNATIONAL BUSINESS MACHINES CORPORATION
To: GOOGLE INC.
Reel/Frame 026894/0001 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Apr 14, 2003
From: FONTOURA, MARCUS F.; JOSIFOVSKI, VANJA
To: INTERNATIONAL BUSINESS MACHINES CORPORATION
Reel/Frame 013982/0453 →
Continuity (1)
Related Publication 20040205082A1 · Oct 14, 2004