Query optimization method for converting XPath (XML path language) query into tree-form data structure

A data structure and query optimization technology, applied in the fields of XML query optimization and query optimization, can solve the problem that the twig mode query method involves little, and achieve the effect of speeding up the evaluation

Active Publication Date: 2013-07-10
TONGFANG KNOWLEDGE NETWORK TECH CO LTD (BEIJING)
View PDF3 Cites 4 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0003] At present, there are many methods for query processing of twig patterns, each of which has its internal representation of twig patterns, but few methods for query processing of twig patterns with positional predicates

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Query optimization method for converting XPath (XML path language) query into tree-form data structure
  • Query optimization method for converting XPath (XML path language) query into tree-form data structure
  • Query optimization method for converting XPath (XML path language) query into tree-form data structure

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0018] In order to make the purpose, technical solutions and advantages of the present invention clearer, the implementation of the present invention will be further described in detail below in conjunction with the accompanying drawings:

[0019] This embodiment provides a method for converting an XPath query into a query optimization method of a tree data structure, such as figure 1 The method shown includes:

[0020] Step 10 converts the XPath query statement with positional predicates into Abstract Syntax Tree AST (Abstract Syntax Tree);

[0021] The above XPath query statement is simplified into an abstract syntax tree through lexical and grammatical analysis.

[0022] Step 20 converts different types of node objects in the abstract syntax tree AST into node objects in the twig pattern tree structure.

[0023] Traversing the abstract syntax tree from top to bottom, each AST node object calls its corresponding conversion interface, and converts it into the corresponding ...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

PUM

No PUM Login to view more

Abstract

The invention discloses a query optimization method for converting XPath (XML path language) query into tree-form data structure. The method includes converting XPath query sentences into location verbs with an AST (abstract syntax tree) and converting different types of target points in the AST with target points into branchlet-type tree structure. The branchlet-type tree data structure and a branchlet-type replacing method can optimize branchlet-type query to some extent; corresponding evaluation target points can be rapidly positioned through storing reference positions of location verbs target points when the branchlet-type query is utilized, so that evaluation to position query in a branchlet-type query process is speeded up.

Description

technical field [0001] The invention relates to the field of XML query optimization, in particular to a query optimization method for converting an XPath query with a position predicate into a tree data structure. Background technique [0002] XML has been widely used because of its advantages of self-description, scalability and openness. With the continuous growth of XML data, the management demand for large-scale XML data is becoming increasingly urgent. Businesses such as XML databases have emerged. product. The query of XML data is therefore particularly important, and XPath, one of the XML query standards, has also been extensively researched and implemented. Due to the semi-structured nature of XML documents, traditional relational database query algorithms are not suitable for them, so some algorithms for XPath query have been proposed one after another. At present, there is a twig pattern matching algorithm that is widely studied, that is, the XPath query is expre...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

Application Information

Patent Timeline
no application Login to view more
IPC IPC(8): G06F17/30
Inventor 陈琳程燕陈海涛符文君王奎
Owner TONGFANG KNOWLEDGE NETWORK TECH CO LTD (BEIJING)
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Try Eureka
PatSnap group products