JP6328078B2 - Database system and database system program - Google Patents

Database system and database system program Download PDF

Info

Publication number
JP6328078B2
JP6328078B2 JP2015144513A JP2015144513A JP6328078B2 JP 6328078 B2 JP6328078 B2 JP 6328078B2 JP 2015144513 A JP2015144513 A JP 2015144513A JP 2015144513 A JP2015144513 A JP 2015144513A JP 6328078 B2 JP6328078 B2 JP 6328078B2
Authority
JP
Japan
Prior art keywords
data source
data
execution plan
integration server
execution
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
JP2015144513A
Other languages
Japanese (ja)
Other versions
JP2017027325A (en
Inventor
圭 山地
圭 山地
大河 片山
大河 片山
誠 嶋村
誠 嶋村
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Toshiba Corp
Original Assignee
Toshiba Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Toshiba Corp filed Critical Toshiba Corp
Priority to JP2015144513A priority Critical patent/JP6328078B2/en
Publication of JP2017027325A publication Critical patent/JP2017027325A/en
Application granted granted Critical
Publication of JP6328078B2 publication Critical patent/JP6328078B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Description

本発明の実施形態は、データベースシステムおよびデータベースシステム用プログラムに関する。   Embodiments described herein relate generally to a database system and a database system program.

一般に、異種のデータベースに接続するデータソースに対して結合検索を実行するクライアント・サーバ型のデータベースシステムにおいては、各データベースの検索結果をデータベース統合サーバにおいて結合して、クライアント側に転送している。   In general, in a client-server type database system that performs a combined search on data sources connected to different types of databases, search results of the databases are combined in a database integration server and transferred to the client side.

各データソースからは、例えば表形式の検索結果を記した大量のメモリが通信を介してデータベース統合サーバにコピーされる。これに伴い、データベース統合サーバには、大量のメモリが集まることになり、検索結果の統合処理に多くの時間を要していた。   From each data source, for example, a large amount of memory in which tabular search results are recorded is copied to the database integration server via communication. Along with this, a large amount of memory is collected in the database integration server, and it takes a lot of time to integrate search results.

特開2007−26296号公報JP 2007-26296 A

本発明が解決しようとする課題は、結合検索結果の統合処理をより高速化することのできるデータベースシステムおよびデータベースシステム用プログラムを提供することである。   The problem to be solved by the present invention is to provide a database system and a database system program capable of further speeding up the integration processing of join search results.

実施形態のデータベースシステムは、クライアントから要求されるクエリを受け付けるアプリケーションと、前記アプリケーションから送信されるクエリを解釈し、複数のデータソースにおける検索の実行計画を生成して当該実行計画をそれぞれに送信するDB統合サーバと、前記実行計画に沿ってデータを取り出すためのオブジェクトである、少なくとも2つの異種のデータソースとを有するデータベースシステムであって、各データソースは、それぞれが管理するデータを呼び出して異種のデータソース間で共通利用するための手順やデータ形式を定めた規約である異種のデータソース用APIと、前記DB統合サーバと通信し、異種のデータソースに対して、前記データソース用APIを使用して検索を実行させる機能を持つ統合サーバ用データ変換部とを備えて、前記統合サーバ用データ変換部同士が相互に通信可能に構成され、検索条件のやりとりを行うとともに、前記DB統合サーバは、各データソースにおける検索の実行計画が、前記統合サーバ用データ変換部同士の通信を含むように生成するもので、前記クエリ、及びスキーマ情報、データソース情報を保持し、前記クエリ、スキーマ情報およびデータソース情報を参照して、前記データソース側からの転送データが少なくて済むように、前記データソースに対する実行計画を作成するプランナと、前記DB統合サーバと前記データソース間で指令やデータの送受信を行う第1の送受信部と、前記プランナから前記データソースに対する実行計画を受け取って前記第1の送受信部に送信するとともに、前記第1の送受信部を介して受け取った前記データソースにおける検索結果の統合処理を実行し、前記アプリケーションに返す機能を果たす計画実行部とを備え、前記データソースは、前記第1の送受信部を介して前記DB統合サーバから実行計画を受信するとともに、実行計画内での転送、受信命令の実施を行い、前記第1の送受信部を介して前記DB統合サーバへ実行計画の実行結果を送信する第2の送受信部と、前記第2の送受信部で受信した前記DB統合サーバからの実行計画を受け取り、前記データソース用APIを使用して、実行計画を実施する計画実行部を備えるデータベースシステム。 The database system of the embodiment interprets a query transmitted from a client and an application that accepts a query requested from a client, generates an execution plan for a search in a plurality of data sources, and transmits the execution plan to each of them. A database system having a DB integration server and at least two different types of data sources that are objects for retrieving data in accordance with the execution plan, wherein each data source calls different data to manage different types of data APIs for different types of data sources, which are contracts that define procedures and data formats for common use among data sources, and communicate with the DB integration server, and the APIs for data sources for different types of data sources An integrated server with the ability to perform searches using And a use data conversion unit, the integration server data converting unit to each other is configured to communicate with each other, with exchanges search, the DB integration server execution plan for retrieval of each data source, It is generated so as to include communication between the integrated server data converters , holds the query, schema information, and data source information, and refers to the query, schema information, and data source information, and the data source A planner that creates an execution plan for the data source, a first transmission / reception unit that transmits and receives instructions and data between the DB integration server and the data source, and the planner. And receiving an execution plan for the data source from the first transmission / reception unit and the first transmission / reception unit. A plan execution unit that performs a process of integrating search results in the data source received via the reception unit and returns the result to the application, and the data source includes the DB via the first transmission / reception unit. Second transmission / reception for receiving an execution plan from the integrated server, transferring the execution plan within the execution plan, executing a reception command, and transmitting the execution result of the execution plan to the DB integrated server via the first transmission / reception unit And a plan execution unit that receives the execution plan from the DB integration server received by the second transmission / reception unit and executes the execution plan using the data source API .

本発明の実施形態に係るデータベースシステムの概略構成を示すブロック図である。It is a block diagram which shows schematic structure of the database system which concerns on embodiment of this invention. DB統合サーバとデータソースの詳細な構成例を示す図である。It is a figure which shows the detailed structural example of DB integrated server and a data source. 従来と本実施形態とを対比して実行計画を説明する図である。It is a figure explaining the execution plan by contrasting the conventional and this embodiment. 実行計画の作成・実行計画の送信・実行計画の実行におけるDB統合サーバとデータソースとの関係を示す図である。It is a figure which shows the relationship between DB integration server and a data source in execution plan creation, execution plan transmission, and execution plan execution. DB統合サーバにおける処理の流れを示すフローチャートである。It is a flowchart which shows the flow of a process in DB integrated server. 図5に示すフローチャートに沿った処理内容を説明する図である。It is a figure explaining the processing content along the flowchart shown in FIG. 小さいテーブルの実行計画の作成を説明する図である。It is a figure explaining preparation of the execution plan of a small table. 大きいテーブルの実行計画の作成を説明する図である。It is a figure explaining preparation of the execution plan of a big table.

以下、本発明の一実施の形態について、図面を参照して説明する。尚、各図において同一箇所については同一の符号を付すとともに、重複した説明は省略する。   Hereinafter, an embodiment of the present invention will be described with reference to the drawings. In the drawings, the same portions are denoted by the same reference numerals, and redundant description is omitted.

まず、本実施形態で用いる主要な用語について説明する。   First, main terms used in the present embodiment will be described.

「クエリ」とは、データが格納されたデータベースから検索結果としてのデータを取り出すための“問い合わせ”をいう。   “Query” refers to an “inquiry” for retrieving data as a search result from a database in which data is stored.

本実施形態においては、異種のデータベースに接続するデータソースに対して結合検索を実行するクライアント・サーバ型のデータベースシステムであって、データベース統合サーバ(以下、DB統合サーバという)は、クライアント側から要求されたクエリを解析し、データソース側からの転送データが少なくて済むように、データソース側における検索の実行計画を生成し、DB統合サーバにおける結合検索結果の統合処理をより高速化するものである。   In the present embodiment, a client-server type database system that performs a join search on a data source connected to a heterogeneous database, and a database integration server (hereinafter referred to as a DB integration server) is requested from the client side. This analysis is performed to generate a search execution plan on the data source side so that less data is transferred from the data source side, and to speed up the integration processing of join search results on the DB integration server. is there.

図1は、本発明の実施形態に係るデータベースシステムの概略構成を示すブロック図である。この装置は汎用のコンピュータ(例えばパーソナルコンピュータ(PC)等)と、同コンピュータ上で動作するソフトウェアとを用いて実現される。コンピュータとしては、CAD(Computer Aided Design)やCAE(Computer Aided Engineering)に好適なエンジニアリングワークステーション(EWS)等も含む。本実施形態はこのようなコンピュータにおいて、実行計画に沿ってデータを取り出すためのオブジェクトである少なくとも2つの異種のデータソースを有するデータベースシステムに、クライアントから要求されるクエリを受け付ける機能と、クエリを解釈し、複数のデータソースにおける検索の実行計画を生成して当該実行計画をそれぞれに送信する機能と、各データソースは、それぞれが管理するデータを呼び出して異種のデータソース間で共通利用するための手順やデータ形式を定める機能と、異種のデータソースに対して、手順やデータ形式を使用して検索を実行させる機能と、相互に通信可能に構成され、検索条件のやりとりを行うとともに、各データソースにおける検索の実行計画が、通信を含むように生成させる機能と、を実現させるためのデータベースシステム用プログラムとして実施することもできる。   FIG. 1 is a block diagram showing a schematic configuration of a database system according to an embodiment of the present invention. This apparatus is realized using a general-purpose computer (for example, a personal computer (PC) or the like) and software operating on the computer. The computer includes an engineering workstation (EWS) suitable for CAD (Computer Aided Design) and CAE (Computer Aided Engineering). In this embodiment, in such a computer, a database system having at least two different types of data sources, which are objects for retrieving data in accordance with an execution plan, and a function for receiving a query requested by a client, and interpreting the query And a function for generating an execution plan for a search in a plurality of data sources and transmitting the execution plan to each of the data sources, and for each data source to call data managed by each data source and share it among different data sources A function for defining procedures and data formats, a function for executing searches using procedures and data formats for dissimilar data sources, and a structure that can communicate with each other. The execution plan of the search at the source generates a function including communication. It can also be implemented as a program database system for.

図1に示すように、本実施形態に係るデータベースシステム1は、主として、アプリケーション10と、DB統合サーバ20と、複数のデータソース30と、複数の統合サーバ用データ変換部40と、複数のデータソース用API50から構成されている。データソース30と、統合サーバ用データ変換部40と、データソース用API50は、それぞれ組になっている。   As shown in FIG. 1, the database system 1 according to this embodiment mainly includes an application 10, a DB integration server 20, a plurality of data sources 30, a plurality of integrated server data conversion units 40, and a plurality of data. It consists of a source API 50. The data source 30, the integrated server data conversion unit 40, and the data source API 50 are in pairs.

アプリケーション10は、クライアントから要求されるクエリを受け付けるものである。アプリケーション10で受け付けたクエリは、DB統合サーバ20に送信される。   The application 10 receives a query requested from a client. The query received by the application 10 is transmitted to the DB integration server 20.

DB統合サーバ20は、アプリケーション10から送信されるクエリをパース(解釈)し、データソース側からの転送データが少なくて済むように、各データソース30における検索の実行計画を生成し、各データソース30に送る。DB統合サーバ20の詳細構成例、実行計画の詳細については後述する。   The DB integration server 20 parses (interprets) the query transmitted from the application 10 and generates a search execution plan in each data source 30 so that less data is transferred from the data source side. Send to 30. A detailed configuration example of the DB integration server 20 and details of the execution plan will be described later.

データソース30は、検索するデータベース、例えば、リレーショナルデータベースに接続して、実行計画に沿ったデータを取り出すためのオブジェクトである。データベースは、データソースAPIを持ち、APIを通じて入力された条件に応じて結果を返すシステムであれば良い。例えば、KVS(キーバリューストア)のデータベースやEXCELなどである。   The data source 30 is an object for connecting to a database to be searched, for example, a relational database, and retrieving data according to the execution plan. The database may be any system that has a data source API and returns a result according to a condition input through the API. For example, KVS (Key Value Store) database or EXCEL.

データソース30をセットアップするには、データベースに接続するためのドライバ名や、名前を付けられたデータベースの情報として、例えばデータベースの種類やサイズ、格納場所、ログオンやパスワード等を指定する。データソース30の詳細構成例については後述する。   In order to set up the data source 30, for example, the type and size of the database, the storage location, the logon and the password are specified as the driver name for connecting to the database and the information of the named database. A detailed configuration example of the data source 30 will be described later.

統合サーバ用データ変換部40は、DB統合サーバ20と通信し、データソース30に対して、データソース用API50を使用して検索を実行させる機能を持っている。統合サーバ用データ変換部40同士は、相互に通信可能に構成され、検索条件のやりとりを行う。統合サーバ用データ変換部40は、ネットワーク通信を必要とせずにアクセスできるようデータソース30と同じシステムにインストールされ、データソース30間の仕様上の差異を吸収する機能を果たす。   The integrated server data conversion unit 40 communicates with the DB integration server 20 and has a function of causing the data source 30 to execute a search using the data source API 50. The integrated server data conversion units 40 are configured to communicate with each other and exchange search conditions. The integrated server data converter 40 is installed in the same system as the data source 30 so that it can be accessed without requiring network communication, and functions to absorb differences in specifications between the data sources 30.

データソース用API50は、データソース30が管理するデータを呼び出して利用するための手順やデータ形式を定めた規約である。   The data source API 50 is a rule that defines a procedure and data format for calling and using data managed by the data source 30.

図2は、DB統合サーバ20とデータソース30の詳細な構成例を示す図である。図2に示すように、DB統合サーバ20は、プランナ21、計画実行部22、送受信部23を備えている。プランナ21は、SQL、及びスキーマ情報、データソース情報を保持する。スキーマ情報は、例えば、データテーブルの仕様等である。データソース情報は、各データソースの仕様等の情報である。プランナ21は、SQL、及びスキーマ情報、データソース情報を参照して、データソース側からの転送データが少なくて済むように、各データソースに対する実行計画を作成する。   FIG. 2 is a diagram illustrating a detailed configuration example of the DB integration server 20 and the data source 30. As illustrated in FIG. 2, the DB integration server 20 includes a planner 21, a plan execution unit 22, and a transmission / reception unit 23. The planner 21 holds SQL, schema information, and data source information. The schema information is, for example, data table specifications. The data source information is information such as specifications of each data source. The planner 21 refers to the SQL, schema information, and data source information, and creates an execution plan for each data source so that less data is transferred from the data source side.

送受信部23は、DB統合サーバ20とデータソース30間で指令やデータの送受信を行う。   The transmission / reception unit 23 transmits / receives commands and data between the DB integration server 20 and the data source 30.

計画実行部22は、プランナ21から各データソース30に対する実行計画を受け取り、送受信部23に送信する。さらに、送受信部23を介して受け取った各データソースにおける検索結果の統合処理を実行し、アプリケーション10に返す機能を果たす。尚、クエリを解析した結果、データテーブルが単数、あるいはデータソースが単数、あるいはデータソース30の構成が統合サーバ用データ変換部40やデータソース用API50を備えていない場合には、計画実行部22は、従来通りの検索結果の統合処理を実行し、アプリケーション10に返すのが好適である。   The plan execution unit 22 receives an execution plan for each data source 30 from the planner 21 and transmits it to the transmission / reception unit 23. Furthermore, the search result integration processing for each data source received via the transmission / reception unit 23 is executed and returned to the application 10. As a result of analyzing the query, if the data table is singular, the data source is singular, or the configuration of the data source 30 does not include the integrated server data conversion unit 40 or the data source API 50, the plan execution unit 22 It is preferable to execute the conventional search result integration processing and return it to the application 10.

また、図2に示すように、データソース30は、送受信部31と、計画実行部32を備えている。送受信部31は、送受信部23を介してDB統合サーバ20から実行計画を受信する。さらに、送受信部31は、実行計画内での転送、受信命令の実施を行う。また、送受信部31は、送受信部23を介してDB統合サーバ20へ実行計画の実行結果を送信する。   As shown in FIG. 2, the data source 30 includes a transmission / reception unit 31 and a plan execution unit 32. The transmission / reception unit 31 receives the execution plan from the DB integration server 20 via the transmission / reception unit 23. Further, the transmission / reception unit 31 performs transfer and reception commands within the execution plan. Further, the transmission / reception unit 31 transmits the execution plan execution result to the DB integration server 20 via the transmission / reception unit 23.

計画実行部32は、送受信部31で受信したDB統合サーバ20からの実行計画を受け取り、実行計画を実施する。上述したように、実行計画の実行に際しては、データソース用API50を使用する。   The plan execution unit 32 receives the execution plan from the DB integration server 20 received by the transmission / reception unit 31 and executes the execution plan. As described above, the data source API 50 is used to execute the execution plan.

<実行計画>
クエリを解釈した実行計画について説明する。図3は、従来と本実施形態とを対比して実行計画を説明する図である。図3(a)は、従来のクエリの解釈を説明する図である。図3(b)は、本実施形態における実行計画を説明する図である。図3(a)に示すSELECT文は、x2=y2 およびy3=1を満たすことを条件に、データソース X.tttからx1を抽出し、データソースY.sss からy1を抽出せよ、とのクエリを表している。係るクエリの実行計画は、y3=1の条件を満たすy3を取得し、x2=y2の条件を満たすy2、x2を取得し、x1を取得し、y1を取得し、x1およびy1を結果とする処理を、全てのデータについてチェックするものである。一方、図3(b)に示すクエリの実行計画は、データを送受信するように命令を変更する。すなわち、y3=1の条件を満たすy3を取得し、y1、y2を取得し、y1、y2をデータソース Xに転送し、データソースY内の全てのデータについてチェックする。データソース Xでは、受信したy1、y2をr1、r2に書き換え、x2=r2の条件を満たすx2を取得し、x1を取得し、実行結果x1、r1を、DB統合サーバに転送し、データソースX 内の全てのデータについてチェックするものである。
<Execution plan>
Explain the execution plan that interpreted the query. FIG. 3 is a diagram for explaining the execution plan by comparing the conventional example with the present embodiment. FIG. 3A is a diagram for explaining conventional query interpretation. FIG. 3B is a diagram for explaining an execution plan in the present embodiment. The SELECT statement shown in Fig. 3 (a) is a query that extracts x1 from the data source X.ttt and y1 from the data source Y.sss on condition that x2 = y2 and y3 = 1 are satisfied. Represents. The query execution plan acquires y3 that satisfies the condition of y3 = 1, acquires y2 and x2 that satisfy the condition of x2 = y2, acquires x1, acquires y1, and results in x1 and y1 The process is to check all data. On the other hand, the query execution plan shown in FIG. 3B changes the instruction to transmit and receive data. That is, y3 satisfying the condition of y3 = 1 is obtained, y1 and y2 are obtained, y1 and y2 are transferred to the data source X, and all data in the data source Y are checked. Data source X rewrites received y1 and y2 to r1 and r2, obtains x2 that satisfies the condition of x2 = r2, obtains x1, transfers the execution results x1 and r1 to the DB integration server, Check all data in X.

実行計画の作成においては、データソースの情報、各データソースが管理するテーブルデータのデータ数に関するメタデータを参考にして、テーブル間の大小関係を決定する。SQL文をテーブル毎に分解し、小さいテーブルの実行計画と大きいテーブルの実行計画をそれぞれ作成する。実行結果の転送量を少なくするため、小さいテーブルのデータソースでの実行結果を大きいテーブルのデータソース側に転送するように計画する。   In creating an execution plan, the size relationship between tables is determined with reference to data source information and metadata related to the number of data items of table data managed by each data source. The SQL statement is decomposed for each table, and an execution plan for a small table and an execution plan for a large table are created. In order to reduce the transfer amount of the execution result, it is planned to transfer the execution result in the data source of the small table to the data source side of the large table.

図4は、実行計画の作成・実行計画の送信・実行計画の実行におけるDB統合サーバ20とデータソース30との関係を示す図である。図4に示すように、DB統合サーバ20は、アプリケーション10から送られたSQL文に基づいて実行計画を作成する。DB統合サーバは、作成した実行計画を、各データソースに送る。データソースYは、実行計画を実行し、実行結果y1、y2を、データソース Xに転送する。データソースXは、転送されたy1、y2をr1、r2に書き換え、実行計画を実行する。データソースXは、実行結果x1、r1を、DB統合サーバに転送する。   FIG. 4 is a diagram illustrating a relationship between the DB integration server 20 and the data source 30 in execution plan creation, execution plan transmission, and execution plan execution. As shown in FIG. 4, the DB integration server 20 creates an execution plan based on the SQL statement sent from the application 10. The DB integration server sends the created execution plan to each data source. The data source Y executes the execution plan and transfers the execution results y1 and y2 to the data source X. The data source X rewrites the transferred y1 and y2 to r1 and r2, and executes the execution plan. The data source X transfers the execution results x1 and r1 to the DB integration server.

次に、以上のように構成されたDB統合サーバ20における処理の流れについて詳述する。図5は、DB統合サーバ20における処理の流れを示すフローチャートである。図6は、図5に示すフローチャートに沿った処理内容を説明する図である。   Next, the flow of processing in the DB integrated server 20 configured as described above will be described in detail. FIG. 5 is a flowchart showing the flow of processing in the DB integration server 20. FIG. 6 is a diagram for explaining the processing contents along the flowchart shown in FIG.

まず、SQL文を入力し、パースする。SQL文に含まれるテーブル情報を取得する(ステップS51)。図6(a)のX.ttt、Y.sss は、テーブル情報を説明するもので、データソース Xはtttと名付けたテーブルを持ち、データソースYはsssと名付けたテーブルを持つことを示している。   First, an SQL sentence is input and parsed. Table information included in the SQL sentence is acquired (step S51). X.ttt and Y.sss in FIG. 6 (a) are used to explain table information. Data source X has a table named ttt, and data source Y has a table named sss. Yes.

次に、全テーブル情報のデータソースを分析する(ステップS52)。仮に、複数のデータソース30のうちの一部のデータソースが、統合サーバ用データ変換部40やデータソース用API50を備えておらず、本実施形態に係るデータソースの構成でない場合には、従来の統合エンジンの仕組みで動くようにするのが好適である。   Next, the data source of all table information is analyzed (step S52). If some data sources of the plurality of data sources 30 do not include the integrated server data conversion unit 40 or the data source API 50 and are not configured as the data source according to the present embodiment, the conventional data source It is preferable to work with the mechanism of the integrated engine.

次に、テーブル間の大小関係を、テーブルと条件文に基づいて決定する(ステップS53)。図6(a)に示す例ではデータソースYを小さいと判断し、データソースXとデータソースYに関する部分として、x2=y2 and y3=1を抜き出す。   Next, the magnitude relationship between the tables is determined based on the table and the conditional statement (step S53). In the example shown in FIG. 6A, it is determined that the data source Y is small, and x2 = y2 and y3 = 1 are extracted as the portions related to the data source X and the data source Y.

続いて、SQL文をテーブル毎に分解する(ステップS54)。まず、小さいと判断したデータソースYに対して分解する。図6(b)に示す例では、y2=x2に対して、データソースYだけでは完結しないので、y2をデータソースXに送るために、y2は条件からカラムに変更する。データソースYに関する部分だけを抜き出すと、図6(c)に示すようになる。続いて、大きいと判断したデータソースX に対して分解する。ここでは、図6(d)に示すように、条件部のyのみに関する条件 y3=1 は除外する。さらに、図6(e)に示すように、データソースYについて、テーブルY.sssを受信する結果をRESとし、y1、y2をRESから受け取る意味で r1、r2にする。   Subsequently, the SQL sentence is decomposed for each table (step S54). First, the data source Y determined to be small is decomposed. In the example shown in FIG. 6B, since y2 = x2 is not completed only by the data source Y, in order to send y2 to the data source X, y2 is changed from a condition to a column. If only the portion related to the data source Y is extracted, it becomes as shown in FIG. Subsequently, the data source X determined to be large is decomposed. Here, as shown in FIG. 6D, the condition y3 = 1 relating only to y in the condition part is excluded. Further, as shown in FIG. 6E, for the data source Y, the result of receiving the table Y.sss is RES, and y1 and y2 are r1 and r2 in the meaning of receiving from the RES.

次に、小さいテーブルの実行計画を作成する(ステップS55)。ここでの実行計画は、小さいテーブルの実行計画の実行結果を、大きいテーブルのデータソースXに送付するように組む。図7は、小さいテーブルの実行計画の作成を説明する図である。   Next, an execution plan for a small table is created (step S55). The execution plan here is configured so that the execution result of the execution plan of the small table is sent to the data source X of the large table. FIG. 7 is a diagram for explaining the creation of an execution plan for a small table.

次に、大きいテーブルの実行計画を作成する(ステップS56)。ここでは、大きいテーブルの実行計画を、最終結果としてDB統合サーバに送付するように組む。図8は、大きいテーブルの実行計画の作成を説明する図である。   Next, an execution plan for a large table is created (step S56). Here, we plan to send an execution plan for a large table to the DB integrated server as the final result. FIG. 8 is a diagram illustrating creation of an execution plan for a large table.

次に、各データソースに実行計画を転送する(ステップS57)。   Next, the execution plan is transferred to each data source (step S57).

続いて、実行結果をデータソースXから受信する(ステップS58)。   Subsequently, the execution result is received from the data source X (step S58).

次に、受け取った各データソースにおける検索結果の統合処理を実行し、アプリケーション10に返して(ステップS59)、DB統合サーバ20における処理を終了する。   Next, integration processing of search results in each received data source is executed and returned to the application 10 (step S59), and the processing in the DB integration server 20 is terminated.

以上説明したように、本実施形態によれば、結合検索結果の統合処理をより高速化することができる。   As described above, according to the present embodiment, it is possible to further speed up the combined search result integration process.

本発明のいくつかの実施形態を説明したが、これらの実施形態は、例として提示したものであり、発明の範囲を限定することは意図していない。これら新規な実施形態は、その他の様々な形態で実施されることが可能であり、発明の要旨を逸脱しない範囲で、種々の省略、置き換え、変更を行うことができる。これら実施形態やその変形は、発明の範囲や要旨に含まれるとともに、特許請求の範囲に記載された発明とその均等の範囲に含まれる。   Although several embodiments of the present invention have been described, these embodiments are presented by way of example and are not intended to limit the scope of the invention. These novel embodiments can be implemented in various other forms, and various omissions, replacements, and changes can be made without departing from the scope of the invention. These embodiments and modifications thereof are included in the scope and gist of the invention, and are included in the invention described in the claims and the equivalents thereof.

1・・・データベースシステム
10・・・アプリケーション
20・・・DB統合サーバ
21・・・プランナ
22・・・計画実行部
23・・・送受信部
30・・・データソース
31・・・送受信部
32・・・計画実行部
40・・・統合サーバ用データ変換部
50・・・データソース用API
DESCRIPTION OF SYMBOLS 1 ... Database system 10 ... Application 20 ... DB integration server 21 ... Planner 22 ... Plan execution part 23 ... Transmission / reception part 30 ... Data source 31 ... Transmission / reception part 32- ..Plan execution unit 40 ... Integrated server data conversion unit 50 ... Data source API

Claims (6)

クライアントから要求されるクエリを受け付けるアプリケーションと、
前記アプリケーションから送信されるクエリを解釈し、複数のデータソースにおける検索の実行計画を生成して当該実行計画をそれぞれに送信するDB統合サーバと、
前記実行計画に沿ってデータを取り出すためのオブジェクトである、少なくとも2つの異種のデータソースとを有するデータベースシステムであって、
各データソースは、それぞれが管理するデータを呼び出して異種のデータソース間で共通利用するための手順やデータ形式を定めた規約である異種のデータソース用APIと、
前記DB統合サーバと通信し、異種のデータソースに対して、前記データソース用APIを使用して検索を実行させる機能を持つ統合サーバ用データ変換部とを備えて、前記統合サーバ用データ変換部同士が相互に通信可能に構成され、検索条件のやりとりを行うとともに、
前記DB統合サーバは、各データソースにおける検索の実行計画が、前記統合サーバ用データ変換部同士の通信を含むように生成するもので、前記クエリ、及びスキーマ情報、データソース情報を保持し、前記クエリ、スキーマ情報およびデータソース情報を参照して、前記データソース側からの転送データが少なくて済むように、前記データソースに対する実行計画を作成するプランナと、
前記DB統合サーバと前記データソース間で指令やデータの送受信を行う第1の送受信部と、
前記プランナから前記データソースに対する実行計画を受け取って前記第1の送受信部に送信するとともに、前記第1の送受信部を介して受け取った前記データソースにおける検索結果の統合処理を実行し、前記アプリケーションに返す機能を果たす計画実行部とを備え、
前記データソースは、
前記第1の送受信部を介して前記DB統合サーバから実行計画を受信するとともに、実行計画内での転送、受信命令の実施を行い、前記第1の送受信部を介して前記DB統合サーバへ実行計画の実行結果を送信する第2の送受信部と、
前記第2の送受信部で受信した前記DB統合サーバからの実行計画を受け取り、前記データソース用APIを使用して、実行計画を実施する計画実行部を備えるデータベースシステム。
An application that accepts queries requested by clients,
A DB integration server that interprets a query sent from the application, generates a search execution plan in a plurality of data sources, and sends the execution plan to each of the DB integration server;
A database system having at least two disparate data sources that are objects for retrieving data in accordance with the execution plan;
Each data source is an API for different types of data sources, which is a protocol that defines procedures and data formats for calling data managed by each of the data sources and sharing them among different types of data sources,
An integrated server data conversion unit that communicates with the DB integration server and has a function of executing a search with respect to different data sources using the data source API. They are configured to communicate with each other, exchange search conditions,
The DB integration server generates the search execution plan in each data source so as to include communication between the data conversion units for the integration server, holds the query, schema information, and data source information, A planner that creates an execution plan for the data source by referring to the query, schema information, and data source information so that less data is transferred from the data source.
A first transmission / reception unit for transmitting / receiving commands and data between the DB integration server and the data source;
An execution plan for the data source is received from the planner and transmitted to the first transmission / reception unit, and an integration process of search results in the data source received via the first transmission / reception unit is executed to the application. A plan execution unit that performs the function of returning,
The data source is
Receives an execution plan from the DB integration server via the first transmission / reception unit, performs transfer within the execution plan, executes a reception command, and executes the execution plan to the DB integration server via the first transmission / reception unit A second transmission / reception unit for transmitting the execution result of the plan;
A database system comprising a plan execution unit that receives an execution plan from the DB integration server received by the second transmission / reception unit and executes the execution plan by using the data source API.
前記スキーマ情報は、データテーブルの仕様であり、前記データソース情報は、各データソースの仕様の情報である請求項1に記載のデータベースシステム。   The database system according to claim 1, wherein the schema information is a specification of a data table, and the data source information is information of a specification of each data source. 前記データベースは、リレーショナルデータベースである請求項1又は請求項2に記載のデータベースシステム。   The database system according to claim 1, wherein the database is a relational database. 前記実行計画は、前記データソースの情報および前記データソースが管理するテーブルデータのデータ数に関するメタデータに基づいてテーブル間の大小関係を決定し、小さい前記テーブルの前記データソースでの実行結果を、大きい前記テーブルの前記データソース側に転送するように計画する請求項1乃至請求項3のいずれか1項に記載のデータベースシステム。   The execution plan determines the magnitude relationship between the tables based on the information on the data source and metadata on the number of data of the table data managed by the data source, and the execution result of the small table on the data source is determined. The database system according to any one of claims 1 to 3, wherein the database is planned to be transferred to the data source side of the large table. 前記データソースと、前記統合サーバ用データ変換部と、前記データソース用APIは、それぞれ組になっており、
前記統合サーバ用データ変換部は、前記データソースと同じシステムにインストールされ、前記データソース間の仕様上の差異を吸収する機能を果たす請求項1乃至請求項4のいずれか1項に記載のデータベースシステム。
The data source, the integrated server data conversion unit, and the data source API are each in pairs,
The database according to any one of claims 1 to 4, wherein the integrated server data conversion unit is installed in the same system as the data source and functions to absorb a difference in specifications between the data sources. system.
実行計画に沿ってデータを取り出すためのオブジェクトである少なくとも2つの異種のデータソースを有するデータベースシステムに、
アプリケーションが、クライアントから要求されるクエリを受け付ける機能と、
DB統合サーバが、前記クエリを解釈し、複数のデータソースにおける検索の実行計画を生成して当該実行計画をそれぞれに送信する機能と、
各データソースが、それぞれが管理するデータを呼び出して異種のデータソース間で共通利用するための手順やデータ形式を定める機能と、
前記各データソースが、前記DB統合サーバと通信し、前記異種のデータソースに対して、前記手順やデータ形式を使用して検索を実行させる機能と、
前記各データソースが、前記各データソース同士で相互に通信可能に構成され、検索条件のやりとりを行う機能と
前記DB統合サーバが、前記通信を含むように各データソースにおける検索の実行計画を生成させる機能と、
前記DB統合サーバが、前記クエリ、及びスキーマ情報、データソース情報を保持し、前記クエリ、スキーマ情報およびデータソース情報を参照して、前記データソース側からの転送データが少なくて済むように、前記データソースに対する実行計画を作成する機能と、
前記DB統合サーバが、前記実行計画を受け取るとともに、受け取った前記データソースにおける検索結果の統合処理を実行し、前記アプリケーションに返す機能と、
前記各データソースが、前記DB統合サーバから前記実行計画を受信するとともに、前記実行計画内での転送、受信命令の実施を行い、前記実行計画の実行結果を前記DB統合サーバへ送信させる機能と、
前記各データソースが、前記DB統合サーバから前記実行計画を受け取り、データソース用APIを使用して、前記実行計画を実施する機能と、
を実現させるためのデータベースシステム用プログラム。
A database system having at least two disparate data sources that are objects for retrieving data along an execution plan,
The application accepts queries requested by clients,
A function of the DB integration server interpreting the query, generating a search execution plan in a plurality of data sources, and transmitting the execution plan to each;
A function for each data source to call up data managed by each data source and to define a procedure and data format for common use among different data sources,
A function for each data source to communicate with the DB integration server, and to perform a search for the heterogeneous data source using the procedure or data format;
Each data source is configured to be able to communicate with each other, and a function for exchanging search conditions.
A function of causing the DB integration server to generate a search execution plan in each data source so as to include the communication ;
The DB integration server holds the query, schema information, and data source information, and refers to the query, schema information, and data source information so that less data is transferred from the data source side. The ability to create an execution plan for the data source,
The DB integration server receives the execution plan, executes a search result integration process in the received data source, and returns it to the application;
A function for each data source to receive the execution plan from the DB integration server, perform transfer within the execution plan, execute a reception command, and transmit the execution result of the execution plan to the DB integration server; ,
Each data source receives the execution plan from the DB integration server, and executes the execution plan using a data source API;
A database system program for realizing
JP2015144513A 2015-07-22 2015-07-22 Database system and database system program Active JP6328078B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2015144513A JP6328078B2 (en) 2015-07-22 2015-07-22 Database system and database system program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2015144513A JP6328078B2 (en) 2015-07-22 2015-07-22 Database system and database system program

Publications (2)

Publication Number Publication Date
JP2017027325A JP2017027325A (en) 2017-02-02
JP6328078B2 true JP6328078B2 (en) 2018-05-23

Family

ID=57946101

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2015144513A Active JP6328078B2 (en) 2015-07-22 2015-07-22 Database system and database system program

Country Status (1)

Country Link
JP (1) JP6328078B2 (en)

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5596744A (en) * 1993-05-20 1997-01-21 Hughes Aircraft Company Apparatus and method for providing users with transparent integrated access to heterogeneous database management systems
JP2003323443A (en) * 2002-05-02 2003-11-14 Nippon Telegr & Teleph Corp <Ntt> Integrated retrieving method and device utilizing inquiry optimization, program and recording medium
US7660805B2 (en) * 2003-12-23 2010-02-09 Canon Kabushiki Kaisha Method of generating data servers for heterogeneous data sources
JP4227033B2 (en) * 2004-01-20 2009-02-18 富士通株式会社 Database integrated reference device, database integrated reference method, and database integrated reference program
JP4331045B2 (en) * 2004-04-20 2009-09-16 株式会社エヌ・ティ・ティ・データ Database system and program
JP4181196B2 (en) * 2006-09-28 2008-11-12 株式会社東芝 SEARCH SYSTEM, SEARCH METHOD, AND INFORMATION MANAGEMENT DEVICE

Also Published As

Publication number Publication date
JP2017027325A (en) 2017-02-02

Similar Documents

Publication Publication Date Title
JP6050272B2 (en) Low latency query engine for APACHE HADOOP
CN110032604B (en) Data storage device, translation device and database access method
JP5940149B2 (en) Enhancing database query responses with data from external data sources
CN103064875B (en) A kind of spatial service data distributed enquiring method
CN104123374A (en) Method and device for aggregate query in distributed databases
US20090055370A1 (en) System and method for data warehousing and analytics on a distributed file system
US20070038658A1 (en) Communication optimization for parallel execution of user-defined table functions
JP2014194769A6 (en) Low latency query engine for APACHE HADOOP
WO2021218144A1 (en) Data processing method and apparatus, computer device, and storage medium
JP2018514012A (en) Querying data sources on the network
US11176044B2 (en) Systems and methods for implementing overlapping data caching for object application program interfaces
CN103136364A (en) Cluster database system and data query processing method thereof
CN102541631B (en) Execution plans with different driver sources in multiple threads
JP2012108635A (en) Distributed memory database system, front database server, data processing method and program
CN111198898B (en) Big data query method and big data query device
CN103823846A (en) Method for storing and querying big data on basis of graph theories
US20150269234A1 (en) User Defined Functions Including Requests for Analytics by External Analytic Engines
CN114356971A (en) Data processing method, device and system
US11048704B2 (en) System and method for integrating health information sources
JP2011100498A (en) System, method and software for retrieving information using a plurality of query languages
US10592506B1 (en) Query hint specification
CN114297224A (en) RDF-based heterogeneous data integration and query system and method
Banane et al. New approach based on model driven engineering for processing complex SPARQL queries on hive
US9047391B2 (en) Searching apparatus, searching method, and computer program product
US20210224271A1 (en) System and method for performing semantically-informed federated queries across a polystore

Legal Events

Date Code Title Description
A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20170721

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20170801

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20170927

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20171114

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20171212

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20180220

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20180307

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20180320

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20180417

R151 Written notification of patent or utility model registration

Ref document number: 6328078

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R151