Database query optimization methods, apparatuses, and computer devices

US2021117424A1 · US · A1

Patent metadata
FieldValue
Publication numberUS-2021117424-A1
Application numberUS-202017084840-A
CountryUS
Kind codeA1
Filing dateOct 30, 2020
Priority dateAug 31, 2018
Publication dateApr 22, 2021
Grant date

How to read this patent

A practical reading order for non-experts. Skip the full description unless you need deep technical detail.

  1. Title

    What the patent document calls the invention.

  2. Abstract

    A short plain-language summary of the technical disclosure.

  3. Assignees and inventors

    Who owns or filed the patent and who is credited as inventor.

  4. Key dates

    Filing, priority, publication, and grant dates set the timeline.

  5. First independent claim

    The legal scope of protection — read this for what is actually claimed.

  6. CPC / IPC classifications

    Technology tags used to group this patent with similar filings.

  7. Citations and related patents

    Prior art links and similar publications in this corpus.

Abstract

Official abstract text for this publication.

A database query optimization computer-implemented method, medium, and system are disclosed. In one computer-implemented method, a data query request sent by a client device is received and parsed. An execution plan for executing the data query request is determined based on a parsing result. If the execution plan is a nested loop anti-join, whether there is a possibility that a to-be-queried field in a to-be-queried data table indicated by the data query request contains a NULL value is determined. If there is a possibility that the to-be-queried field contains a NULL value, a filter condition is generated and the execution plan is optimized based on the filter condition.

First claim

Opening claim text (preview).

