Sélection de la langue

Search

Sommaire du brevet 3131330 

Énoncé de désistement de responsabilité concernant l'information provenant de tiers

Une partie des informations de ce site Web a été fournie par des sources externes. Le gouvernement du Canada n'assume aucune responsabilité concernant la précision, l'actualité ou la fiabilité des informations fournies par les sources externes. Les utilisateurs qui désirent employer cette information devraient consulter directement la source des informations. Le contenu fourni par les sources externes n'est pas assujetti aux exigences sur les langues officielles, la protection des renseignements personnels et l'accessibilité.

Disponibilité de l'Abrégé et des Revendications

L'apparition de différences dans le texte et l'image des Revendications et de l'Abrégé dépend du moment auquel le document est publié. Les textes des Revendications et de l'Abrégé sont affichés :

  • lorsque la demande peut être examinée par le public;
  • lorsque le brevet est émis (délivrance).
(12) Demande de brevet: (11) CA 3131330
(54) Titre français: METHODE, DISPOSITIF ET SYSTEME DE RECHERCHE EN BASE DE DONNEES PAR AGREGATION
(54) Titre anglais: DATABASE AGGREGATION QUERY METHOD, DEVICE AND SYSTEM
Statut: Examen
Données bibliographiques
(51) Classification internationale des brevets (CIB):
  • G06F 16/24 (2019.01)
(72) Inventeurs :
  • ZHANG, QIANG (Chine)
  • WANG, JINZHONG (Chine)
  • SUN, QIAN (Chine)
(73) Titulaires :
  • 10353744 CANADA LTD.
(71) Demandeurs :
  • 10353744 CANADA LTD. (Canada)
(74) Agent: JAMES W. HINTONHINTON, JAMES W.
(74) Co-agent:
(45) Délivré:
(22) Date de dépôt: 2021-09-20
(41) Mise à la disponibilité du public: 2022-03-18
Requête d'examen: 2022-09-16
Licence disponible: S.O.
Cédé au domaine public: S.O.
(25) Langue des documents déposés: Anglais

Traité de coopération en matière de brevets (PCT): Non

(30) Données de priorité de la demande:
Numéro de la demande Pays / territoire Date
202010988662.X (Chine) 2020-09-18

Abrégés

Abrégé anglais


A method, an apparatus and a system for database aggregate query, which
involves: receiving a
query request, obtaining a corresponding data table according to the query
request, acquiring
grouped fields of to-be-processed tuples in the data table, wherein the
grouped fields refer to
fields in the data table that are grouped according to grouping information
provided in the query
request; performing a calculation on the to-be-processed tuples that have
identical grouped fields
with an aggregate function to obtain aggregate results; taking the grouped
fields as primary keys
for a hat trie and taking the aggregate results corresponding to the grouped
fields as values
corresponding to the primary keys, and saving all the primary keys and their
corresponding
values to the hat trie; and returning the primary keys and their corresponding
values saved in the
hat trie as query results, to effectively reduce resource occupation for
grouped aggregate queries
and enhance overall query efficiency.

Revendications

Note : Les revendications sont présentées dans la langue officielle dans laquelle elles ont été soumises.


CLAIMS
What is claimed is:
1. A method for database aggregate query, comprising
receiving a query request, obtaining a corresponding data table according to
the query request,
acquiring grouped fields of to-be-processed tuples in the data table, wherein
the grouped fields
refer to fields in the data table that are grouped according to grouping
information provided in
the query request;
performing a calculation on the to-be-processed tuples that have identical
said grouped fields
with an aggregate function so as to obtain aggregate results; taking the
grouped fields as primary
keys for a hat trie and taking the aggregate results corresponding to the
grouped fields, which
results are obtained by the calculation with the aggregate function, as values
corresponding to
the primary keys, and saving all the primary keys and their corresponding
values to the hat trie;
and
returning the primary keys and their corresponding values saved in the hat
trie as query results
to a user.
2. The method of claim 1, wherein the step of "obtaining a corresponding data
table according to
the query request" comprises:
reading information of to-be-aggregated data from a database according to the
query request, and
converting the information into the data table.
3. The method of claim 1 or 2, wherein the step of "performing a calculation
on the to-be-
processed tuples that have identical said grouped fields with an aggregate
function so as to obtain
an aggregate result" further comprises:
checking whether there is already a primary key in the hat trie identical to
the grouped field of
18
Date recue / Date received 2021-11-22

