IP Library Granted Patent US 10,275,491
Granted Patent B2
US 10,275,491 · App. 15/220,247 · Granted Apr 30, 2019

Method and apparatus for executing query and computer readable medium therefor

Inventors: Sukwon Yi (Gyeonggi-do, KR); Youngjae Choi (Gyeonggi-do, KR); Kyungtae Lee (Gyeonggi-do, KR); Seungkeol Kim (Gyeonggi-do, KR)
Assignee: TmaxData Co., Ltd.
G06F17/30489G06F17/30318G06F17/30339
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 10,275,491
App. No.
15/220,247
Granted
Apr 30, 2019
Kind
B2
Abstract

Provided is a method for executing a query in a DBMS. The method may include: receiving a query statement including a pivot operator—the query statement being associated with an original table; executing a pivot operation for the original table in response to reception of the query statement; generating BLOB data by serializing at least a part of an execution result of the pivot operation to a BLOB type; and storing the generated BLOB data in a pivot table.

Claims (29)

1. A non-transitory computer-readable medium including encoded commands, which allow one or more processors of a computing apparatus to perform the following operations for executing a query statement in a database management system (DBMS) when the commands are executed by the one or more processors of a computing system, wherein the operations include:

an operation of receiving a query statement including a pivot operator, where the query statement is associated with an original table;

an operation of generating a pivoted data set and non-pivoted data set to be stored in a pivot table by executing the pivot operation for the original table in response to reception of the query statement;

an operation of generating binary large object (BLOB) data by counting the number of columns having no null value in the pivoted data set, determining column number information for the respective columns having no null value, determining actual positional information on the BLOB data for a value of a column corresponding to the column number information, determining actual values for the respective columns having no null value, and transforming the pivoted data set to a serialized data stream based on the counted number of columns, the determined column number information and the determined actual values; and

an operation of storing the generated BLOB data at a place associated with a place in a pivot table where the pivoted data set is to be stored, in lieu of the pivoted data set so that the generated BLOB data functions as the pivoted data set, and storing the non-pivoted data set at another place in the pivot table.

2. The computer-readable medium of claim 1 , wherein the operation of generating a pivoted data set and non-pivoted data set to be stored in a pivot table includes:

an operation of executing a Group by operation with respect to a first set of one or more columns which are not associated with a pivot operator in the original table; and

an operation of executing an aggregation operation by a unit of the first set of one or more columns of which the Group by operation is executed with respect to a second set of one or more columns associated with the pivot operator in the original table; and thereafter, an operation of exchanging a row and a column for the second set of one or more columns.

3. The computer-readable medium of claim 2 , wherein the operation of generating the BLOB data includes an operation of generating the BLOB data by serializing the execution result of the pivot operation for the second set of one or more columns associated with the pivot operator to the BLOB type in the original table, where the operation of storing the generated BLOB data in the pivot table includes an operation of storing the generated BLOB data in a second pivot column in the pivot table, and

the second pivot column is a single column.

4. The computer-readable medium of claim 1 , wherein the operation of generating the BLOB data includes an operation of generating the BLOB data by serializing the execution result of the pivot operation for the second set of one or more columns associated with the pivot operator to the BLOB type in the original table, where the operation of storing the generated BLOB data in the pivot table includes an operation of storing the generated BLOB data in a second pivot column in the pivot table, and

the second pivot column is a single column.

5. The computer-readable medium of claim 1 , wherein the BLOB data is constituted by a header count BLOB data, a header BLOB data, and a value BLOB data in order.

6. The computer-readable medium of claim 5 , wherein a header information of the header BLOB data includes column number information having a size of 4 bytes and offset information in BLOB data having the size of 4 bytes and the offset information represents actual positional information on the BLOB data for a value of a column corresponding to the column number information.

7. The computer-readable medium of claim 5 , wherein the header count BLOB data has the size of 4 bytes and the header BLOB data has a size obtained by multiplying the number of columns having no null value by 8 bytes.

8. The computer-readable medium of claim 1 , further comprising:

an operation of storing meta information for the generated BLOB data in a meta information management table.

9. A method for executing a query in a DBMS, performed by one or more processors of a computing apparatus, the method comprising:

receiving a query statement including a pivot operator, where the query statement is associated with an original table;

generating a pivoted data set and non-pivoted data set to be stored in a pivot table by executing a pivot operation for the original table in response to reception of the query statement;

generating BLOB data by counting the number of columns having no null value in the pivoted data set, determining column number information for the respective columns having no null value, determining actual positional information on the BLOB data for a value of a column corresponding to the column number information, determining actual values for the respective columns having no null value, and transforming the pivoted data set to a serialized data stream based on the counted number of columns, the determined column number information and the determined actual values; and

storing the generated BLOB data at a place associated with a place in a pivot table where the pivoted data set is to be stored, in lieu of the pivoted data set so that the generated BLOB data functions as the pivoted data set, and storing the non-pivoted data set at another place in the pivot table.

10. An apparatus for executing a query statement in a database management system, the apparatus comprising:

a database management module in the database management system, where the database management module is configured to cooperate with components in the database management system that include one or more processors to execute instructions, one or more memories to store information, one or more data input components to receive data input from a user of the database management system, a communication circuit to establish a communication link to communicate with other computing devices external to the database management system, a display device to display at least some of the information stored in the one or more memories, where portions of the database management module implemented in software are stored in the one or more memories and are executed by the one or more processors, where the database management module consists of multiple different modules including but not limited to a communication module, an operation executing module, a BLOB data generating module, and a storage module to efficiently store, query, and output an execution result for a pivot calculation in a binary large object (BLOB) type;

where the communication module is configured to receive the query statement includes a pivot operator and the query statement is associated with an original table;

where the operation executing module is configured to generate a pivoted data set and non-pivoted data set to be stored in a pivot table by executing a pivot operation for the original table in response to reception of the query statement;

where the BLOB data generating module is configured to generate BLOB data by counting the number of columns having no null value in the pivoted data set, determining column number information for the respective columns having no null value, determining actual positional information on the BLOB data for a value of a column corresponding to the column number information, determining actual values for the respective columns having no null value, and transforming the pivoted data set to a serialized data stream based on the counted number of columns, the determined column number information and the determined actual values; and

where the storage module is configured to store the generated BLOB data at a place associated with a place in a pivot table where the pivoted data set is to be stored, in lieu of the pivoted data set so that the generated BLOB data functions as the pivoted data set, and storing the non-pivoted data set at another place in the pivot table.

11. The apparatus of claim 10 , where the pivot calculation is performed in order to extend a schema by performing an aggregation query statement with respect to a specific condition in the DBMS, where when the pivot calculation is performed, since multiple pivot columns are additionally automatically generated, the pivot calculation performs an additional calculation by using the multiple pivot columns.

Assignments (2)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Jul 12, 2022
From: TMAXDATACO., LTD. (ALSO KNOWN AS TMAXDATA CO., LTD. AND TMAX DATA CO., LTD.)
To: TMAXTIBERO CO., LTD.
Reel/Frame 060635/0387 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded May 24, 2017
From: YI, SUKWON; CHOI, YOUNGJAE; LEE, KYUNGTAE; KIM, SEUNGKEOL
To: TMAXDATA CO., LTD.
Reel/Frame 042493/0055 →
Priority Claims (1)
KR 10-2016-0076234 · Jun 20, 2016 · national
Continuity (1)
Related Publication 20170364560A1 · Dec 21, 2017