Looking for breakthrough ideas for innovation challenges? Try Patsnap Eureka!

Database kernel query optimization method based on equivalence class

A technology of query optimization and equivalence class, which is applied in the field of database kernel query optimization of valence class, can solve the problem of low performance of database query and achieve the effect of improving query performance

Active Publication Date: 2014-03-26
YONYOU NETWORK TECH
View PDF3 Cites 16 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0005] The purpose of the embodiments of the present invention is to provide a database kernel query optimization method based on equivalence classes, which solves the problem of low performance of certain database queries in the prior art

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
  • Database kernel query optimization method based on equivalence class
  • Database kernel query optimization method based on equivalence class
  • Database kernel query optimization method based on equivalence class

Examples

Experimental program
Comparison scheme
Effect test

Embodiment

[0036] Suppose there are tables t1, t2 and t3, and t1, t2 and t3 have two columns col1 and col2 respectively. For the query statement: "select t1.col1,t2.col2,t3.col2from t1,t2,t3where t1.col1=t2.col2and t2.col2=t3.col1and t1.col1>0.9order by t2.col2", according to this The idea of ​​invention, the specific process is as follows:

[0037] 1. Enter the query planner, loop into the subquery planner, and the global linked lists RELS, COLS, and ECS are used to store the table objects, column objects, and equivalence class objects generated during the query statement analysis process. The initialization linked list is shown in Table 1. When the number of object structures exceeds eight, bitmap variables (such as Rel\Col\Eclass) can be dynamically loaded. Here, only one byte is used to illustrate the example. The global bit variable records the Id number of each object, and the Rel\Col\Eclass in the object records the correspondence with the global variable and the relationship be...

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 belongs to the field of software, and provides a database kernel query optimization method based on an equivalence class. The method comprises the steps of using a function for processing description after the keyword 'from' and before the keyword 'where' in sql sentences after inquire statements enter a sub query optimizer, processing a nest tree structure with explicit connection or a linked list with no connection mode assigned, extracting list information, obtaining list objects, initializing the Col and Eclass bit variables contained by the list objects, and filling a linked list RELS; processing the restricted condition linked list 'quals' after the 'on' and after the 'where' in the sql sentences, and carrying out transmission on the restricted conditions according to the Eclass bit variables; entering an enumerator, enlarging planed searching space according to the Eclass bit variables, enumerating more equivalence plans, and entering a cost calculator to count cost; obtaining the plan with the minimum cost as a final execution plan, wherein the execution plan is compiled into an execution tree, and the execution plan is sent to an actuator to be executed. The database kernel query optimization method based on the equivalence class has the advantages of being high in performance.

Description

technical field [0001] The invention belongs to the field of software, in particular to an equivalence class-based database kernel query optimization method. Background technique [0002] The overall architecture of the early database management system, whether in terms of security or memory hardware environment, was designed from the perspective of occupying less memory. Therefore, most of the data retrieval execution operations of traditional relational databases adopt a demand-pull pipeline mechanism (a demand-pull pipeline mechanism): the system calls a plan node (plan node) each time, which will be obtained from the following nodes A record or an empty record. The number of data pages resident in the memory is at most the number of leaf nodes of the query tree. This mechanism can greatly save memory usage, and it can be efficiently applied to simple extraction and verification of single-table data. However, multi-table connections or complex calculations of relational...

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
CPCG06F16/24544
Inventor 宋晓眉
Owner YONYOU NETWORK TECH
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Patsnap Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Patsnap Eureka Blog
Learn More
PatSnap group products