the tuple; and
if there is not, taking the grouped field as the primary key, and calculating
the aggregate result
corresponding to the grouped field with the aggregate function, taking the
aggregate result as the
value corresponding to the primary key in the hat trie, and saving the both
into the hat trie;
if there is, searching the value corresponding to the primary key and taking
it as an initial value
for the calculation with the aggregate function, calculating the aggregate
result corresponding to
the grouped field with the aggregate function, updating the value
corresponding to the primary
key in the hat trie, and saving it into the hat trie.
4. The method of claim 3, further comprising:
checking resources occupation, if the occupation exceeds a predetermined
range, caching a part
of the primary keys and their corresponding values from a memory to a disk
using a format
required by the hat trie, and generating a cache file.
5. The method of claim 4, wherein the step of "returning the primary keys and
their corresponding
values saved in the hat trie as query results to a user" comprises:
checking whether there is a cache file generated with the disk,
if there is, merging the primary keys and their corresponding values in the
cache file to the
hat trie, and returning the primary keys and their corresponding values saved
in the hat trie as
the query results to the user;
if there is not, directly returning the primary keys and their corresponding
values saved in the
hat (fie as the query results to the user.
6. An apparatus for database aggregate query, comprising:
an acquiring unit, for receiving a query request, obtaining a corresponding
data table according
to the query request, acquiring grouped fields of to-be-processed tuples in
the data table, wherein
19
Date recue / Date received 2021-11-22

the grouped fields refer to fields in the data table that are grouped
according to grouping
information provided in the query request;
an aggregating unit, for performing a calculation on the to-be-processed
tuples that have identical
said grouped fields with an aggregate function so as to obtain aggregate
results; taking the
grouped fields as primary keys for a hat trie and taking the aggregate results
corresponding to
the grouped fields, which results are obtained by the calculation with the
aggregate function, as
values corresponding to the primary keys, and saving all the primary keys and
their
corresponding values to the hat trie; and
a returning unit, for returning the primary keys and their corresponding
values saved in the
hat trie as query results to a user.
7. The apparatus of claim 6, wherein said "obtaining a corresponding data
table according to the
query request" is achieved by:
reading information of to-be-aggregated data from a database according to the
query request, and
converting the information into the data table.
8. The apparatus of claim 6, wherein the aggregating unit is particularly for:
checking whether there is already a primary key in the hat trie identical to
the grouped field of
the tuple; and
if there is not, taking the grouped field as the primary key, and calculating
the aggregate result
corresponding to the grouped field with the aggregate function, taking the
aggregate result as the
value corresponding to the primary key in the hat trie, and saving the both
into the hat trie;
if there is, searching the value corresponding to the primary key and taking
it as an initial value
for the calculation with the aggregate function, calculating the aggregate
result corresponding to
the grouped field with the aggregate function, updating the value
corresponding to the primary
key in the hat trie, and saving it into the hat trie.
Date recue / Date received 2021-11-22

9. The apparatus of claim 6, further comprising
a caching unit, for checking resources occupation,
if the occupation exceeds a predetermined range, caching a part of the primary
keys and their
corresponding values from a memory to a disk using a format required by the
hat trie, and
generating a cache file.
10. A computer system, comprising:
one or more processor; and
a memory associated with the one or more processor, the memory storing one or
more program
instructions, which, when read and executed by the one or more processors,
perform a method
of any of claims 1 through 5.
21
Date recue / Date received 2021-11-22

Description

Note : Les descriptions sont présentées dans la langue officielle dans laquelle elles ont été soumises.


DATABASE AGGREGATION QUERY METHOD, DEVICE AND SYSTEM
BACKGROUND OF THE INVENTION
Technical Field
[0001] The present invention relates to Internet technologies, and more
particularly to a method,
an apparatus, and a system for database aggregate query.
Description of Related Art
[0002] Aggregate query is one type of query features of relational databases,
and includes
several kinds, such as group by, and distinct. This type of queries is mainly
used for
grouping indicator fields to be analyzed according to the dimension field as
specified in a
database, thereby facilitating subsequent pooled analysis, such as finding
sum, avg, count
and so on, making them a frequently used solution for making queries in online
analytical
processing (OLAP) systems.
[0003] The conventional database engines usually use a hash-table data
structure to realize
grouped aggregate queries. While the hash-type data structure is known to be
simple,
versatile, low time complexity of 0(1), and efficient, its disadvantageously
occupies
considerable memory resources, and this particularly true for a grouped query
that involves
high field cardinality and many groups (or buckets). Specifically, assuming
grouped fields
have 50 million strings having an average length of 10Byte (namely 500MB in
total), the
inteiniediately generated Hash table will produce a series of link table
structures that jointly
take 5GB memory capacity, meaning a 10X expansion. Since such a query occupies
considerably memory space and CPU resources, its execution may cause other
queries to
have prolonged execution time and even time-out problems.
SUMMARY OF THE INVENTION
[0004] The present invention provides a method, an apparatus, and a system for
database
aggregate query, which effectively reduce resource occupation for grouped
aggregate
queries and enhance overall query efficiency.
1
Date recue / Date received 202 1-1 1-22

[0005] The present invention provides the following solutions:
[0006] In a first aspect, the present invention provides a method for database
aggregate query,
which comprises:
[0007] receiving a query request, obtaining a corresponding data table
according to the query
request, acquiring grouped fields of to-be-processed tuples in the data table,
wherein the
grouped fields refer to fields in the data table that are grouped according to
grouping
information provided in the query request;
[0008] performing a calculation on the to-be-processed tuples that have
identical said grouped
fields with an aggregate function so as to obtain aggregate results; taking
the grouped fields
as primary keys for a hat tri e and taking the aggregate results corresponding
to the grouped
fields, which results are obtained by the calculation with the aggregate
function, as values
corresponding to the primary keys, and saving all the primary keys and their
corresponding
values to the hat trie; and
[0009] and returning the primary keys and their corresponding values saved in
the hat trie as
query results to a user.
[0010] Further, the step of "obtaining a corresponding data table according to
the query request"
comprises:
[0011] reading information of to-be-aggregated data from a database according
to the query
request, and converting the information into the data table.
[0012] Further, the performing a calculation on the to-be-processed tuples
that have identical
said grouped fields with an aggregate function so as to obtain an aggregate
result comprises:
[0013] for every said to-be-processed tuple, checking whether there is already
a primary key in
the hat trie identical to the grouped field of the tuple; and
[0014] if there is not, taking the grouped field as the primary key, and
taking its corresponding
aggregate result as the value corresponding to the primary key and saving the
both into the
hat trie; or
[0015] if there is, taking the value corresponding to the primary key as an
initial value for the
operation performed with the aggregate function, performing a further
operation on the
aggregate results corresponding to the grouped fields with the aggregate
function so as to
update the value corresponding to the primary key in the hat trie, and saving
the updated
2
Date recue / Date received 202 1-1 1-22

value into the hat trie.
[0016] Further, the method further comprises:
[0017] checking resources occupation, if the occupation exceeds a
predetermined range,
caching a part of the primary keys and their corresponding values from a
memory to a disk
using a format required by the hat trie, and generating a cache file.
[0018] Further, the step of "returning the primary keys and their
corresponding values saved in
the hat trie as query results to a user" comprises:
[0019] checking whether the cache file generated in the disk exists, and if it
does, merging the
primary keys and their corresponding values in the cache file to the hat trie,
and returning
the primary keys and their corresponding values saved in the hat trie as the
query results
to the user; or
[0020] if it does not, directly returning the primary keys and their
corresponding values saved
in the hat trie as the query results to the user.
[0021] In a second aspect, the present invention provides an apparatus for
database aggregate
query, which comprises:
[0022] an acquiring unit, for receiving a query request, obtaining a
corresponding data table
according to the query request, acquiring grouped fields of to-be-processed
tuples in the
data table, wherein the grouped fields refer to fields in the data table that
are grouped
according to grouping information provided in the query request;
[0023] an aggregating unit, for performing a calculation on the to-be-
processed tuples that have
identical said grouped fields with an aggregate function so as to obtain
aggregate results;
taking the grouped fields as primary keys for a hat trie and taking the
aggregate results
corresponding to the grouped fields, which results are obtained by the
calculation with the
aggregate function, as values corresponding to the primary keys, and saving
all the primary
keys and their corresponding values to the hat trie; and
[0024] a returning unit, for returning the primary keys and their
corresponding values saved in
the hat trie as query results to a user.
[0025] Further, the step of "obtaining a corresponding data table according to
the query request"
comprises:
3
Date recue / Date received 202 1-1 1-22

[0026] reading information of to-be-aggregated data from a database according
to the query
request, and converting the information into the data table.
[0027] Further, the aggregating unit is for:
[0028] for every said to-be-processed tuple, checking whether there is already
a primary key in
the hat trie identical to the grouped field of the tuple; and
[0029] if there is not, taking the grouped field as the primary key, and
taking its corresponding
aggregate result as the value corresponding to the primary key and saving the
both into the
hat trie; or
[0030] if there is, taking the value corresponding to the primary key as an
initial value for the
operation performed with the aggregate function, performing a further
operation on the
aggregate results corresponding to the grouped fields with the aggregate
function so as to
update the value corresponding to the primary key in the hat trie, and saving
the updated
value into the hat trie.
[0031] Further, the apparatus further comprises:
[0032] a caching unit, for checking resources occupation, if the occupation
exceeds a
predetermined range, caching a part of the primary keys and their
corresponding values
from a memory to a disk using a format required by the hat trie, and
generating a cache
file.
[0033] In a third aspect, the present invention provides a computer system,
which comprises:
[0034] one or more processor; and
[0035] a memory associated with the one or more processor, the memory storing
one or more
program instructions, which, when read and executed by the one or more
processors,
perform the foregoing method.
[0036] As described in the embodiments of the present invention, the present
invention
discloses the following technical effects: acquiring grouped fields of to-be-
processed tuples
from a data table obtained in advance, performing a calculation on the to-be-
processed
tuples that have identical said grouped fields with an aggregate function so
as to obtain
aggregate results; taking the grouped fields as primary keys for a hat trie
and taking the
aggregate results corresponding to the grouped fields as values corresponding
to the
4
Date recue / Date received 202 1-1 1-22

primary keys, and saving all the primary keys and their corresponding values
to the hat trie,
wherein the hat trie data structure uses common prefixes of strings to
significantly reduce
resource occupation as compared to the conventional primary key -value
structure, and
returning the primary keys and their corresponding values saved in the hat
trie as query
results to a user. Thus, the present invention helps to reduce query time and
improve overall
query efficiency.
BRIEF DESCRIPTION OF THE DRAWINGS
[0037] The accompanying drawings are provided herein for better understanding
of the present
invention and form a part of this disclosure. The illustrative embodiments and
their
descriptions are for explaining the present invention and by no means form any
improper
limitation to the present invention, wherein:
[0038] FIG. 1 is a flowchart of a method for database aggregate query
according to a first
embodiment of the present invention;
[0039] FIG. 2 is a structural diagram illustrating an apparatus for database
aggregate query
according to a second embodiment of the present invention;
[0040] FIG. 3 is a structural diagram illustrating a computer system according
to a third
embodiment of the present invention; and
[0041] FIG. 4 shows strings stored in a hat tri e data structure according to
the present invention.
DETAILED DESCRIPTION OF THE INVENTION
[0042] To make the foregoing objectives, features, and advantages of the
present invention
clearer and more understandable, the following description will be directed to
some
embodiments as depicted in the accompanying drawings to detail the technical
schemes
disclosed in these embodiments. It is, however, to be understood that the
embodiments
referred herein are only a part of all possible embodiments and thus not
exhaustive. Based
on the embodiments of the present invention, all the other embodiments can be
conceived
without creative labor by people of ordinary skill in the art, and all these
and other
embodiments shall be embraced in the scope of the present invention.
[0043] As described earlier about the prior art, the conventional database
engines usually use a
Date recue / Date received 202 1-1 1-22

hash-table data structure to realize grouped aggregate queries. While the hash-
type data
structure is known to be simple, versatile, low time complexity of 0(1), and
efficient, its
disadvantageously occupies considerable memory resources, and this
particularly true for
a grouped query that involves high field cardinality and many groups (or
buckets).
Specifically, assuming grouped fields have 50 million strings having an
average length of
10Byte (namely 500MB in total), the intermediately generated Hash table will
produce a
series of link table structures that jointly take 5GB memory capacity, meaning
a 10X
expansion. Since such a query occupies considerably memory space and CPU
resources,
its execution may cause other queries to have prolonged execution time and
even time-out
problems. Since such a query occupies considerably memory space and CPU
resources, its
execution may cause other queries to have prolonged execution time and even
time-out
problems.
[0044] The hat trie data structure combines the advantages of trie-, array-
and hash-based
approaches. Hat trie is useful in cases where string-type data is taken as
primary keys
because it uses common prefixes of strings to significantly reduce resource
occupation as
compared to the conventional primary key -value structure.
[0045] One example of a hat trie data structure storing string-type data is as
below:
romane ruber
romanes rubes
romanus rubicon
romulus rubicundus
rubens rubric
[0046] FIG. 4 shows how the strings above stored in a hat trie structure.
[0047] Hence, the present invention provides a method for database aggregate
query, which
involves acquiring grouped fields of to-be-processed tuples from a data table
obtained in
advance, performing a calculation on the to-be-processed tuples that have
identical said
grouped fields with an aggregate function so as to obtain aggregate results;
taking the
grouped fields as primary keys for a hat trie and taking the aggregate results
corresponding
to the grouped fields as values corresponding to the primary keys, and saving
all the
primary keys and their corresponding values to the hat trie, wherein the hat
trie data
structure uses common prefixes of strings to significantly reduce resource
occupation as
6
Date recue / Date received 202 1-1 1-22

compared to the conventional primary key -value structure, and returning the
primary keys
and their corresponding values saved in the hat trie as query results to a
user, thereby
decreasing query time and improving overall query efficiency.
Embodiment 1
[0048] The present invention embodiment provides a method for database
aggregate query. As
one example, the method is herein described as being applied to an apparatus
for database
aggregate query, and the apparatus may be used in any computer devices so that
the
computer device can perform the method for database aggregate query.
[0049] As shown in FIG. 1, the foregoing method comprises steps described
below.
[0050] The step Sll involves receiving a query request, obtaining a
corresponding data table
according to the query request, acquiring grouped fields of to-be-processed
tuples in the
data table, wherein the grouped fields refer to fields in the data table that
are grouped
according to grouping information provided in the query request.
[0051] The request for a grouped aggregate query contains grouping
information. The grouping
information usually refers to a specified dimension. The objective of query is
to group
indicator fields to be analyzed according to the dimension field as specified
in a database,
thereby facilitating subsequent pooled analysis. For example, a grouped
aggregate query
may be made for Data Table 1:
Year City
2016 Beijing
2016 Shanghai
2017 Beijing
2017 Hangzhou
[0052] The query request is "Selet Year, count(City) from table group by
year," and the field
following "group by" is the grouping information. Accordingly, the data shall
be grouped
by the dimension "Year," and subject to pooled analysis. The grouped fields
are results of
grouping the data by "Year" according to the query request, i.e., 2016 and
2017. Every line
in the data table is a tuple. Grouped fields of to-be-processed tuples come
from a data table
7
Date recue / Date received 202 1-1 1-22

obtained in advance. In this case, all the lines in the table above are to-be-
processed tuple,
so 2016, 2016, 2017, 2017 shall be acquired.
[0053] The step S12 involves performing a calculation on the to-be-processed
tuples that have
identical said grouped fields with an aggregate function so as to obtain
aggregate results;
taking the grouped fields as primary keys for a hat trie and taking the
aggregate results
corresponding to the grouped fields as values corresponding to the primary
keys, and
saving all the primary keys and their corresponding values to the hat Vie.
[0054] A calculation is performed on the to-be-processed tuples that have
identical said grouped
fields with an aggregate function so as to obtain aggregate results. The
grouped fields are
taken as primary keys for a hat trie, and the aggregate results corresponding
to the grouped
fields are taken as values corresponding to the primary keys, in order to save
all the primary
keys and their corresponding values to the hat Vie. In this case, the grouped
fields are 2016,
2016, 2017, 2017. The aggregate function is used to operate the to-be-
processed tuples
having 2016 and 2017, respectively, so as to obtain aggregate results. Then,
2016, 2017 are
taken as primary keys for the hat trie, and the aggregate results that are
obtained using the
aggregate function and corresponding to 2016 and 2017 are taken as values
corresponding
to the primary keys. According to Data Table 1, the aggregate results are 2
and 2, so what
is saved into the hat trie herein is "2016, 2; 2017, 2".
[0055] The step S13 involves returning the primary keys and their
corresponding values saved
in the hat trie as query results to a user.
[0056] The step of "obtaining a corresponding data table according to the
query request"
comprises:
[0057] reading information of to-be-aggregated data from a database according
to the query
request, and converting the information into the data table.
[0058] According to the query request, information about the database, table
and fields involved
in the query is acquired. Then the data information to be aggregated is read
from the
database and converted into a data table having tuples.
[0059] The step of "performing a calculation on the to-be-processed tuples
that have identical
8
Date recue / Date received 202 1-1 1-22

said grouped fields with an aggregate function so as to obtain an aggregate
result" further
comprises:
[0060] for every said to-be-processed tuple, checking whether there is already
a primary key in
the hat trie identical to the grouped field of the tuple; and
[0061] if there is not, taking the grouped field as the primary key, and
taking its corresponding
aggregate result as the value corresponding to the primary key and saving the
both into the
hat trie; or
[0062] if there is, taking the value corresponding to the primary key as an
initial value for the
operation performed with the aggregate function, performing a further
operation on the
aggregate results corresponding to the grouped fields with the aggregate
function so as to
update the value corresponding to the primary key in the hat trie, and saving
the updated
value into the hat trie.
[0063] Since every tuple is a line, in the process of acquiring the grouped
fields of the to-be-
processed tuples in the data table, the data is acquired line by line. For
example, to acquire
grouped fields of to-be-processed tuples in Data Table 1, the grouped field
2016 in the first
line is acquired first. In the part of determining whether there is already a
primary key
identical to 2016 in the hat trie, since 2016 is from the first line, there
could not be any
primary key identical to it in the hat trie at that moment. Therefore, 2016 is
taken as a
primary key and save to the hat trie. Then the aggregate function is used to
get an aggregate
result 1 corresponding to the grouped field as a value corresponding to that
primary key in
the hat trie, so the value "1" is saved to the hat vie. The same process is
repeated for the
grouped field, 2016, in the second line. At this time, since there is already
a primary key
identical to 2016 in the hat trie, as a result of processing the first line,
there is a primary
key identical to 2016 in the hat trie now. Thus, the value corresponding to
the primary key
(i.e., 1) is taken as the initial value for the operation performed with the
aggregate function,
and the aggregate result 2 that is obtained using the aggregate function and
corresponding
to the grouped field now processed is taken as the value corresponding to the
primary key
2016. Then the value "2" is saved into the hat trie to substitute the previous
value "1." In
other words, the value corresponding to the primary key 2016 is now updated
from "1" to
"2." Then reading is continued and the above processing steps are repeated
until the last
line is read. To this point, all the primary keys and values corresponding to
the primary
keys are saved to the hat vie.
9
Date recue / Date received 202 1-1 1-22

[0064] The method further comprises:
[0065] checking resources occupation, if the occupation exceeds a
predetermined range,
caching a part of the primary keys and their corresponding values from a
memory to a disk
using a format required by the hat trie, and generating a cache file.
[0066] During a grouped aggregate query, resource allocation is made according
to the resource
application contained in the query statement to the query. At this step,
resources occupation
is checked, if the occupation exceeds a predetermined range, a part of the
primary keys and
their corresponding values are cached from a memory to a disk using a format
required by
the hat trie, and a corresponding cache file is generated.
[0067] The step of "returning the primary keys and their corresponding values
saved in the
hat trie as query results to a user" comprises:
[0068] checking whether the cache file generated in the disk exists, and if it
does, merging the
primary keys and their corresponding values in the cache file to the hat trie,
and returning
the primary keys and their corresponding values saved in the hat trie as the
query results
to the user; or
[0069] if it does not, directly returning the primary keys and their
corresponding values saved
in the hat trie as the query results to the user.
[0070] Before the query results are returned, the existence of the foregoing
cache file in the disk
is checked. If there is such a cache file, the primary keys and their
corresponding values in
the cache file are saved to the hat trie. If there is not such a cache file,
the primary keys
and their corresponding values saved in the hat trie are directly returned to
the user as the
query results.
Embodiment 2
[0071] The present invention embodiment provides an apparatus for database
aggregate query
that implements the foregoing method. As shown in FIG. 2, the apparatus
comprises: an
acquiring unit 21, an aggregating unit 22, and a returning unit 23:
[0072] acquiring unit 21, for receiving a query request, obtaining a
corresponding data table
according to the query request, acquiring grouped fields of to-be-processed
tuples in the
data table, wherein the grouped fields refer to fields in the data table that
are grouped
Date recue / Date received 202 1-1 1-22

according to grouping information provided in the query request;
[0073] The request for a grouped aggregate query contains grouping
information. The grouping
information usually refers to a specified dimension. The objective of query is
to group
indicator fields to be analyzed according to the dimension field as specified
in a database,
thereby facilitating subsequent pooled analysis. For example, a grouped
aggregate query
may be made for Data Table 1:
Year City
2016 Beijing
2016 Shanghai
2017 Beijing
2017 Hangzhou
[0074] The query request is "Selet Year, count(City) from table group by
year," and the field
following "group by" is the grouping information. Accordingly, the data shall
be grouped
by the dimension "Year", and subject to pooled analysis. The grouped fields
are results of
grouping the data by "Year" according to the query request, i.e., 2016 and
2017. Every line
in the data table is a tuple. Grouped fields of to-be-processed tuples come
from a data table
obtained in advance. In this case, all the lines in the table above are to-be-
processed tuple,
so 2016, 2017 shall be acquired.
[0075] The aggregating unit 22 performs a calculation on the to-be-processed
tuples that have
identical said grouped fields with an aggregate function so as to obtain
aggregate results.
It then takes the grouped fields as primary keys for a hat trie and takes the
aggregate results
corresponding to the grouped fields as values corresponding to the primary
keys, and saves
all the primary keys and their corresponding values to the hat trie.
[0076] The aggregating unit 22 performs a calculation on the to-be-processed
tuples that have
identical said grouped fields with an aggregate function so as to obtain
aggregate results.
The grouped fields are taken as primary keys for a hat trie, and the aggregate
results
corresponding to the grouped fields are taken as values corresponding to the
primary keys,
in order to save all the primary keys and their corresponding values to the
hat trie. In this
case, the grouped fields are 2016, 2016, 2017, 2017. The aggregate function is
used to
11
Date recue / Date received 202 1-1 1-22

operate the to-be-processed tuples having 2016 and 2017, respectively, so as
to obtain
aggregate results. Then, 2016, 2017 are taken as primary keys for the hat
trie, and the
aggregate results that are obtained using the aggregate function and
corresponding to 2016
and 2017 are taken as values corresponding to the primary keys. According to
Data Table
1, the aggregate results are 2 and 2, so what is saved into the hat trie
herein is "2016, 2;
2017, 2".
[0077] The returning unit 23 is for returning the primary keys and their
corresponding values
saved in the hat trie as query results to a user.
[0078] The step of "obtaining a corresponding data table according to the
query request"
comprises:
[0079] reading information of to-be-aggregated data from a database according
to the query
request, and converting the information into the data table.
[0080] The aggregating unit is particularly for:
[0081] for every said to-be-processed tuple, checking whether there is already
a primary key in
the hat trie identical to the grouped field of the tuple; and
[0082] if there is not, taking the grouped field as the primary key, and
taking its corresponding
aggregate result as the value corresponding to the primary key and saving the
both into the
hat trie;
[0083] if there is, taking the value corresponding to the primary key as an
initial value for the
operation performed with the aggregate function, performing a further
operation on the
aggregate results corresponding to the grouped fields with the aggregate
function so as to
update the value corresponding to the primary key in the hat trie, and saving
the updated
value into the hat trie.
[0084] Since every tuple is a line, in the process of acquiring the grouped
fields of the to-be-
processed tuples in the data table, the data is acquired line by line. For
example, to acquire
grouped fields of to-be-processed tuples in Data Table 1, the grouped field
2016 in the first
line is acquired first. In the part of determining whether there is already a
primary key
identical to 2016 in the hat trie, since 2016 is from the first line, there
could not be any
primary key identical to it in the hat trie at that moment. Therefore, 2016 is
taken as a
12
Date recue / Date received 202 1-1 1-22

primary key and save to the hat trie. Then the aggregate function is used to
get an aggregate
result 1 corresponding to the grouped field as a value corresponding to that
primary key in
the hat trie, so the value "1" is saved to the hat vie. The same process is
repeated for the
grouped field, 2016, in the second line. At this time, since there is already
a primary key
identical to 2016 in the hat trie, as a result of processing the first line,
there is a primary
key identical to 2016 in the hat trie now. Thus, the value corresponding to
the primary key
(i.e., 1) is taken as the initial value for the operation performed with the
aggregate function,
and the aggregate result 2 that is obtained using the aggregate function and
corresponding
to the grouped field now processed is taken as the value corresponding to the
primary key
2016. Then the value "2" is saved into the hat trie to substitute the previous
value "1." In
other words, the value corresponding to the primary key 2016 is now updated
from "1" to
"2." Then reading is continued and the above processing steps are repeated
until the last
line is read. To this point, all the primary keys and values corresponding to
the primary
keys are saved to the hat Vie.
[0085] The apparatus further comprises:
[0086] a caching unit, for checking resources occupation, if the occupation
exceeds a
predetermined range, caching a part of the primary keys and their
corresponding values
from a memory to a disk using a format required by the hat trie, and
generating a cache
file.
[0087] During a grouped aggregate query, resource allocation is made according
to the resource
application contained in the query statement to the query. At this step,
resources occupation
is checked, if the occupation exceeds a predetermined range, a part of the
primary keys and
their corresponding values are cached from a memory to a disk using a format
required by
the hat trie, and a corresponding cache file is generated.
[0088] The apparatus for database aggregate query disclosed in the present
embodiment is
based on the same concept as the foregoing method for database aggregate
query, and is
configured to implement the disclosed method for database aggregate query. It
has the
function modules required by execution of the method for database aggregate
query and
provides the same beneficial effects as the method. For avoiding unnecessary
reiteration,
technical features not detailed herein for succinctness may be refer to the
method for
13
Date recue / Date received 202 1-1 1-22

database aggregate query as described in the previous embodiment provides.
[0089] Embodiment 3
[0090] The present embodiment provides a computer system for implementing the
foregoing
method and apparatus. The computer system comprises:
[0091] one or more processor; and
[0092] a memory associated with the one or more processor, the memory storing
one or more
program instructions, which, when read and executed by the one or more
processors,
perform the steps of the method as described in Embodiment 1, namely:
[0093] receiving a query request, obtaining a corresponding data table
according to the query
request, acquiring grouped fields of to-be-processed tuples in the data table,
wherein the
grouped fields refer to fields in the data table that are grouped according to
grouping
information provided in the query request;
[0094] performing a calculation on the to-be-processed tuples that have
identical said grouped
fields with an aggregate function so as to obtain aggregate results; taking
the grouped fields
as primary keys for a hat tri e and taking the aggregate results corresponding
to the grouped
fields as values corresponding to the primary keys, and saving all the primary
keys and
their corresponding values to the hat trie; and
[0095] returning the primary keys and their corresponding values saved in the
hat trie as query
results to a user.
[0096] FIG. 3 illustratively depicts a structure of the computer system. It
may specifically
include a processor 1510, a video display adapter 1511, a disk driver 1512, an
I/O port
1513, a network port 1514, and a memory 1520. The processor 1510, the video
display
adapter 1511, the disk driver 1512, the I/O port 1513, the network port 1514,
and the
memory 1520 may be communicatively connected through a communication bus 1530.
[0097] Therein, the processor 1510 may be implemented using a common CPU
(Central
Processing Unit), a microprocessor, an ASIC (Application Specific Integrated
Circuit), or
one or more integrated circuits for executing relevant programs to realize the
technical
scheme provided by the present invention.
[0098] The memory 1520 may be realized using a ROM (Read Only Memory), a RAM
14
Date recue / Date received 202 1-1 1-22

(Random Access Memory), a static storage device, a dynamic storage device or
any analog.
The memory 1520 may store for an operating system 1521 that controls operation
of the
computer system 1500, and a basic input/output system (BIOS) for controlling
low-level
operations of the computer system 1500. In addition, it may further store a
web browser
1523, a data storage management system 1524, and an icon and font processing
system
1525. The icon and font processing system 1525 may be an application enabling
operations
of the foregoing various steps of the embodiments of the present invention. In
any case,
when the technical scheme provided by present invention is realized using
software or
firmware, the related program codes are stored in the memory 1520 for the
processor 1510
to call and execute.
[0099] The input/output port 1513 is for connecting an I/O module for allowing
data input and
output. The input/output module may be built in the apparatus as a component
(not shown),
or may be set externally and connected to the apparatus so as to provides
corresponding
functions. Therein, the input device may include a keyboard, a mouse, a touch
panel, a
microphone, various sensors or more. The output device may include a display,
an amplifier,
a vibrator, an indicator or more.
[0100] The network port 1514 is for connecting a communication module (not
shown) to allow
communication between the disclosed apparatus and external devices. Therein,
the
communication module may enable communication either in a wired manner (such
as
through a USB, a network line, etc.) or in a wireless way (such as through a
mobile network,
WIFI, Bluetooth, etc.).
[0101] The bus 1530 comprises a channel allowing information transmission
among the
components of the device (i.e., the processor 1510, the video display adapter
1511, the disk
driver 1512, the I/O port 1513, the network port 1514, and the memory 1520).
[0102] Moreover, the computer system 1500 may further obtain information about
specific
collection conditions from a virtual resources object collection condition
information
database 1541 for its condition determination or the like.
[0103] It is to be noted that while the apparatus in the depicted embodiment
works merely by
Date recue / Date received 202 1-1 1-22

virtue of the processor 1510, the video display adapter 1511, the disk driver
1512, the I/O
port 1513, the network port 1514, the memory 1520, and the bus 1530, in
practical
implementations, the apparatus may further include additional components
required for its
desired purposes. Moreover, people skilled in the art would appreciate that
the disclosed
apparatus may only include the minimal number of components for realizing the
scheme
of the present invention instead of having all these depicted components.
[0104] From the description above, people skilled in the art would clearly
recognize that the
present invention may be realized using software in combination with necessary
universal
hardware-based platform. Based on this understanding, the technical scheme of
the present
invention may, in nature or for its part that is contributive to the
improvement of the prior
art, implemented in the form of a software product Such a computer software
product may
be stored in a storage medium, such as a ROM/RAM, a disc, an optical disk, or
the like and
include several instructions that direct a computer-based apparatus (such as a
personal
computer, a cloud server, or a network device) to perform the methods as
described in any
embodiment or any part of an embodiment of the present invention.
[0105] The embodiments disclosed herein are described in a progressive sense,
and therefore a
part in one embodiment may having tis details complemented by the description
for its
counter parts in other embodiments. Every embodiment is such described that it
only
emphasizes what differentiates it from the other embodiments. Particularly,
for a system or
an embodiment directed to a system, the subject matter may be described in a
simplified
way as more details may be learned from the embodiment about its relevant
method. The
system and system embodiment disclosed herein are merely illustrative, in
which a unit
described as a separated part may be or may be not physically separated, and a
part shown
as a unit may be or may be not a physical unit, meaning that it may be located
at one site
or alternatively be distributed across multiple units in a network. The
purpose of an
embodiment may be realized using all or some of the described/shown modules
according
to practical needs. People skilled in the art would understand and implement
the present
invention without paying creative efforts.
[0106] The present invention has been described with reference to the
preferred embodiments
and it is understood that the embodiments are not intended to limit the scope
of the present
16
Date recue / Date received 202 1-1 1-22

invention. Moreover, as the contents disclosed herein should be readily
understood and can
be implemented by a person skilled in the art, all equivalent changes or
modifications
which do not depart from the concept of the present invention should be
encompassed by
the appended claims. Hence, the scope of the present invention shall only be
defined by the
appended claims.
17
Date recue / Date received 202 1-1 1-22

Dessin représentatif
Une figure unique qui représente un dessin illustrant l'invention.
États administratifs

2024-08-01 : Dans le cadre de la transition vers les Brevets de nouvelle génération (BNG), la base de données sur les brevets canadiens (BDBC) contient désormais un Historique d'événement plus détaillé, qui reproduit le Journal des événements de notre nouvelle solution interne.

Veuillez noter que les événements débutant par « Inactive : » se réfèrent à des événements qui ne sont plus utilisés dans notre nouvelle solution interne.

Pour une meilleure compréhension de l'état de la demande ou brevet qui figure sur cette page, la rubrique Mise en garde , et les descriptions de Brevet , Historique d'événement , Taxes périodiques et Historique des paiements devraient être consultées.

Historique d'événement

Description Date
Rapport d'examen 2024-08-15
Modification reçue - réponse à une demande de l'examinateur 2023-12-07
Modification reçue - modification volontaire 2023-12-07
Rapport d'examen 2023-08-10
Inactive : Rapport - Aucun CQ 2023-08-10
Avancement de l'examen jugé conforme - alinéa 84(1)a) des Règles sur les brevets 2023-05-11
Lettre envoyée 2023-05-11
Modification reçue - modification volontaire 2023-04-17
Modification reçue - modification volontaire 2023-04-17
Inactive : Taxe de devanc. d'examen (OS) traitée 2023-04-17
Inactive : Avancement d'examen (OS) 2023-04-17
Lettre envoyée 2023-02-08
Inactive : Correspondance - SPAB 2022-12-23
Toutes les exigences pour l'examen - jugée conforme 2022-09-16
Exigences pour une requête d'examen - jugée conforme 2022-09-16
Requête d'examen reçue 2022-09-16
Demande publiée (accessible au public) 2022-03-18
Inactive : Page couverture publiée 2022-03-17
Inactive : CIB en 1re position 2022-01-26
Inactive : CIB attribuée 2022-01-26
Inactive : Supprimer l'abandon 2021-12-09
Inactive : Lettre officielle 2021-12-09
Inactive : Rép reçue: Traduct de priorité exigée 2021-11-22
Inactive : Rép reçue: Traduct de priorité exigée 2021-11-22
Réputée abandonnée - omission de répondre à un avis exigeant une traduction 2021-11-22
Lettre envoyée 2021-10-08
Exigences de dépôt - jugé conforme 2021-10-08
Exigences applicables à la revendication de priorité - jugée conforme 2021-10-07
Inactive : Pré-classement 2021-10-07
Demande de priorité reçue 2021-10-07
Demande reçue - nationale ordinaire 2021-09-20
Lettre envoyée 2021-09-20
Inactive : CQ images - Numérisation 2021-09-20

Historique d'abandonnement

Date d'abandonnement Raison Date de rétablissement
2021-11-22

Taxes périodiques

Le dernier paiement a été reçu le 2023-12-15

Avis : Si le paiement en totalité n'a pas été reçu au plus tard à la date indiquée, une taxe supplémentaire peut être imposée, soit une des taxes suivantes :

  • taxe de rétablissement ;
  • taxe pour paiement en souffrance ; ou
  • taxe additionnelle pour le renversement d'une péremption réputée.

Les taxes sur les brevets sont ajustées au 1er janvier de chaque année. Les montants ci-dessus sont les montants actuels s'ils sont reçus au plus tard le 31 décembre de l'année en cours.
Veuillez vous référer à la page web des taxes sur les brevets de l'OPIC pour voir tous les montants actuels des taxes.

Historique des taxes

Type de taxes Anniversaire Échéance Date payée
Taxe pour le dépôt - générale 2021-09-20 2021-09-20
Requête d'examen - générale 2025-09-22 2022-09-16
Avancement de l'examen 2023-04-17 2023-04-17
TM (demande, 2e anniv.) - générale 02 2023-09-20 2023-06-15
TM (demande, 3e anniv.) - générale 03 2024-09-20 2023-12-15
Titulaires au dossier

Les titulaires actuels et antérieures au dossier sont affichés en ordre alphabétique.

Titulaires actuels au dossier
10353744 CANADA LTD.
Titulaires antérieures au dossier
JINZHONG WANG
QIAN SUN
QIANG ZHANG
Les propriétaires antérieurs qui ne figurent pas dans la liste des « Propriétaires au dossier » apparaîtront dans d'autres documents au dossier.
Documents

Pour visionner les fichiers sélectionnés, entrer le code reCAPTCHA :



Pour visualiser une image, cliquer sur un lien dans la colonne description du document (Temporairement non-disponible). Pour télécharger l'image (les images), cliquer l'une ou plusieurs cases à cocher dans la première colonne et ensuite cliquer sur le bouton "Télécharger sélection en format PDF (archive Zip)" ou le bouton "Télécharger sélection (en un fichier PDF fusionné)".

Liste des documents de brevet publiés et non publiés sur la BDBC .

Si vous avez des difficultés à accéder au contenu, veuillez communiquer avec le Centre de services à la clientèle au 1-866-997-1936, ou envoyer un courriel au Centre de service à la clientèle de l'OPIC.

({010=Tous les documents, 020=Au moment du dépôt, 030=Au moment de la mise à la disponibilité du public, 040=À la délivrance, 050=Examen, 060=Correspondance reçue, 070=Divers, 080=Correspondance envoyée, 090=Paiement})


Description du
Document 
Date
(aaaa-mm-jj) 
Nombre de pages   Taille de l'image (Ko) 
Revendications 2023-12-06 12 644
Description 2021-09-19 21 874
Description 2021-11-21 17 838
Revendications 2021-11-21 4 137
Dessins 2021-11-21 3 94
Abrégé 2021-11-21 1 25
Dessin représentatif 2022-02-14 1 22
Revendications 2023-04-16 14 734
Demande de l'examinateur 2024-08-14 5 139
Courtoisie - Certificat de dépôt 2021-10-07 1 569
Courtoisie - Réception de la requête d'examen 2023-02-07 1 423
Demande de l'examinateur 2023-08-09 7 343
Modification / réponse à un rapport 2023-12-06 37 1 402
Nouvelle demande 2021-09-19 6 214
Avis du commissaire - Traduction requise 2021-09-19 2 199
Traduction reçue 2021-11-21 29 1 218
Courtoisie - Lettre du bureau 2021-12-08 1 180
Traduction reçue 2021-11-21 29 1 218
Correspondance pour SPA 2022-12-22 4 153
Avancement d'examen (OS) / Modification / réponse à un rapport 2023-04-16 20 718
Courtoisie - Requête pour avancer l’examen - Conforme (OS) 2023-05-10 1 176