US7933935B2

Efficient partitioning technique while managing large XML documents

Summary by NHIP

Streaming XML Partitioning

The method loads XML documents into database partitions by reading only required portions into a buffer before storing the remainder. It detects partition key information within specific read portions to select a partition without loading the entire document into temporary memory.

Claim Score by NHIP

Read claim 1, the broadest

Abstract

A method is provided to efficiently evaluate an expression to determine the partition key for an XML document stored in a database without the entire XML document first being stored in temporary memory storage. The partition key is determined using streaming evaluation or incrementally using a DOM node tree as a portion of the document is read and stored in the buffer. The XML document is stored in the partition using the read portion of the document stored in the buffer and the remaining portion from the original source.

US7933935B2, drawing sheet 1
Sheet 1 of 4

Term

1 yearleft in the term

Expires 10 September 2027, including 186 days of term adjustment.

  1. Priority
  2. Filed
  3. Granted
  4. Today
  5. Expires

16 claims: 2 independent, 14 dependent

  1. 1
    Broadest claimClaim Score 20, narrow(NHIP)A method for loading an XML document into a selected database table partition of a partitioned database table without reading the entire XML document into a buffer, wherein selection of the database table partition requires partition key information from the XML document, the method comprising:beginning reading, from a source into the buffer, an XML document;after reading into said buffer one or more portions of the XML document that include the required partition key information for the selection of the database table partition of the partitioned database table and without reading into said buffer one or more other portions of the XML document that include other information that is not required for selection of the database table partition, performing: detecting that the one or more portions include the required partition key information for the selection of the database table partition of the partitioned database table, wherein the partitioned database table is divided into multiple partitions and stores a collection of XML documents, wherein each XML document of said collection is stored in a single partition selected for said each XML document based on information in said each XML document;in response to detecting that the one or more portions include the required partition key information for the selection of the database table partition: based at least in part on the required partition key information from said portion of said XML document, selecting the database table partition of the partitioned database table to store the XML document;and storing a read part of the XML document stored in the buffer to the selected database table partition, wherein the read part of the XML document includes the one or more portions;after storing the read part of the XML document to the selected database table partition, reading and storing a remainder of the XML document from the source to the selected database table partition, wherein the remainder includes the one or more other portions of the XML document that include the other information that is not required for selection of the database table partition, wherein the method is performed by one or more computing devices.
  2. 9
    A non-transitory machine-readable storage medium storing one or more sequences of instructions which, when executed by one or more processors, causes the one or more processors to perform loading an XML document into a selected database table partition of a partitioned database table without reading the entire XML document into a buffer, wherein selection of the database table partition requires particular information from the XML document, wherein the one or more sequences of instructions cause the one or more processors perform the loading by causing the one or more processors to perform:beginning reading, from a source into the buffer, an XML document;after reading into said buffer one or more portions of the XML document that include the required partition key information for the selection of the database table partition of the partitioned database table and without reading into said buffer one or more other portions of the XML document that include other information that is not required for selection of the database table partition, performing: detecting that the one or more portions include the required partition key information for the selection of the database table partition of the partitioned database table, wherein the partitioned database table is divided into multiple partitions and stores a collection of XML documents, wherein each XML document of said collection is stored in a single partition selected for said each XML document based on information in said each XML document;in response to detecting that the one or more portions include the required partition key information for the selection of the database table partition: based at least in part on the required partition key information from said certain portion of said XML document, selecting the database table partition of the partitioned database table to store the XML document;and storing a read part of the XML document stored in the buffer to the selected database table partition, wherein the read part of the XML document includes the one or more portions;after storing the read part of the XML document to the selected database table partition, reading and storing a remainder of the XML document from the source to the selected database table partition, wherein the remainder includes the one or more other portions of the XML document that include the other information that is not required for selection of the database table partition.