# US 2013/0159285 A1 · Many-core algorithms for in-memory column store databases

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 2013/0159285 A1
- Document ID: US20130159285A1
- Status: Published application
- Kind: A1
- Application number: 13/332,189
- Filed: 2011-12-20
- Published: 2013-06-20
- Earliest claimed: 2011-12-20
- Assignees: Sap SE
- Inventors: Jonathan Dees; Peter Sanders; Franz Faerber; Jochen Seidel
- Web page: https://patentgrep.com/patent/US20130159285A1

## CPC

- G06F 16/24544: {Join order optimisation}
- G06F 16/24542: {Plan optimisation}
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)

## Abstract

A pattern can be identified in at least part of a query whose definition is received in a query request. The identified pattern can be matched with a set of pre-defined patterns, each of which has associated therewith at least one pre-compiled query execution sub-component of a plurality of pre-compiled query execution sub-components retained in a library. A plan for executing the query can be generated, for example by incorporating the pre-compiled query execution sub-component associated with the matched pattern into the plan based on a pseudo code representation of the plan derived from the definition.

## Claims

### Claim 1

A computer program product comprising a machine-readable medium storing instructions that, when executed by at least one programmable processor, cause the at least one programmable processor to perform operations comprising:
receiving a query request comprising a definition of a query of a database persisted in a column-based storage;
identifying a pattern in at least part of the query;
matching the identified pattern with a set of pre-defined patterns, each of the pre-defined patterns having associated therewith at least one pre-compiled query execution sub-component of a plurality of pre-compiled query execution sub-components retained in a library;
generating a plan for executing the query, the generating comprising incorporating the pre-compiled query execution sub-component associated with the matched pattern into the plan based on a pseudo code representation of the plan derived from the definition; and
executing the query using the generated plan.

### Claim 2 (depends on 1)

A computer program product as in claim 1, wherein the operations further comprise
selecting, based on the matching of the identified patterns with the set of pre-defined patterns, an optimal sequence for processing a plurality of tables that must be joined to respond to the query; and
configuring the plan to include the optimal sequence for processing the plurality of tables.

### Claim 3 (depends on 1)

A computer program product as in claim 1, wherein the operations further comprise deriving the pseudo code representation of the plan from the definition.

### Claim 4 (depends on 1)

A computer program product as in claim 1, wherein the generating further comprises creating a single function to call the pre-compiled query execution component and the one or more other pre-compiled query execution components to generate the plan.

### Claim 5 (depends on 4)

A computer program product as in claim 4, wherein the single function defines a desired result and accesses a predefined parallelization plan from a set of two or more predefined parallelization plans based at least in part of the matching of the identified pattern.

### Claim 6 (depends on 1)

A computer program product as in claim 1, wherein the pre-compiled query execution sub-component comprises one or more pre-compiled SQL operations expressed in C++.

### Claim 7

A system comprising:
at least one programmable processor; and
a machine-readable medium storing instructions that, when executed by the at least one processor, cause the at least one programmable processor to perform operations comprising:
receiving a query request comprising a definition of a query of a database persisted in a column-based storage;
identifying a pattern in at least part of the query;
matching the identified pattern with a set of pre-defined patterns, each of the pre-defined patterns having associated therewith at least one pre-compiled query execution sub-component of a plurality of pre-compiled query execution sub-components retained in a library;
generating a plan for executing the query, the generating comprising incorporating the pre-compiled query execution sub-component associated with the matched pattern into the plan based on a pseudo code representation of the plan derived from the definition; and
executing the query using the generated plan.

### Claim 8 (depends on 7)

A system as in claim 7, wherein the operations further comprise:
selecting, based on the matching of the identified patterns with the set of pre-defined patterns, an optimal sequence for processing a plurality of tables that must be joined to respond to the query; and
configuring the plan to include the optimal sequence for processing the plurality of tables.

### Claim 9 (depends on 7)

A system as in claim 7, wherein the operations further comprise deriving the pseudo code representation of the plan from the definition.

### Claim 10 (depends on 1)

A computer program product as in claim 1, wherein the generating further comprises creating a single function to call the pre-compiled query execution component and the one or more other pre-compiled query execution components to generate the plan.

### Claim 11 (depends on 10)

A system as in claim 10, wherein the single function defines a desired result and accesses a predefined parallelization plan from a set of two or more predefined parallelization plans based at least in part of the matching of the identified pattern.

### Claim 12 (depends on 7)

A system as in claim 7, wherein the pre-compiled query execution sub-component comprises one or more pre-compiled SQL operations expressed in C++.

### Claim 13

A computer-implemented method comprising:
receiving a query request comprising a definition of a query of a database persisted in a column-based storage;
identifying a pattern in at least part of the query;
matching the identified pattern with a set of pre-defined patterns, each of the pre-defined patterns having associated therewith at least one pre-compiled query execution sub-component of a plurality of pre-compiled query execution sub-components retained in a library;
generating a plan for executing the query, the generating comprising incorporating the pre-compiled query execution sub-component associated with the matched pattern into the plan based on a pseudo code representation of the plan derived from the definition; and
executing the query using the generated plan.

### Claim 14 (depends on 13)

A computer-implemented method as in claim 13, further comprising:
selecting, based on the matching of the identified patterns with the set of pre-defined patterns, an optimal sequence for processing a plurality of tables that must be joined to respond to the query; and
configuring the plan to include the optimal sequence for processing the plurality of tables.

### Claim 15 (depends on 13)

A computer-implemented method as in claim 13, further comprising deriving the pseudo code representation of the plan from the definition.

### Claim 16 (depends on 13)

A computer-implemented method as in claim 13, wherein the generating further comprises creating a single function to call the pre-compiled query execution component and the one or more other pre-compiled query execution components to generate the plan.

### Claim 17 (depends on 16)

A computer-implemented method as in claim 16, wherein the single function defines a desired result and accesses a predefined parallelization plan from a set of two or more predefined parallelization plans based at least in part of the matching of the identified pattern.

### Claim 18 (depends on 13)

A computer-implemented method as in claim 13, wherein the pre-compiled query execution sub-component comprises one or more pre-compiled SQL operations expressed in C++.

### Claim 19 (depends on 13)

A computer-implemented method as in claim 13, wherein at least one of the receiving, the identifying, the matching, the generating, and the executing is performed by at least one programmable processor.