What is claimed is: 1 . A computer-implemented method for database query optimization, comprising: receiving a data query request sent by a client device; parsing the data query request, and determining an execution plan for executing the data query request based on a parsing result; in response to determining that the execution plan is a nested loop anti-join, determining whether a probability that a to-be-queried field in a to-be-queried data table indicated by the data query request contains a NULL value is greater than zero; and in response to determining that the probability that the to-be-queried field contains a NULL value is greater than zero, generating a filter condition and optimizing the execution plan based on the filter condition generated. 2 . The computer-implemented method of claim 1 , wherein determining whether a probability that a to-be-queried field in a to-be-queried data table indicated by the data query request contains a NULL value is greater than zero comprises: determining a NULL attribute of a to-be-queried field in a to-be-queried data table indicated by the data query request. 3 . The computer-implemented method of claim 2 , further comprising: in response to determining that the NULL attribute of the to-be-queried field is in a default state, determining that the probability that the to-be-queried field contains a NULL value is zero, wherein the default state indicates that a value of the to-be-queried field is not allowed to be a NULL value; and in response to determining that the NULL attribute of the to-be-queried field is in a non-default state, determining that the probability that the to-be-queried field contains a NULL value is greater than zero, wherein the non-default state indicates that the value of the to-be-queried field is allowed to be a NULL value. 4 . The computer-implemented method of claim 1 , wherein generating a filter condition comprises: determining a data representation form of a field value of the to-be-queried field in the to-be-queried data table, wherein the data representation form comprises a single-value form or a vector form; and generating a filter condition based on the data representation form, wherein different data representation forms correspond to different filter conditions. 5 . The computer-implemented method of claim 4 , wherein generating a filter condition based on the data representation form comprises: in response to the data representation form being a single-value form, generating a first filter condition. 6 . The computer-implemented method of claim 5 , further comprising: in response to the data representation form being a vector form, generating a second filter condition. 7 . The computer-implemented method of claim 1 , wherein optimizing the execution plan based on the filter condition generated comprises: applying the filter condition generated as a join condition for inner loop scanning in the nested loop anti-join. 8 . A non-transitory, computer-readable medium storing one or more instructions executable by a computer system to perform operations comprising: receiving a data query request sent by a client device; parsing the data query request, and determining an execution plan for executing the data query request based on a parsing result; in response to determining that the execution plan is a nested loop anti-join, determining whether a probability that a to-be-queried field in a to-be-queried data table indicated by the data query request contains a NULL value is greater than zero; and in response to determining that the probability that the to-be-queried field contains a NULL value is greater than zero, generating a filter condition and optimizing the execution plan based on the filter condition generated. 9 . The non-transitory, computer-readable medium of claim 8 , wherein determining whether a probability that a to-be-queried field in a to-be-queried data table indicated by the data query request contains a NULL value is greater than zero comprises: determining a NULL attribute of a to-be-queried field in a to-be-queried data table indicated by the data query request. 10 . The non-transitory, computer-readable medium of claim 9 , further comprising: in response to determining that the NULL attribute of the to-be-queried field is in a default state, determining that the probability that the to-be-queried field contains a NULL value is zero, wherein the default state indicates that a value of the to-be-queried field is not allowed to be a NULL value; and in response to determining that the NULL attribute of the to-be-queried field is in a non-default state, determining that the probability that the to-be-queried field contains a NULL value is greater than zero, wherein the non-default state indicates that the value of the to-be-queried field is allowed to be a NULL value. 11 . The non-transitory, computer-readable medium of claim 8 , wherein generating a filter condition comprises: determining a data representation form of a field value of the to-be-queried field in the to-be-queried data table, wherein the data representation form comprises a single-value form or a vector form; and generating a filter condition based on the data representation form, wherein different data representation forms correspond to different filter conditions. 12 . The non-transitory, computer-readable medium of claim 11 , wherein generating a filter condition based on the data representation form comprises: in response to the data representation form being a single-value form, generating a first filter condition. 13 . The non-transitory, computer-readable medium of claim 12 , further comprising: in response to the data representation form being a vector form, generating a second filter condition. 14 . The non-transitory, computer-readable medium of claim 8 , wherein optimizing the execution plan based on the filter condition generated comprises: applying the filter condition generated as a join condition for inner loop scanning in the nested loop anti-join. 15 . A computer-implemented system, comprising: one or more computers; and one or more computer memory devices interoperably coupled with the one or more computers and having tangible, non-transitory, machine-readable media storing one or more instructions that, when executed by the one or more computers, perform one or more operations comprising: receiving a data query request sent by a client device; parsing the data query request, and determining an execution plan for executing the data query request based on a parsing result; in response to determining that the execution plan is a nested loop anti-join, determining whether a probability that a to-be-queried field in a to-be-queried data table indicated by the data query request contains a NULL value is greater than zero; and in response to determining that the probability that the to-be-queried field contains a NULL value is greater than zero, generating a filter condition and optimizing the execution plan based on the filter condition generated. 16 . The computer-implemented system of claim 15 , wherein determining whether a probability that a to-be-queried field in a to-be-queried data table indicated by the data query request contains a NULL value is greater than zero comprises: determining a NULL attribute of a to-be-queried field in a to-be-queried data table indicated by the data query request. 17 . The computer-implemented system of claim 16 , further comprising: in response to determining that the NULL attribute o

Assignees

Inventors

Classifications

Patent family

Related publications grouped by family.

External sources

Frequently asked questions

Answers are generated from the same data shown on this page.

What does patent US2021117424A1 cover?
A database query optimization computer-implemented method, medium, and system are disclosed. In one computer-implemented method, a data query request sent by a client device is received and parsed. An execution plan for executing the data query request is determined based on a parsing result. If the execution plan is a nested loop anti-join, whether there is a possibility that a to-be-queried f…
Who is the assignee on this patent?
Advanced New Technologies Co Ltd
What technology area does this patent fall under?
Primary CPC classification G06F16/24537. Mapped technology areas include Physics.
When was this patent published?
Publication date Thu Apr 22 2021 00:00:00 GMT+0000 (Coordinated Universal Time) (A1). Legal status and post-grant events are not shown on this page.
What related patents are in patentsdb?
We list 8 related publications on this page (citations in our corpus or others sharing the same primary CPC).