Method and device for generating composite index key value

A technology of compound index and generating device, applied in the database field, can solve problems such as low scanning efficiency, and achieve the effects of reducing scanning time, improving scanning efficiency, and reducing the amount of calculation.

Active Publication Date: 2020-09-29
SHANGHAI DAMENG DATABASE
View PDF5 Cites 0 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0004] The purpose of the present invention is to propose a method and device for generating composite index key values ​​to solve the technical problem of low scanning efficiency in the prior art when there is no filtering condition in the leading column of the composite index

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
  • Method and device for generating composite index key value
  • Method and device for generating composite index key value
  • Method and device for generating composite index key value

Examples

Experimental program
Comparison scheme
Effect test

Embodiment 1

[0022] This embodiment provides a method for generating composite index key values. The method of this embodiment can be executed by a method device for generating a composite index key value in a numerical database, which can be implemented by means of hardware and / or software, and can generally be integrated into a relational numerical database

[0023] see figure 1 , the method for generating the composite index key value includes:

[0024] S110. Determine the leading column according to the filter condition.

[0025] A composite index (concatenated index) is an index composed of multiple columns, and the leading column may refer to the column before the first column with a filter condition. When building a composite index, the column before the first column with the filter condition of the composite index can be used as the leading column. For example: if there is a filter condition on column N+1 (N>0), then column 1 to column N are the leading columns.

[0026] Exempl...

Embodiment 2

[0034] Figure 4 It is the generation method of the compound index key value provided by the second embodiment of the present invention. This embodiment is optimized based on the above embodiment, and the key value of the leading column is created according to the value of the leading column, and the specific optimization is as follows : Generate the key-value tag of the current lookup column, the key-value tag includes the current values ​​of all columns before the current lookup column; when the key-value tag remains unchanged, look up the difference value of the current lookup column; when the difference is found value, create the key value of the leading column according to the found difference value; when no difference value is found or all the difference values ​​are searched, set the previous column of the current lookup column as the current lookup column until the current lookup column is the first column of the leading column.

[0035] see Figure 4 , the method fo...

Embodiment 3

[0050] Figure 5 is a schematic structural diagram of the device for generating composite index key values ​​provided by Embodiment 3 of the present invention, as shown in Figure 5 As shown, the device includes:

[0051] A leading column determining module 310, configured to determine a leading column according to a filter condition;

[0052] A key value creation module 320, configured to create the key value of the leading column according to the numerical value of the leading column;

[0053] A key value generating module 330, configured to generate a key value of a composite index according to the key value of the leading column.

[0054] The device for generating a composite index key value provided in this embodiment generates a composite index key value by combining the value of the leading column with the filter condition. Using the generated composite key value to perform conditional scanning can eliminate the need for full index scanning and then perform screening...

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 embodiment of the invention discloses a generating method and device of a compound index key value. The method includes the steps of determining a precedent line according to filtering conditions, establishing the key value of the precedent line according to the numerical value of the precedent line, and combining the key value of the precedent line with the filtering conditions to generate the key value of a compound index. By means of the method and device, by combining the value of the precedent line with the filtering conditions, the compound index key value is generated. Condition scanning is conducted by means of the generated compound key value, and there is no need to scan all indexes first and then screen the indexes according to conditions, the computational amount can be effectively reduced, scanning duration is shortened, and scanning efficiency is improved.

Description

technical field [0001] The invention relates to the technical field of databases, in particular to a method and device for generating composite index key values. Background technique [0002] In a relational numerical database, an index is a separate, physical storage structure that sorts the values ​​of one or more columns in a numerical database table. It is a collection of one or several column values ​​in a certain table and the corresponding A list of logical pointers to the value pages in the table that physically identify these values. An index can contain one, two, or more columns, and an index on two or more columns is called a composite index. [0003] When using a composite index, if the leading column of the leading column index does not have a corresponding filter condition, the leading column refers to the column before the first column with a filtering condition. According to the existing processing method, if you want to quickly Local positioning, because p...

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
Patent Type & Authority Patents(China)
IPC IPC(8): G06F16/22G06F16/28
CPCG06F16/2228G06F16/284
Inventor 朱仲颖耿慧玲张钦
Owner SHANGHAI DAMENG DATABASE
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