Dismiss
InnovationQ will be updated on Sunday, Oct. 22, from 10am ET - noon. You may experience brief service interruptions during that time.
Browse Prior Art Database

Aggressive Merge across queries

IP.com Disclosure Number: IPCOM000243458D
Publication Date: 2015-Sep-23
Document File: 3 page(s) / 73K

Publishing Venue

The IP.com Prior Art Database

Abstract

Currently, with the technical changing, more and more application developer would like to use small object instead of big SQL. Actually, it is just like a kind of join, but with the program structure, the join sequence is defined by the code process. But the tables size and data are changed frequently, and programmers has to check the performance by experience. Our solution is that we need to detect the relationship between small objects, and the database would merge the small object into a big one.

This text was extracted from a PDF file.
This is the abbreviated version, containing approximately 58% of the total text.

Page 01 of 3

Aggressive Merge across queries

Currently, with the technical changing, more and more application developer would like to use small object instead of big SQL. For example, we get the value from T1 we might use the following function:

Procedure GetT1 : Return (Cursor)

Do;

SELECT C2 FROM T1
WHERE T1.C1 = ?

End;

We might also use the result of the GetT1 as input for another query as below:

For(;Cursor->next NULL; Cursor = Cursor->next)

Do;

SELECT *
FROM T2
WHERE T2.C1 = Cursor.Value
End;

Actually, it is just like a kind of join, but with the program structure, the join sequence is defined by thecode process. But the tables size and data are changed frequently, and programmers has to check the performance by experience.

Our solution is that we need to detect the relationship between small objects, and the database would merge the small object into a big one. For example, as the case above,

Procedure GetT1 : Return (Cursor)

Do;

SELECT C2 FROM T1
WHERE T1.C1 = ?

End;

We might also use the result of the GetT1 as input for another query as below:

For(;Cursor->next NULL; Cursor = Cursor->next)

Do;

SELECT C2

1



Page 02 of 3

FROM T2
WHERE T2.C1 = Cursor.Value End;

The database would change the SQL into a big one as below:

SELECT T2.C2
FROM T1, T2
WHERE T1. C1 = T2.C1 AND T1.C1=?

The following is the detail process for this method. The solution steps is as below:


1. Query Transformation
During this stage, database should detect the query style whether it meet the basic condition for...