[go: up one dir, main page]

JP2009043083A - Database connection system, database connection program, and database connection method - Google Patents

Database connection system, database connection program, and database connection method Download PDF

Info

Publication number
JP2009043083A
JP2009043083A JP2007208258A JP2007208258A JP2009043083A JP 2009043083 A JP2009043083 A JP 2009043083A JP 2007208258 A JP2007208258 A JP 2007208258A JP 2007208258 A JP2007208258 A JP 2007208258A JP 2009043083 A JP2009043083 A JP 2009043083A
Authority
JP
Japan
Prior art keywords
metadata
database
data
query
setting information
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.)
Pending
Application number
JP2007208258A
Other languages
Japanese (ja)
Inventor
Toshiyuki Kamiya
俊之 神谷
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.)
NEC Corp
Original Assignee
NEC 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 NEC Corp filed Critical NEC Corp
Priority to JP2007208258A priority Critical patent/JP2009043083A/en
Publication of JP2009043083A publication Critical patent/JP2009043083A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

<P>PROBLEM TO BE SOLVED: To provide a database connection system capable of registering to a database metadata along with data to be written to the database by a processing module without altering the processing module. <P>SOLUTION: A setting information storage means 51 stores setting information which defines items of the metadate to be written to the database along with data in writing the data to the database. A metadata collecting means 52 requests metadata of the item defined by the setting information of a metadata holding means 54 for holding the metadata and collects the metadata from the metadata holding means 54. A write query conversion means 53 converts a query for instructing writing the data to the database into a query for instructing writing the data and the metadata of the item defined by the data and the setting information. <P>COPYRIGHT: (C)2009,JPO&INPIT

Description

本発明は、データベースの操作を行うデータベース接続システム、データベース接続用プログラムおよびデータベース接続方法に関する。   The present invention relates to a database connection system for performing database operations, a database connection program, and a database connection method.

インターネットの普及や企業内のデータ蓄積量の増大等によって、WWW(World-Wide Web)や既存の情報システムあるいは音声・画像等のデータを利用したデータ分析を行い、その結果を蓄積・管理するシステムが重要となってきた。   A system that performs data analysis using data such as WWW (World-Wide Web), existing information systems, or voice / images due to the spread of the Internet or an increase in the amount of data stored in the company, and stores and manages the results. Has become important.

図15は、本発明に関連するデータベース接続システムの例を示す説明図である。図15に例示するデータベース接続システムは、データベースシステム85を含み、また、アプリケーションプログラム81と、データベースアクセスモジュール82とが搭載されている。アプリケーションプログラム81とデータベースアクセスモジュール82はソフトウェアであり、実際にはデータベース接続システムがこれらのソフトウェアに従って動作するが、図15の説明では、便宜的にソフトウェアの動作として説明する。   FIG. 15 is an explanatory diagram showing an example of a database connection system related to the present invention. The database connection system illustrated in FIG. 15 includes a database system 85, and an application program 81 and a database access module 82 are installed. The application program 81 and the database access module 82 are software, and the database connection system actually operates according to these software. However, in the description of FIG.

データ分析を行うアプリケーションプログラム81は、WWWや既存の情報システムが保持するデータ、音声・画像データ等をデータベースシステム85に記録する。また、必要に応じて、処理の途中の中間データもデータベースシステム85に書き込んだり読み込んだりしながら、データの分析や抽出を行い、最終的に得られる結果をデータベースシステム85に書き込む。   The application program 81 that performs data analysis records data, audio / image data, and the like held by the WWW or an existing information system in the database system 85. Further, if necessary, intermediate data in the middle of processing is written and read into the database system 85 while analyzing and extracting data, and finally obtaining the result is written into the database system 85.

データベースアクセスモジュール82は、標準的なデータベース接続インタフェース83をアプリケーションプログラム81に提供する。また、データベースアクセスモジュール82は、データベース言語(例えばSQL)によるデータの書き込みや読み取り等のコマンドを、データベースシステム85に固有のプロトコルのコマンドに変換するライブラリ84を含む。   The database access module 82 provides a standard database connection interface 83 to the application program 81. The database access module 82 includes a library 84 that converts commands such as data writing and reading in a database language (for example, SQL) into commands of a protocol unique to the database system 85.

アプリケーションプログラム81は、データベースを読み書きする際、SQL等のデータベース言語によるデータベースの読み書きのコマンドをデータベースアクセスモジュール82に渡す。データベースアクセスモジュール82は、ライブラリ84によって、そのコマンドをデータベース固有のプロトコルのコマンドに変換し、データベースシステム85にデータの読み取りあるいは書き込みを行わせる。   When reading / writing the database, the application program 81 passes a database read / write command in a database language such as SQL to the database access module 82. The database access module 82 converts the command into a command of a protocol specific to the database by the library 84 and causes the database system 85 to read or write data.

一方、BI(Business Intelligence:ビジネスインテリジェンス)等と呼ばれるデータ分析システムが知られている。このデータ分析システムは、WWWや企業内のデータベース等の様々な情報源からデータを収集し、形態素解析、音声認識、データマイニング等の様々な処理を行うための各種処理モジュールによる分析を行い、処理モジュールによる分析により得られたデータをさらに横断的に分析し、分析結果を利用者に提供する。このようなデータ分析システムでは、所望の全ての情報分析を行うための処理モジュールを予め不足なく用意しておくことはできず、収集したデータに対して分析者の所望の分析を行うための処理モジュールを追加して、所望の分析を行えるように機能拡張することがある。   On the other hand, a data analysis system called BI (Business Intelligence) is known. This data analysis system collects data from various information sources, such as the WWW and corporate databases, and performs analysis by various processing modules for performing various processes such as morphological analysis, voice recognition, and data mining. The data obtained by the module analysis is analyzed further across the board, and the analysis results are provided to the user. In such a data analysis system, a processing module for performing all desired information analysis cannot be prepared in advance, and a process for performing an analysis desired by the analyst on the collected data. Modules may be added to extend the functionality to perform the desired analysis.

このような横断的な分析を行う際には、分析結果のデータとともに、そのデータのメタデータを保持しておき、メタデータに基づいて適切なデータを選択的に利用する必要がある。メタデータは、分析結果(横断的な分析を行う前の処理モジュールによる分析結果)のデータに関連するデータである。   When performing such a cross-sectional analysis, it is necessary to retain the metadata of the data together with the data of the analysis result and selectively use appropriate data based on the metadata. The metadata is data related to the data of the analysis result (analysis result by the processing module before performing the cross-sectional analysis).

メタデータの例として、データの作成日時、分析結果のデータの元になったデータソースの情報、処理モジュールのパラメータ設定状態等が挙げられる。また、複数の処理モジュールを連携して分析結果を導いた場合には、どのような連携によって分析結果を得られたかという情報も、分析結果データの信頼性を確認するために必要なメタデータとなることがある。また、処理モジュールが搭載された装置の位置における雨量や周囲の音量等を収集する処理モジュールの場合には、その位置の情報もメタデータとなることがある。また、複数の同様な処理モジュールが複数人の利用者により利用されていたり、あるいは複数の装置(例えばパーソナルコンピュータ)で稼動している場合には、各処理モジュールを実行している装置名(例えばPC名)あるいはその装置を利用しているユーザ名もメタデータとなる。   Examples of metadata include data creation date and time, data source information that is the source of analysis result data, and parameter setting statuses of processing modules. In addition, when the analysis results are derived by linking multiple processing modules, the information on how the analysis results were obtained is also the metadata necessary to confirm the reliability of the analysis result data. May be. In addition, in the case of a processing module that collects rainfall, surrounding sound volume, and the like at the position of the apparatus on which the processing module is mounted, the information on the position may also be metadata. In addition, when a plurality of similar processing modules are used by a plurality of users or are operated by a plurality of devices (for example, personal computers), the name of the device executing each processing module (for example, PC name) or the name of the user who uses the device is also metadata.

また、非特許文献1には、アプリケーションプログラムを変更することなしに、データベースシステムを異なるデータベースシステムに置き換える方式が記載されている。非特許文献1に記載された方式では、アプリケーションプログラムを変更せずに、アプリケーションプログラムが発行したSQLを新たなデータベースシステム用のSQLに変換する。この変換は、アプリケーションプログラムをデータベースシステムに接続させるデータベース接続層において行われる。また、SQLの変換の態様として、固有の予約語を変換する予約語変換、予約語だけでなくパラメータを含むロジックを変換するロジック変換、プリペアド変換が非特許文献1に記載されている。非特許文献1に記載された方式では、アプリケーションプログラムが発行したSQLを変換することによって、アプリケーションプログラム自体を変更することなく新たなデータベースシステムへの置き換えを実現することができる。   Non-Patent Document 1 describes a method for replacing a database system with a different database system without changing an application program. In the method described in Non-Patent Document 1, the SQL issued by the application program is converted into the SQL for a new database system without changing the application program. This conversion is performed in the database connection layer that connects the application program to the database system. Non-Patent Document 1 describes reserved word conversion for converting a unique reserved word, logic conversion for converting a logic including a parameter as well as a reserved word, and prepared conversion as SQL conversion modes. In the method described in Non-Patent Document 1, conversion to a new database system can be realized without changing the application program itself by converting the SQL issued by the application program.

藤山健一郎,喜田弘司,中村暢達、「データベース接続層におけるSQL変換によるDBMS置き換え支援」、情報処理学会全国大会講演論文集、VOL.69th,NO.1,PAGE.1.357‐1.358,2007年Kenichiro Fujiyama, Koji Kida, Satoshi Nakamura, “DBMS replacement support by SQL transformation in database connection layer”, IPSJ National Conference Proceedings, VOL. 69th, NO. 1, PAGE. 1.357-1.358, 2007

上述のように、BI等のデータ分析システムにおいて処理モジュールの分析結果に対してさらに横断的な分析を行うためには、分析結果のデータとともに、そのデータのメタデータを保持し、メタデータに基づいて適切なデータを選択的に利用する必要がある。ここで、処理モジュールは、各種アプリケーションプログラム向けに個別に開発された処理モジュールであることが一般的であり、アプリケーションプログラムの目的に応じた必要なデータのみを処理対象としている。また、処理モジュールによって読み書きされるデータベースのスキーマは予め決まっている。これらのことから、分析結果のデータとともにメタデータもデータベースに登録するように処理モジュールを改造しなければ、処理モジュールによる分析結果にメタデータを付加することはできない。しかし、処理モジュールとしては、実行モジュール(実行ファイル)のみが提供されるので、分析者自身が処理モジュールのソースコードを見て処理モジュールを改造することはできない。   As described above, in order to perform a further cross-sectional analysis on the analysis result of the processing module in the data analysis system such as BI, the metadata of the data is held together with the analysis result data, and is based on the metadata. It is necessary to selectively use appropriate data. Here, the processing modules are generally processing modules developed individually for various application programs, and only necessary data corresponding to the purpose of the application program is processed. Further, the schema of the database read and written by the processing module is determined in advance. For these reasons, the metadata cannot be added to the analysis result by the processing module unless the processing module is modified so that the metadata along with the data of the analysis result is registered in the database. However, since only an execution module (execution file) is provided as a processing module, the analyst cannot view the processing module source code and modify the processing module.

また、非特許文献1に記載された方式は、処理モジュールを改造せずにクエリを変換する方式であるが、この変換は、予約語変換、ロジック変換等のような、クエリ内のデータベース言語の形式的な変換である。従って、元のクエリに含まれていないメタデータを、処理モジュールによる分析結果のレコードに追加して、そのレコードとともに同時に記録することはできない。   The method described in Non-Patent Document 1 is a method for converting a query without modifying a processing module. This conversion is performed by a database language in a query such as reserved word conversion or logic conversion. Formal conversion. Therefore, metadata that is not included in the original query cannot be added to the analysis result record by the processing module and recorded together with the record.

本発明は、処理モジュールを改造することなく、処理モジュールによってデータベースに書き込まれるデータとともにメタデータもデータベースに登録できるようにするデータベース接続システム、データベース接続用プログラムおよびデータベース接続方法を提供することを目的とする。   An object of the present invention is to provide a database connection system, a database connection program, and a database connection method that enable metadata to be registered in a database together with data written to the database by the processing module without modifying the processing module. To do.

本発明のデータベース接続システムは、データベースにデータを書き込む際に当該データとともにデータベースに書き込むメタデータの項目を定めた設定情報を記憶する設定情報記憶手段と、メタデータを保持するメタデータ保持手段に対して、設定情報で定められた項目のメタデータを要求して、前記メタデータ保持手段からメタデータを収集するメタデータ収集手段と、データベースへのデータの書き込みを指示するクエリを、当該データおよび設定情報で定められた項目のメタデータの書き込みを指示するクエリに変換する書き込みクエリ変換手段とを備えることを特徴とする。   The database connection system of the present invention has a setting information storage unit that stores setting information that defines metadata items to be written to the database together with the data when the data is written to the database, and a metadata holding unit that holds the metadata. Requesting metadata for the item defined in the setting information, collecting metadata from the metadata holding means, and a query for instructing data writing to the database, the data and the setting Write query conversion means for converting into a query for instructing writing of metadata of an item defined by information.

また、本発明のデータベース接続用プログラムは、データベースにデータを書き込む際に当該データとともにデータベースに書き込むメタデータの項目を定めた設定情報を記憶する設定情報記憶手段を備えるコンピュータに搭載されるデータベース接続用プログラムであって、前記コンピュータに、メタデータを保持するメタデータ保持手段に対して、設定情報で定められた項目のメタデータを要求して、前記メタデータ保持手段からメタデータを収集するメタデータ収集処理、およびデータベースへのデータの書き込みを指示するクエリを、当該データおよび設定情報で定められた項目のメタデータの書き込みを指示するクエリに変換する書き込みクエリ変換処理を実行させることを特徴とする。   Further, the database connection program of the present invention is a database connection program installed in a computer provided with setting information storage means for storing setting information defining metadata items to be written to the database together with the data when the data is written to the database. Metadata that collects metadata from the metadata holding unit by requesting metadata of an item defined by setting information from the metadata holding unit that holds metadata to the computer A collection query and a write query conversion process for converting a query instructing writing of data into a database into a query instructing writing of metadata of an item defined by the data and setting information are executed. .

また、本発明のデータベース接続方法は、データベースにデータを書き込む際に当該データとともにデータベースに書き込むメタデータの項目を定めた設定情報を記憶する設定情報記憶手段を備えたデータベース接続システムに適用されるデータベース接続方法であって、メタデータ収集手段が、メタデータを保持するメタデータ保持手段に対して、設定情報で定められた項目のメタデータを要求して、前記メタデータ保持手段からメタデータを収集し、書き込みクエリ変換手段が、データベースへのデータの書き込みを指示するクエリを、当該データおよび設定情報で定められた項目のメタデータの書き込みを指示するクエリに変換することを特徴とする。   The database connection method of the present invention is a database applied to a database connection system provided with setting information storage means for storing setting information that defines metadata items to be written to the database together with the data when the data is written to the database. A connection method, wherein the metadata collecting unit requests metadata of an item defined in the setting information from the metadata holding unit holding the metadata, and collects the metadata from the metadata holding unit The write query conversion means converts the query for instructing data writing to the database into a query for instructing to write metadata of items defined by the data and setting information.

本発明によれば、処理モジュールを改造せずに、処理モジュールによってデータベースに書き込まれるデータだけでなく、メタデータもデータベースに書き込むことができる。   According to the present invention, not only the data written to the database by the processing module but also the metadata can be written to the database without modifying the processing module.

以下、本発明の実施形態を図面を参照して説明する。
図1は、本発明のデータベース接続システムの例を示すブロック図である。本実施形態のデータベース接続システム10は、記憶装置11と、DBアクセス仮想化手段100と、DBアクセス手段200と、処理実行手段300と、実行制御手段400とを備える。また、データベース接続システム10は、データベース501を備えたデータベースシステム500に通信ネットワークを介して接続され、データベース501の操作を行う。また、データベースシステム500は、データベース管理システム(RDBMS。図示せず。)も備えている。なお、DBは、データベースを意味する。
Hereinafter, embodiments of the present invention will be described with reference to the drawings.
FIG. 1 is a block diagram showing an example of a database connection system of the present invention. The database connection system 10 of this embodiment includes a storage device 11, a DB access virtualization unit 100, a DB access unit 200, a process execution unit 300, and an execution control unit 400. The database connection system 10 is connected to a database system 500 including the database 501 via a communication network, and operates the database 501. The database system 500 also includes a database management system (RDBMS, not shown). DB means a database.

データベース接続システム10およびデータベースシステム500はそれぞれ、例えば、パーソナルコンピュータ等の情報処理装置によって実現される。   Each of the database connection system 10 and the database system 500 is realized by an information processing apparatus such as a personal computer, for example.

記憶装置11は、DBアクセス仮想化モジュール101と、データベースアクセスモジュール(以下、DBアクセスモジュールと記す。)201と、処理モジュール301と、実行制御モジュール401とを記憶する記憶装置である。これらの各モジュール101,201,301,401は、ソフトウェアである。DBアクセス仮想化手段100は、DBアクセス仮想化モジュール101に従って動作する。DBアクセス手段200は、DBアクセスモジュール201に従って動作する。処理実行手段300は、処理モジュール301に従って動作する。実行制御手段400は、実行制御モジュール401に従って動作する。   The storage device 11 is a storage device that stores a DB access virtualization module 101, a database access module (hereinafter referred to as a DB access module) 201, a processing module 301, and an execution control module 401. Each of these modules 101, 201, 301, 401 is software. The DB access virtualization unit 100 operates according to the DB access virtualization module 101. The DB access means 200 operates according to the DB access module 201. The process execution unit 300 operates according to the process module 301. The execution control unit 400 operates according to the execution control module 401.

データベース接続システム10の動作の概要について説明する。
処理モジュール301は、データベース501へのデータ書き込みまたはデータベース501からのデータ読み込みを伴う処理を処理実行手段300に実行させるためのソフトウェアモジュールである。また、記憶装置11は、複数種類の処理モジュール301を記憶していてもよい。実行制御モジュール401は、実行制御手段400に、処理モジュールの呼び出し制御(例えば、呼び出し順序の制御)を行わせるソフトウェアである。処理実行手段300は、実行制御手段400の制御に従って処理モジュール301を呼び出し、データベースへのデータの書き込みまたはデータベースからのデータの読み込みを行うためのクエリ(命令)を生成する。処理モジュール301は、データベース言語(例えばSQL)で記述したクエリを生成する。
An outline of the operation of the database connection system 10 will be described.
The processing module 301 is a software module that causes the processing execution unit 300 to execute processing involving data writing to the database 501 or data reading from the database 501. The storage device 11 may store a plurality of types of processing modules 301. The execution control module 401 is software that causes the execution control unit 400 to perform process module call control (for example, call order control). The process execution unit 300 calls the processing module 301 under the control of the execution control unit 400, and generates a query (command) for writing data into the database or reading data from the database. The processing module 301 generates a query described in a database language (for example, SQL).

DBアクセス仮想化手段100には、データベース501に書き込まれるデータとそのデータに追加すべきメタデータの項目との対応関係を示す設定情報が予め入力され、DBアクセス仮想化手段100はその設定情報を記憶する。そして、データを書き込むためのクエリを処理実行手段300が作成した場合、DBアクセス仮想化手段100は、予め記憶している設定情報を参照して、クエリで書き込みを指定されたデータだけでなく、そのデータに追加すべきメタデータもデータベース501に書き込むようにクエリを変換する。処理モジュール301によって書き込み指示されたデータとそのメタデータとが、変換後のクエリに基づいてデータベース501に書き込まれる。   The DB access virtualization unit 100 is preliminarily input with setting information indicating the correspondence between the data written in the database 501 and the metadata items to be added to the data. The DB access virtualization unit 100 stores the setting information. Remember. When the process execution unit 300 creates a query for writing data, the DB access virtualization unit 100 refers to the setting information stored in advance, and not only the data designated for writing by the query, The query is converted so that metadata to be added to the data is also written in the database 501. Data instructed to be written by the processing module 301 and its metadata are written to the database 501 based on the converted query.

処理モジュール301は、メタデータを用いずに処理を進めるための処理モジュールであり、処理モジュール301に従って動作する処理実行手段300は、データベースへのメタデータの書き込みを指示するクエリは生成しない。   The processing module 301 is a processing module for proceeding with processing without using metadata, and the processing execution means 300 that operates according to the processing module 301 does not generate a query that instructs writing of metadata to the database.

DBアクセス仮想化手段100は、データベース501からデータを読み込んだ場合、読み込んだ読み込みデータの中からメタデータを削除する。処理実行手段300は、メタデータが削除されたデータに基づいて処理モジュール301の目的の処理を行う。DBアクセス仮想化手段100はメタデータを削除することによって、処理と関係のないメタデータが処理実行手段300に送られることを防止する。   When the DB access virtualization unit 100 reads data from the database 501, the DB access virtualization unit 100 deletes metadata from the read data. The process execution unit 300 performs a target process of the processing module 301 based on the data from which the metadata has been deleted. The DB access virtualization unit 100 prevents the metadata unrelated to the process from being sent to the process execution unit 300 by deleting the metadata.

また、データベース501には、クエリで書き込みを指示されたデータとともにメタデータも書き込まれる。従って、BI等のデータ分析システム(図1において図示せず。)は、データベース501に記憶されたデータおよびメタデータを参照して、データの分析を行うことができる。   Also, metadata is written in the database 501 together with data instructed to be written by the query. Therefore, a data analysis system such as BI (not shown in FIG. 1) can perform data analysis with reference to data and metadata stored in the database 501.

次に、データベース接続システム10の各構成要素について説明する。
DBアクセス仮想化手段100は、設定情報が入力されるインタフェースを有し、そのインタフェースを介して入力された設定情報を予め記憶する。DBアクセス仮想化手段100は、データを書き込むためのクエリを処理実行手段300が生成すると、設定情報を参照し、クエリで指定されたデータだけでなくメタデータもデータベース501に書き込むように、クエリを変換する。また、実行制御手段400はメタデータを有しており、DBアクセス仮想化手段100はデータベース501に書き込むべきメタデータを実行制御手段400から収集する。DBアクセス仮想化手段100は、データ書き込みのためのクエリを変換すると、そのクエリをDBアクセス手段200に出力する。
Next, each component of the database connection system 10 will be described.
The DB access virtualization unit 100 has an interface through which setting information is input, and stores setting information input through the interface in advance. When the process execution unit 300 generates a query for writing data, the DB access virtualization unit 100 refers to the setting information, and writes the query to the database 501 in addition to the data specified by the query. Convert. Further, the execution control unit 400 has metadata, and the DB access virtualization unit 100 collects metadata to be written in the database 501 from the execution control unit 400. When the DB access virtualization unit 100 converts a query for writing data, the DB access virtualization unit 100 outputs the query to the DB access unit 200.

また、データベース501からデータを読み込むためのクエリを処理実行手段300が生成した場合、DBアクセス仮想化手段100は、そのクエリに対しては変換を行わずにDBアクセス手段200に出力する。この結果、データベース501からデータが読み出され、その結果がDBアクセスモジュール200から返ってくる。このとき、DBアクセス仮想化手段100は、データベース501から読み込んだ読み込みデータの中に、クエリの変換によって追加されたメタデータが含まれている場合には、そのメタデータを削除し、メタデータを取り除いた後のデータを処理実行手段300に返す。なお、読み込みデータの中にメタデータが含まれていなければ、DBアクセス仮想化手段100は、そのデータを処理実行手段300に返す。   When the process execution unit 300 generates a query for reading data from the database 501, the DB access virtualization unit 100 outputs the query to the DB access unit 200 without performing conversion. As a result, data is read from the database 501 and the result is returned from the DB access module 200. At this time, if the read data read from the database 501 includes metadata added by query conversion, the DB access virtualization unit 100 deletes the metadata and stores the metadata. The removed data is returned to the process execution means 300. If the read data does not include metadata, the DB access virtualization unit 100 returns the data to the process execution unit 300.

DBアクセス仮想化手段100は、これらの処理をDBアクセス仮想化モジュール101に従って実行する。DBアクセス仮想化モジュール101は、本発明のデータベース接続用プログラムである。   The DB access virtualization unit 100 executes these processes according to the DB access virtualization module 101. The DB access virtualization module 101 is a database connection program of the present invention.

DBアクセス手段200は、SQL等のデータベース言語で記述されたクエリがDBアクセス仮想化モジュール100から入力されると、そのクエリを、データベースシステム500において独自に定められているコマンドに書き換え、そのコマンドをデータベースシステム500に送信する。データベースシステム500は、データベースシステム500の種類に応じた独自のコマンドに従って、データの読み込みや書き込みを行う。   When a query written in a database language such as SQL is input from the DB access virtualization module 100, the DB access means 200 rewrites the query into a command uniquely defined in the database system 500, To the database system 500. The database system 500 reads and writes data according to a unique command corresponding to the type of the database system 500.

また、DBアクセス手段200がデータベースシステム500にコマンドを送信すると、データベースシステム500は、データの読み込みや書き込みを行い、その結果の値(コマンドに対する応答結果)をDBアクセス手段200に送信する。この応答結果も、データベースシステム500の独自の表現で記述されている。DBアクセス手段200は、データベースシステム500からこの応答結果を受信した場合、応答結果をデータベース言語による記述に書き換え、書き換えた結果をDBアクセス仮想化モジュール100に送る。   When the DB access unit 200 transmits a command to the database system 500, the database system 500 reads and writes data, and transmits a result value (response result to the command) to the DB access unit 200. This response result is also described in a unique expression of the database system 500. When receiving the response result from the database system 500, the DB access unit 200 rewrites the response result into a description in the database language, and sends the rewritten result to the DB access virtualization module 100.

DBアクセス手段200は、これらの書き換え処理を、DBアクセスモジュール201に従って実行する。DBアクセスモジュール201は、例えば、データベースシステム500に対応したJDBC(Java DataBase Connectivity)やODBC(Open DataBase Connectivity)である。なお、Javaは登録商標である。   The DB access unit 200 executes these rewrite processes according to the DB access module 201. The DB access module 201 is, for example, a JDBC (Java DataBase Connectivity) or an ODBC (Open DataBase Connectivity) corresponding to the database system 500. Java is a registered trademark.

処理実行手段300は、処理モジュール301に従って、データベース501へのデータの書き込みを指示するクエリ、またはデータベース501からのデータの読み込みを指示するクエリを生成する。また、処理実行手段300は、データベース501から読み込んだ読み込みデータ等を用いて、処理モジュール301の目的に応じた処理を実行する。例えば、データベース501から読み込んだデータからの情報抽出や、データの分析等を行う。この処理の内容は限定されない。また、処理実行手段300は、実行制御モジュール400から処理モジュール301の起動通知を受けると、通知された処理モジュール301に従って処理を実行する。そして、その処理を完了すると、処理実行手段300は、処理の完了を実行制御手段400に通知する。   The process execution unit 300 generates a query for instructing data writing to the database 501 or a query for instructing data reading from the database 501 in accordance with the processing module 301. Further, the process execution unit 300 executes a process according to the purpose of the processing module 301 using read data read from the database 501 and the like. For example, information extraction from data read from the database 501 and data analysis are performed. The content of this process is not limited. When the process execution unit 300 receives the activation notification of the process module 301 from the execution control module 400, the process execution unit 300 executes the process according to the notified process module 301. When the process is completed, the process execution unit 300 notifies the execution control unit 400 of the completion of the process.

処理モジュール301の例を以下に示す。処理モジュール301は、例えば、処理実行手段300に、データベース501からデータ(文)を順次読み込ませ、その文に対する形態素解析を実行させ、形態素解析の結果を新たなデータとしてデータベース501に書き込ませるソフトウェアモジュールであってもよい。また、処理モジュール301は、処理実行手段300に、インターネットを介してWebページを収集させ、そのWebページを新たなデータとしてデータベース501に書き込ませるソフトウェアモジュールであってもよい。また、処理モジュール301は、処理実行手段300に、ファイルを記憶しているパーソナルコンピュータ等の情報処理装置からファイルに関する情報を収集させ、その情報を新たなデータとしてデータベース501に書き込ませるソフトウェアモジュールであってもよい。また、処理モジュール301は、処理実行手段300に外気温を測定させ、その測定結果をデータベース501に書き込ませるソフトウェアモジュールであってもよい。   An example of the processing module 301 is shown below. The processing module 301 is, for example, a software module that causes the processing execution unit 300 to sequentially read data (sentences) from the database 501, execute morpheme analysis on the sentences, and write the morpheme analysis result to the database 501 as new data. It may be. The processing module 301 may be a software module that causes the processing execution unit 300 to collect Web pages via the Internet and write the Web pages as new data in the database 501. The processing module 301 is a software module that causes the processing execution unit 300 to collect information about a file from an information processing apparatus such as a personal computer that stores the file, and to write the information in the database 501 as new data. May be. The processing module 301 may be a software module that causes the processing execution unit 300 to measure the outside air temperature and writes the measurement result in the database 501.

実行制御モジュール401は、処理モジュールの連携を記述したり設定したりしたソフトウェアである。すなわち、実行制御モジュール401は、1つあるいは複数の処理モジュールの処理の順序を定めたソフトウェアである。実行制御モジュール401は、データベース接続システム10の利用者によって作成され、記憶装置11に記憶される。実行制御手段400は、実行制御モジュール401に従って、実行する処理モジュールの順序を制御する。例えば、実行制御手段400は、実行制御モジュール401に定められた順に、実行すべき処理モジュールを処理実行手段300に通知することによって、処理実行手段300に処理モジュールを順次、実行させる。   The execution control module 401 is software that describes or sets the cooperation of processing modules. That is, the execution control module 401 is software that defines the order of processing of one or a plurality of processing modules. The execution control module 401 is created by a user of the database connection system 10 and stored in the storage device 11. The execution control unit 400 controls the order of processing modules to be executed according to the execution control module 401. For example, the execution control unit 400 notifies the processing execution unit 300 of the processing modules to be executed in the order determined by the execution control module 401, thereby causing the processing execution unit 300 to sequentially execute the processing modules.

本システムの利用者は、1つの処理モジュールによって、あるいは複数の処理モジュールを連携することによって、意図した処理全体を行うアプリケーション(処理モジュールの組み合わせ)を定義する。利用者はこのアプリケーションにおける処理モジュールの実行順を定めた実行制御モジュール401を作成する。データベース接続システム10は、実行制御モジュール401を入力するためのインタフェースを備え、そのインタフェースを介して利用者によって実行制御モジュール401が入力されると、実行制御モジュール401を記憶装置11に記憶させる。   A user of this system defines an application (combination of processing modules) that performs the entire intended processing by one processing module or by linking a plurality of processing modules. The user creates an execution control module 401 that defines the execution order of the processing modules in this application. The database connection system 10 includes an interface for inputting the execution control module 401, and stores the execution control module 401 in the storage device 11 when the user inputs the execution control module 401 via the interface.

実行制御手段400は、実行制御モジュール401に従って、処理実行手段300に処理モジュールを順次、実行させる。例えば、実行制御手段400は、実行制御モジュール401に従ってある処理モジュール301の起動通知を処理実行手段300に送り、処理実行手段300にその処理を実行させる。処理実行手段300は通知された処理モジュール301の処理を完了すると、完了通知を実行制御手段400に送り、実行制御手段400は完了通知を受けると、次の処理モジュール301の起動通知を処理実行手段300に送る。実行させるべき処理モジュールがなくなるまで、実行制御手段400は上記の処理を繰り返す。   The execution control unit 400 causes the process execution unit 300 to sequentially execute the processing modules according to the execution control module 401. For example, the execution control unit 400 sends an activation notification of a processing module 301 to the process execution unit 300 according to the execution control module 401, and causes the process execution unit 300 to execute the process. When the processing execution unit 300 completes the processing of the notified processing module 301, the processing execution unit 300 sends a completion notification to the execution control unit 400. When the execution control unit 400 receives the completion notification, the processing execution unit 300 sends a startup notification of the next processing module 301. Send to 300. The execution control unit 400 repeats the above processing until there is no processing module to be executed.

また、実行制御手段400は、処理実行手段300が生成するデータとともにデータベース501に書き込まれるメタデータを保持する。メタデータの例として、例えば、処理モジュール301の処理対象となるデータを作成したユーザのユーザ名や、処理モジュール301の処理対象となるデータを作成したり保持したりする装置の識別情報(例えば、装置名、IPアドレス等)が挙げられる。例えば、処理モジュール301が通信ネットワーク上のPC(パーソナルコンピュータ)からファイルを収集するためのファイルクローラである場合、ファイルを作成したユーザのユーザ名や、ファイルを保持しているPCの装置名等をメタ情報とすることができる。また、実行制御モジュール401を実行制御手段400に実行させる操作を行っている利用者のユーザ名をメタデータとしてもよい。また、メタデータの例として、処理実行手段300に実行させる処理モジュール301のモジュール名や、処理モジュール301のバージョン名も挙げられる。また、現在、処理実行手段300に実行させている処理モジュール301の直前に実行させていた処理モジュールのモジュール名や、次に実行させる処理モジュールのモジュール名もメタデータとすることができる。また、処理モジュール301の実行時刻もメタデータとなる。また、アプリケーション(モジュールの組み合わせ)の名称(例えば、実行制御モジュール401の名称)をメタデータとしてもよい。また、処理モジュール301を実行させる際に、実行制御モジュール401が処理実行手段300に入力する情報(データソース情報と記す。)や、処理モジュール301に設定されているパラメータをメタデータとして保持してもよい。また、処理モジュール301が、処理実行手段300に処理完了時または処理の途中で実行制御手段400へのデータ出力を行わせるプログラムである場合、実行制御手段400は、処理完了時または処理の途中で出力されるデータをメタデータとしてもよい。ここで挙げたユーザ名や時刻等の各情報はメタデータの例示であり、実行制御手段400は、上記以外の情報をメタデータとして保持してもよい。   Further, the execution control unit 400 holds metadata written in the database 501 together with data generated by the process execution unit 300. Examples of metadata include, for example, the user name of a user who created data to be processed by the processing module 301, and identification information of a device that creates and holds data to be processed by the processing module 301 (for example, Device name, IP address, etc.). For example, when the processing module 301 is a file crawler for collecting files from a PC (personal computer) on a communication network, the user name of the user who created the file, the device name of the PC holding the file, etc. Meta information can be used. Further, the user name of the user who is performing an operation for causing the execution control module 401 to execute the execution control module 401 may be used as metadata. Examples of metadata include the module name of the processing module 301 to be executed by the processing execution unit 300 and the version name of the processing module 301. Further, the module name of the processing module that is currently executed immediately before the processing module 301 that is being executed by the processing execution unit 300 and the module name of the processing module that is executed next can also be used as metadata. The execution time of the processing module 301 is also metadata. The name of the application (combination of modules) (for example, the name of the execution control module 401) may be used as metadata. Further, when executing the processing module 301, information (referred to as data source information) input to the processing execution means 300 by the execution control module 401 and parameters set in the processing module 301 are held as metadata. Also good. When the processing module 301 is a program that causes the process execution unit 300 to output data to the execution control unit 400 when the process is completed or during the process, the execution control unit 400 performs the process when the process is completed or during the process. The output data may be metadata. Each piece of information such as the user name and time given here is an example of metadata, and the execution control unit 400 may hold information other than the above as metadata.

実行制御手段400は、例えば、処理モジュール301の実行を指示した時刻(すなわち起動通知を処理実行手段300に送った時刻)を処理モジュール301の実行時刻として保持すればよい。あるいは、実行制御手段400は時刻を計時し、処理モジュール301の起動通知を処理実行手段300に送った後、DBアクセス仮想化手段100(具体的には後述のメタデータ収集手段140)から時刻を要求されたときに現在時刻を処理モジュール301の実行時刻として提供してもよい。   For example, the execution control unit 400 may hold the time when the execution of the processing module 301 is instructed (that is, the time when the activation notification is sent to the processing execution unit 300) as the execution time of the processing module 301. Alternatively, the execution control unit 400 measures the time, sends an activation notification of the processing module 301 to the process execution unit 300, and then sets the time from the DB access virtualization unit 100 (specifically, the metadata collection unit 140 described later). The current time may be provided as the execution time of the processing module 301 when requested.

処理モジュール301の処理対象となるデータを作成したユーザのユーザ名は、例えば、実行制御モジュール401に明示しておけばよい。例えば、ファイルクローラの実行を指示する実行制御モジュール401の作成者が、ファイルクローラによって収集されるファイルの作成者のユーザ名を実行制御モジュール401内に予めメタデータとして記述しておき、実行制御手段400は、そのユーザ名を読み取ってメタデータとして保持すればよい。また、処理モジュール301が、処理実行手段300に、処理完了時または処理の途中で実行制御手段400に対してユーザ名を出力させるプログラムである場合、実行制御モジュール401は、処理実行手段300から出力されたユーザ名を保持してもよい。   The user name of the user who created the data to be processed by the processing module 301 may be clearly specified in the execution control module 401, for example. For example, the creator of the execution control module 401 instructing execution of the file crawler describes the user name of the creator of the file collected by the file crawler as metadata in advance in the execution control module 401, and executes the execution control means. 400 may read the user name and hold it as metadata. When the processing module 301 is a program that causes the process execution unit 300 to output a user name to the execution control unit 400 when the process is completed or during the process, the execution control module 401 outputs from the process execution unit 300. It is also possible to hold the user name that has been set.

また、実行制御モジュール401を実行制御手段400に実行させる操作を行っている利用者のユーザ名をメタデータとするには、実行制御手段400は以下のようにユーザ名を保持すればよい。すなわち、実行制御手段400は、その実行制御手段400自身を備える装置(図1に示す例ではデータベース接続システム10)においてユーザ名を入力するログイン操作が行われたときに、そのユーザ名をメタデータとして保持すればよい。   Further, in order to use the user name of the user who is performing the operation of causing the execution control module 401 to execute the execution control module 401 as metadata, the execution control unit 400 may hold the user name as follows. That is, the execution control unit 400 converts the user name into metadata when a login operation for inputting the user name is performed in an apparatus (the database connection system 10 in the example shown in FIG. 1) including the execution control unit 400 itself. As long as it holds.

実行制御手段400は、DBアクセス仮想化手段100からメタデータの取得要求を受け取ると、要求されたメタデータをDBアクセス仮想化手段100に送る。   Upon receiving the metadata acquisition request from the DB access virtualization unit 100, the execution control unit 400 sends the requested metadata to the DB access virtualization unit 100.

処理モジュール301および実行制御モジュール401の例について説明する。例えば、各処理モジュール301は、それぞれプログラムであり、実行制御モジュール401は、各プログラムの実行順序を定めたバッチファイル(例えば、UNIXにおけるシェルスクリプト)であってもよい。UNIXは登録商標である。また、処理モジュール301はDLL(Dynamic Link Library)によって呼び出されるモジュールであり、実行制御モジュール401はそのモジュールを呼び出すファイルであってもよい。また、処理モジュール301はJavaにおけるクラスライブラリであり、実行制御モジュール401はそのクラスライブラリを呼び出す情報であってもよい。   Examples of the processing module 301 and the execution control module 401 will be described. For example, each processing module 301 may be a program, and the execution control module 401 may be a batch file (for example, a shell script in UNIX) that defines the execution order of each program. UNIX is a registered trademark. Further, the processing module 301 may be a module called by a DLL (Dynamic Link Library), and the execution control module 401 may be a file for calling the module. Further, the processing module 301 may be a class library in Java, and the execution control module 401 may be information for calling the class library.

記憶装置11が複数種類の処理モジュール301を記憶する場合、DBアクセス仮想化モジュール101およびDBアクセスモジュール201も、処理モジュール301毎に用意され、記憶装置11が各処理モジュール301に対応するDBアクセス仮想化モジュール101およびDBアクセスモジュール201をそれぞれ記憶する。記憶装置11は、例えば、このように処理モジュール301、DBアクセス仮想化モジュール101およびDBアクセスモジュール201を記憶する。あるいは、複数種類の処理モジュール301が用意されていても、DBアクセス仮想化モジュール101およびDBアクセスモジュール201は、それぞれ単一のモジュールとして記憶装置11に記憶されていてもよい。   When the storage device 11 stores a plurality of types of processing modules 301, the DB access virtualization module 101 and the DB access module 201 are also prepared for each processing module 301, and the storage device 11 corresponds to each processing module 301. Storing module 101 and DB access module 201 are stored. For example, the storage device 11 stores the processing module 301, the DB access virtualization module 101, and the DB access module 201 in this way. Alternatively, even if a plurality of types of processing modules 301 are prepared, the DB access virtualization module 101 and the DB access module 201 may each be stored in the storage device 11 as a single module.

データベースシステム500は、DBアクセス手段200から受信するデータの読み込みや書き込みを指示するコマンドに応じて、データベース501からのデータの読み込みまたはデータの書き込みを行う。   The database system 500 reads or writes data from the database 501 in accordance with a command for instructing reading or writing of data received from the DB access unit 200.

また、データベースシステム500には、データベース501を参照可能な統合データ分析システム(図1において図示せず。)が接続される。統合データ分析システムは、例えばBIであり、各種処理モジュール301の実行によりデータベース501に登録されたデータおよびそのデータとともに登録されたメタデータを参照し、各種処理モジュール301の実行結果を総合的に分析する。統合データ分析システムが行う分析の処理内容は特に限定されない。   Further, an integrated data analysis system (not shown in FIG. 1) that can refer to the database 501 is connected to the database system 500. The integrated data analysis system is, for example, a BI, and comprehensively analyzes the execution results of the various processing modules 301 by referring to the data registered in the database 501 by the execution of the various processing modules 301 and the metadata registered together with the data. To do. The processing content of analysis performed by the integrated data analysis system is not particularly limited.

図2は、DBアクセス仮想化手段100を示すブロック図である。DBアクセス仮想化手段100は、クエリ書き換え手段110と、書き換え設定手段120と、書き換え設定蓄積手段130と、メタデータ収集手段140と、メタデータ蓄積手段150とを備える。   FIG. 2 is a block diagram showing the DB access virtualization unit 100. The DB access virtualization unit 100 includes a query rewrite unit 110, a rewrite setting unit 120, a rewrite setting storage unit 130, a metadata collection unit 140, and a metadata storage unit 150.

書き換え設定手段120は、データベース501に書き込まれるデータとそのデータに追加すべきメタデータの項目との対応関係を示す設定情報が入力されるインタフェース(例えば、キーボード等の入力デバイス)を有し、インタフェースを介して入力された設定情報を書き換え設定蓄積手段130に記憶させる。書き換え設定蓄積手段130は、設定情報を記憶する記憶装置である。   The rewrite setting unit 120 has an interface (for example, an input device such as a keyboard) to which setting information indicating a correspondence relationship between data written in the database 501 and metadata items to be added to the data is input. Is stored in the rewrite setting storage means 130. The rewrite setting storage unit 130 is a storage device that stores setting information.

設定情報では、データベース501のテーブル毎に、テーブルに書き込むデータとともに書き込むべきメタデータの項目が定められる。従って、テーブルに書き込むデータと、メタデータの項目とが対応づけられる。   In the setting information, for each table of the database 501, metadata items to be written together with data to be written to the table are determined. Therefore, the data to be written to the table is associated with the metadata item.

図3および図4は、設定情報の例を示す説明図である。図3に例示する設定情報は、テーブルAにデータを書き込む場合、そのデータとともに「ユーザ名」および「実行時刻」をメタデータとして書き込むことを示している。「ユーザ名」は、例えば、処理モジュール301の処理対象となるデータを作成したユーザのユーザ名であるが、他のユーザのユーザ名であってもよい。また、「実行時刻」は、テーブルAにデータを書き込むクエリを処理実行手段300に生成させた処理モジュール301の実行時刻である。   3 and 4 are explanatory diagrams showing examples of setting information. The setting information illustrated in FIG. 3 indicates that when data is written in the table A, “user name” and “execution time” are written as metadata together with the data. “User name” is, for example, the user name of the user who created the data to be processed by the processing module 301, but may be the user name of another user. The “execution time” is the execution time of the processing module 301 that causes the process execution unit 300 to generate a query for writing data to the table A.

設定情報において、メタデータの項目は、メタデータが書き込まれるテーブルにおけるメタデータのフィールドを特定できるように記述される。例えば、メタデータが書き込まれるテーブルにおけるメタデータのフィールド名が、メタデータの項目として設定情報に記述される。図3に示す例では、テーブルAでのメタデータのフィールド名である「ユーザ名」および「実行時刻」を設定情報に記述している。   In the setting information, the metadata item is described so that the metadata field in the table to which the metadata is written can be specified. For example, metadata field names in a table to which metadata is written are described in the setting information as metadata items. In the example shown in FIG. 3, “user name” and “execution time” that are metadata field names in the table A are described in the setting information.

なお、処理実行手段300はメタデータを扱わないので、データベース501内のテーブルには、当初、メタデータのフィールドは設けられていない。そのため、例えば、利用者が手作業によって、データベース501のスキーマを確認し、メタデータのフィールドを追加するようにテーブルを変更しておく。   Since the process execution unit 300 does not handle metadata, the table in the database 501 is not initially provided with a metadata field. For this reason, for example, the user manually checks the schema of the database 501 and changes the table to add metadata fields.

また、メタデータは、処理実行手段300が生成したクエリで指定されたテーブルとは別のテーブルに記憶されてもよい。図4に例示する設定情報は、テーブルBにデータを書き込む場合、テーブルBにおける特定のフィールド(本例では「データ1」)を外部キーとして、他のテーブルCに、外部キー(「データ1」)のキー値、「ユーザ名」、「実行時刻」を書き込むことを示している。本例では、テーブルBに「データ1」、「データ2」を書き込む場合、メタデータある「ユーザ名」および「実行時刻」が別のテーブルCに書き込まれることになる。なお、「ユーザ名」および「実行時刻」がメタデータの項目である旨が設定情報中に記述される。   The metadata may be stored in a table different from the table specified by the query generated by the process execution unit 300. In the setting information illustrated in FIG. 4, when data is written to the table B, a specific field (“data 1” in this example) in the table B is used as an external key, and the external key (“data 1”) is stored in another table C. ) Key value, “user name”, and “execution time”. In this example, when “data 1” and “data 2” are written in the table B, the “user name” and “execution time” as metadata are written in another table C. The setting information describes that “user name” and “execution time” are metadata items.

図3および図4では、テーブル毎にメタデータの項目を定める設定情報の例を示したが、テーブルを指定する必要がない場合(例えば、各処理モジュール301の処理対象となるテーブルが1つである場合等)には、メタデータの項目だけ定められていてもよい。   3 and 4 show examples of setting information that determines metadata items for each table. However, when there is no need to specify a table (for example, one processing target for each processing module 301 is one table). In some cases, only metadata items may be defined.

メタデータ収集手段140は、設定情報において定められた各種メタデータを実行制御手段400に要求し、実行制御手段400からメタデータを収集する。   The metadata collection unit 140 requests the execution control unit 400 for various metadata defined in the setting information, and collects metadata from the execution control unit 400.

メタデータ蓄積手段150は、メタデータ収集手段140にメタデータを収集させる。また、メタデータ蓄積手段150は、メタデータを記憶する記憶装置を含んでおり、メタデータ収集手段140が収集したメタデータをその記憶装置に記憶する。また、メタデータ蓄積手段150は、クエリ書き換え手段110からの要求に応じて、記憶したメタデータをクエリ書き換え手段110に提供する。   The metadata storage unit 150 causes the metadata collection unit 140 to collect metadata. The metadata accumulating unit 150 includes a storage device that stores metadata, and stores the metadata collected by the metadata collection unit 140 in the storage device. Further, the metadata accumulating unit 150 provides the stored metadata to the query rewriting unit 110 in response to a request from the query rewriting unit 110.

クエリ書き換え手段110は、処理実行手段300によってデータ書き込みのクエリが生成されると、書き換え設定蓄積手段130に記憶されている設定情報を参照し、クエリによって書き込みを指示されたデータに追加するメタデータの項目を特定する。例えば、図3や図4に例示した設定情報のように、データベース501内のテーブルとメタデータの項目とが対応付けられているとする。クエリ書き換え手段110は、クエリで指定されたテーブルに対応するメタデータの項目を、設定情報を参照することによって特定する。クエリ書き換え手段110は、その項目に該当するメタデータを、メタデータ蓄積手段150に要求し、メタデータを受け取ると、そのメタデータもデータベース501に書き込むようにクエリを変換し、変換後のクエリをDBアクセス手段200に送る。   When a data write query is generated by the process execution unit 300, the query rewrite unit 110 refers to setting information stored in the rewrite setting storage unit 130, and adds metadata to the data instructed to write by the query Identify items. For example, it is assumed that the table in the database 501 and the metadata item are associated with each other as in the setting information illustrated in FIGS. 3 and 4. The query rewriting means 110 identifies the metadata item corresponding to the table specified by the query by referring to the setting information. The query rewriting unit 110 requests the metadata corresponding to the item from the metadata storage unit 150. When the query rewriting unit 110 receives the metadata, the query rewriting unit 110 converts the query so that the metadata is also written in the database 501, and converts the query after conversion. It is sent to the DB access means 200.

図3に例示する設定情報が定められていて、テーブルAに対するデータ書き込みを指定するクエリが生成されたとする。すると、クエリ書き換え手段110は、テーブルAに対応付けられた「ユーザ名」、「実行時刻」という項目を設定情報の中から特定し、その項目のメタデータ(例えば「User1」等)をメタデータ蓄積手段150から受け取り、それらのメタデータもテーブルAに書き込むようにクエリを変換する。例えば、データベース501におけるメタデータのフィールド名およびメタデータをクエリに追加する。このようにクエリを変換することにより、図3の下段に示すように、ユーザ名や実行時刻等のメタデータもデータベース501内のテーブルAに書き込まれる。   Assume that the setting information illustrated in FIG. 3 is defined and a query that specifies data writing to the table A is generated. Then, the query rewriting unit 110 identifies items such as “user name” and “execution time” associated with the table A from the setting information, and sets metadata (for example, “User1”) of the items as metadata. The query is converted so as to be received from the storage means 150 and to write their metadata into the table A as well. For example, metadata field names and metadata in the database 501 are added to the query. By converting the query in this way, metadata such as the user name and execution time is also written in the table A in the database 501 as shown in the lower part of FIG.

また、例えば、図4に例示する設定情報が定められていて、テーブルBに対するデータ書き込みを指定するクエリが生成されたとする。すると、クエリ書き換え手段110は、テーブルBに対応付けられた「ユーザ名」、「実行時刻」という項目を設定情報の中から特定し、その項目のメタデータ(例えば「User1」等)をメタデータ蓄積手段150から受け取る。そして、クエリ書き換え手段110は、テーブルBに対するデータ書き込みを指定するクエリに含まれている外部キーのキー値と、「ユーザ名」、「実行時刻」のメタデータとをテーブルCに書き込むクエリを新たに作成する。この結果得られたクエリによって、図4の下段に示すように、各データおよびメタデータがデータベース501内のテーブルB,Cに書き込まれる。   Further, for example, it is assumed that the setting information illustrated in FIG. 4 is defined and a query that specifies data writing to the table B is generated. Then, the query rewriting unit 110 identifies items such as “user name” and “execution time” associated with the table B from the setting information, and sets metadata (for example, “User1”) of the items as metadata. Receive from storage means 150. Then, the query rewriting means 110 newly creates a query for writing the key value of the foreign key included in the query for designating data writing to the table B and the metadata of “user name” and “execution time” to the table C. To create. By the query obtained as a result, each data and metadata are written in the tables B and C in the database 501 as shown in the lower part of FIG.

クエリ書き換え手段110は、処理実行手段300によって生成されたクエリを、データベース501に書き込むデータおよびメタデータの各フィールド名と、データおよびメタデータを含めたクエリに変換すればよい。変換は、図4を例にして説明したように新たなクエリを追加する変換であってもよい。   The query rewriting unit 110 may convert the query generated by the process execution unit 300 into a query including each field name of data and metadata to be written in the database 501 and the data and metadata. The conversion may be a conversion for adding a new query as described with reference to FIG.

また、データベース501からデータを読み込むためのクエリを処理実行手段300が生成した場合、クエリ書き換え手段110は、そのクエリに対する変換を行わずにDBアクセス手段200に送る。データベース501から読み出された読み込みデータがDBアクセス手段200から返ってきた場合、クエリ書き換え手段110は、設定情報を参照し、設定情報で指定されているメタデータが、読み込みデータ中に含まれているか否かを判定する。設定情報には、メタデータの項目が、テーブルにおけるメタデータのフィールドを特定できるように記述されている。例えば、フィールド名がメタデータの項目として記述されている。クエリ書き換え手段110は、設定情報を参照してメタデータのフィールド名を特定し、読み込みデータ中にそのフィールドのデータが含まれているか否かを判定すればよい。読み込みデータ中に、設定情報で定められているメタデータが含まれていれば、クエリ書き換え手段110は、読み込みデータからメタデータを削除し、メタデータを削除したデータを処理実行手段300に返す。読み込みデータにメタデータが含まれていなければ、クエリ書き換え手段110は、そのデータを処理実行手段300に送る。   Further, when the processing execution unit 300 generates a query for reading data from the database 501, the query rewriting unit 110 sends the query to the DB access unit 200 without converting the query. When read data read from the database 501 is returned from the DB access means 200, the query rewrite means 110 refers to the setting information, and the metadata specified by the setting information is included in the read data. It is determined whether or not. In the setting information, metadata items are described so that metadata fields in the table can be specified. For example, field names are described as metadata items. The query rewriting unit 110 may refer to the setting information to identify the field name of the metadata and determine whether or not the data of the field is included in the read data. If the read data includes metadata defined by the setting information, the query rewriting unit 110 deletes the metadata from the read data and returns the data from which the metadata has been deleted to the process execution unit 300. If the read data does not include metadata, the query rewrite unit 110 sends the data to the process execution unit 300.

なお、図1では、記憶装置11が各処理モジュール301に対応するDBアクセス仮想化モジュール101を記憶している場合を示している。DBアクセス仮想化モジュール101が処理モジュール301毎に作成される場合、入力された設定情報を書き換え設定蓄積手段130に記憶させる命令に該当する部分を、共通のモジュールとして作成してもよい。そして、クエリ書き換え手段110、メタデータ収集手段140、およびメタデータ蓄積手段150に対する命令の部分を、各処理モジュール301毎に作成して記憶装置11に記憶させてもよい。   FIG. 1 shows a case where the storage device 11 stores the DB access virtualization module 101 corresponding to each processing module 301. When the DB access virtualization module 101 is created for each processing module 301, a portion corresponding to a command for storing the input setting information in the rewrite setting storage unit 130 may be created as a common module. Then, a command portion for the query rewriting unit 110, the metadata collection unit 140, and the metadata storage unit 150 may be created for each processing module 301 and stored in the storage device 11.

クエリ書き換え手段110、メタデータ収集手段140、DBアクセス手段200、処理実行手段300、実行制御手段400は、例えば、プログラムに従って動作するCPUによって実現される。書き換え設定手段120は、例えば、プログラムに従って動作するCPUと、キーボード等の入力デバイスとによって実現される。メタデータ蓄積手段150は、プログラムに従って動作するCPUと、記憶装置とによって実現される。上記の各手段を実現するためのCPUは、同一のCPUであってもよい。   The query rewriting unit 110, the metadata collection unit 140, the DB access unit 200, the process execution unit 300, and the execution control unit 400 are realized by a CPU that operates according to a program, for example. The rewrite setting unit 120 is realized by, for example, a CPU that operates according to a program and an input device such as a keyboard. The metadata storage unit 150 is realized by a CPU that operates according to a program and a storage device. The same CPU may be sufficient as CPU for implement | achieving said each means.

なお、上記の説明では、データベース501内のテーブルにメタデータのフィールドを追加する例として、利用者が手作業によってメタデータのフィールドを追加する場合を例示した。データベース501内のテーブルにメタデータのフィールドを追加する処理を自動的に行ってもよい。例えば、新規テーブルの生成を指示するクエリに対して、設定情報で定められたメタデータのフィールドを追加する処理をDBアクセス仮想化手段100(より具体的にはクエリ書き換え手段110)に実行させるモジュールを記憶させておく。そして、クエリ書き換え手段110が、新規テーブルの生成を指示するクエリ(例えば、SQLのcreate table文)が生成された場合、設定情報を参照してその新規テーブルに対応付けられたメタデータの項目を探索し、メタデータの項目があれば、その項目を新たなフィールドとしてテーブルに追加するようにクエリを変換してもよい。設定情報に、テーブルの情報がなく、メタデータの項目だけが指定されている場合、その項目を新たなフィールドとしてテーブルに追加するように、新規テーブルの生成を指示するクエリを書き換えればよい。ここで、データベース接続システム10が、新規テーブルの生成を指示するクエリを作成する手段(図示せず。)を備えていてもよい。あるいは、データベース接続システム10以外の装置あるいはデータベース接続システム10の利用者によって、新規テーブルの生成を指示するクエリが入力されてもよい。   In the above description, as an example of adding a metadata field to a table in the database 501, a case where a user manually adds a metadata field is illustrated. Processing for adding a metadata field to a table in the database 501 may be automatically performed. For example, a module that causes the DB access virtualization unit 100 (more specifically, the query rewriting unit 110) to execute a process of adding a metadata field defined by setting information to a query instructing generation of a new table Remember me. When the query rewriting unit 110 generates a query (for example, an SQL create table statement) that instructs generation of a new table, the setting information is referred to, and the metadata item associated with the new table is displayed. If there is an item of metadata by searching, the query may be converted to add the item to the table as a new field. When there is no table information in the setting information and only an item of metadata is specified, a query for instructing generation of a new table may be rewritten so that the item is added to the table as a new field. Here, the database connection system 10 may be provided with means (not shown) for creating a query that instructs generation of a new table. Alternatively, a query instructing generation of a new table may be input by a device other than the database connection system 10 or a user of the database connection system 10.

また、メタデータのフィールドを新規テーブルに追加させるようにクエリを変換させるためのモジュールは、DBアクセス仮想化モジュール101とは、別のモジュールとして作成されるのではなく、DBアクセス仮想化モジュール101と同一のモジュールとして作成されてもよい。すなわち、DBアクセス仮想化モジュール101が、DBアクセス仮想化手段100に対して、メタデータのフィールドを新規テーブルに追加させるようにクエリを変換させる命令を含んでいてもよい。   Further, the module for converting the query so that the metadata field is added to the new table is not created as a module separate from the DB access virtualization module 101, but the DB access virtualization module 101 and They may be created as the same module. That is, the DB access virtualization module 101 may include an instruction that causes the DB access virtualization unit 100 to convert a query so that a metadata field is added to the new table.

次に、本発明のデータベース接続システムの他の構成例を示す。以下に示す図5および図6では、図1に示す構成要素と同様の構成要素については、図1と同一の符号を付し、説明を省略する。図5は、データベースシステムとデータベース接続システム10とが同一の装置である場合の構成例を示すブロック図である。図5に示すように、データベース接続システム10がデータベース501を保持する構成であってもよい。   Next, another configuration example of the database connection system of the present invention is shown. In FIG. 5 and FIG. 6 described below, the same components as those shown in FIG. 1 are denoted by the same reference numerals as those in FIG. FIG. 5 is a block diagram illustrating a configuration example when the database system and the database connection system 10 are the same device. As shown in FIG. 5, the database connection system 10 may hold the database 501.

また、図6は、処理モジュール301が複数台のデータベース接続システム10に分散されている場合の構成例を示すブロック図である。この場合、各データベース接続システム10は、DBアクセス手段200と、DBアクセス仮想化手段100と、処理実行手段300とを備える。また、各データベース接続システム10は、DBアクセスモジュール201と、DBアクセス仮想化モジュール101と、処理モジュール301とを記憶した記憶装置11を備える。また、実行制御モジュール401を記憶する記憶装置71と、実行制御手段400とを備えた情報処理装置70が設けられる。情報処理装置70と各データベース接続システム10とは通信ネットワークを介して接続される。実行制御手段400は、実行制御モジュールに従い、各データベース接続システム10の処理実行手段300に、実行すべき処理モジュールの起動通知を順次送信する。処理実行手段300は、実行制御手段400に通知された処理モジュール301の処理を完了すると、完了通知を実行制御手段400に送信する。また、DBアクセス仮想化手段100は、収集すべきメタデータを、通信ネットワークを介して実行制御手段400に送信する。実行制御手段400は要求されたメタデータをDBアクセス仮想化手段100にに送信する。なお、図6では、実行制御手段400を備える情報処理装置70を各データベース接続システム10とは別に設ける場合を示しているが、複数のデータベース接続システム10のいずれかが実行制御モジュール401を記憶するとともに、実行制御手段400を備えていてもよい。   FIG. 6 is a block diagram illustrating a configuration example when the processing modules 301 are distributed among a plurality of database connection systems 10. In this case, each database connection system 10 includes DB access means 200, DB access virtualization means 100, and process execution means 300. Each database connection system 10 includes a storage device 11 that stores a DB access module 201, a DB access virtualization module 101, and a processing module 301. In addition, an information processing apparatus 70 including a storage device 71 that stores the execution control module 401 and an execution control unit 400 is provided. The information processing apparatus 70 and each database connection system 10 are connected via a communication network. The execution control unit 400 sequentially transmits a processing module activation notification to be executed to the process execution unit 300 of each database connection system 10 according to the execution control module. When the processing of the processing module 301 notified to the execution control unit 400 is completed, the process execution unit 300 transmits a completion notification to the execution control unit 400. Further, the DB access virtualization unit 100 transmits the metadata to be collected to the execution control unit 400 via the communication network. The execution control unit 400 transmits the requested metadata to the DB access virtualization unit 100. 6 shows a case where the information processing apparatus 70 including the execution control unit 400 is provided separately from each database connection system 10, but any one of the plurality of database connection systems 10 stores the execution control module 401. In addition, the execution control means 400 may be provided.

次に、動作について説明する。
図7は、データベース接続システム10および統合データ分析システム(図1において図示せず。)の動作の例を示すフローチャートである。まず、データベース接続システム10の利用者は、1つの処理モジュールによって、あるいは複数の処理モジュールを連携することによって、所望の処理を行うアプリケーションを定める。アプリケーションは、処理モジュールの組み合わせであり、利用者は、処理モジュールの実行順を定めた実行制御モジュールを作成し、実行制御モジュールをデータベース統合システム10に入力する。データベース統合システム10(図1参照)は、実行制御モジュール401が入力されると、実行制御モジュール401を記憶装置11に記憶させる(ステップS1)。
Next, the operation will be described.
FIG. 7 is a flowchart showing an example of operations of the database connection system 10 and the integrated data analysis system (not shown in FIG. 1). First, the user of the database connection system 10 determines an application for performing a desired process by one processing module or by linking a plurality of processing modules. The application is a combination of processing modules, and the user creates an execution control module that defines the execution order of the processing modules, and inputs the execution control module to the database integrated system 10. When the execution control module 401 is input, the database integration system 10 (see FIG. 1) stores the execution control module 401 in the storage device 11 (step S1).

次に、利用者は、設定情報を作成する。処理モジュール301に従い動作する処理実行手段300が処理実行時に使用せず、またデータベース501への書き込みも指示しないデータであって、統合データ分析システムが分析時に使用するデータを、利用者はメタデータとして定める。そして、利用者は、処理実行手段300がデータベース301への書き込みを指示するデータと、メタデータの項目との対応関係を示す設定情報を作成する。データベース接続システム10は、設定情報が入力されると、その設定情報を記憶する(ステップS2)。   Next, the user creates setting information. Data that is not used by the processing execution unit 300 that operates according to the processing module 301 at the time of processing execution and that does not instruct writing to the database 501 and that the integrated data analysis system uses at the time of analysis is used as metadata by the user. Determine. Then, the user creates setting information indicating the correspondence between the data that the process execution unit 300 instructs to write to the database 301 and the metadata items. When the setting information is input, the database connection system 10 stores the setting information (step S2).

続いて、処理実行手段300は、利用者によってアプリケーションとして定められた各
処理モジュール301を実行する(ステップS3)。このとき、実行制御手段400が処理モジュール301の実行順を制御する。ステップS3において、処理実行手段300は、データベース501に記憶されているデータを読み込んだり、データベース501にデータを書き込んだりしながら、各処理モジュール301が定めている処理を行う。処理実行手段300がデータベース501へのデータの書き込みを指示するクエリを生成した場合、DBアクセス仮想化手段100は、そのデータに対応するメタデータもデータベース501に書き込まれるようにクエリを変換する。DBアクセス手段200は、変換後のクエリをデータベースシステム500独自のコマンドに変換し、データベースシステム500はそのコマンドに従ってデータおよびメタデータを記憶する。この結果、処理実行手段300が書き込もうとしたデータの他にメタデータもデータベース501に書き込まれる。
Subsequently, the process execution unit 300 executes each process module 301 defined as an application by the user (step S3). At this time, the execution control unit 400 controls the execution order of the processing modules 301. In step S <b> 3, the process execution unit 300 performs the process defined by each process module 301 while reading data stored in the database 501 and writing data to the database 501. When the process execution unit 300 generates a query that instructs to write data to the database 501, the DB access virtualization unit 100 converts the query so that metadata corresponding to the data is also written to the database 501. The DB access means 200 converts the converted query into a command unique to the database system 500, and the database system 500 stores data and metadata according to the command. As a result, metadata is also written in the database 501 in addition to the data that the process execution means 300 is trying to write.

データベース接続システム10が複数のアプリケーションを実行する場合、ステップS1〜S3の処理を繰り返せばよい。   When the database connection system 10 executes a plurality of applications, the processes in steps S1 to S3 may be repeated.

統合データ分析システムは、データベース501に蓄積されたメタデータを活用し、データの分析を行う(ステップS4)。例えば、複数のアプリケーションが実行された後、統合データ分析システムは各アプリケーションの実行によりデータベース501に記憶されたデータおよびメタデータ全体を用いて分析を行う。   The integrated data analysis system uses the metadata accumulated in the database 501 to analyze the data (step S4). For example, after a plurality of applications are executed, the integrated data analysis system performs analysis using the data and the entire metadata stored in the database 501 by executing each application.

次に、ステップS2,S3の処理についてより詳細に説明する。図8ないし図10は、ステップS2,S3の処理をより詳細に示すフローチャートである。具体的には、図8は、設定情報が入力されてからアプリケーション実行開始時までの動作を示す。図9は、処理実行手段300がデータベースへのデータの書き込みを指示するクエリを生成した場合の動作の例を示すフローチャートである。図10は、処理実行手段300がデータベースからのデータの読み込みを指示するクエリを生成した場合の動作の例を示すフローチャートである。   Next, the processing in steps S2 and S3 will be described in more detail. 8 to 10 are flowcharts showing the processes of steps S2 and S3 in more detail. Specifically, FIG. 8 shows the operation from when the setting information is input to when the application execution is started. FIG. 9 is a flowchart illustrating an example of an operation when the process execution unit 300 generates a query for instructing writing of data into the database. FIG. 10 is a flowchart illustrating an example of an operation when the process execution unit 300 generates a query for instructing reading of data from the database.

また、実行制御手段400がDBアクセス仮想化手段100に提供するメタデータには、処理実行手段300が各処理モジュール301を順次実行していく経過とともに変化するものと、変化しないものとがある。前者の例として、処理モジュール301の実行時刻等が挙げられる。また、後者の例として、アプリケーション(モジュールの組み合わせ)の名称(例えば、実行制御モジュール401の名称)が挙げられる。以下に示す説明では、DBアクセス仮想化手段100が後者のメタデータを最初に収集し、処理実行手段300が処理モジュール301を実行する際に後者のメタデータを収集する場合を例にして説明する。   The metadata provided by the execution control unit 400 to the DB access virtualization unit 100 may or may not change as the process execution unit 300 sequentially executes each processing module 301. An example of the former is the execution time of the processing module 301. As an example of the latter, there is a name of an application (a combination of modules) (for example, a name of the execution control module 401). In the following description, an example will be described in which the DB access virtualization unit 100 first collects the latter metadata, and the process execution unit 300 collects the latter metadata when the processing module 301 is executed. .

まず、図8を参照して、アプリケーション実行開始時までの動作を説明する。利用者は、データベース501に書き込まれるデータとメタデータの項目との対応関係を示す設定情報を作成する。書き換え設定手段120は、利用者により設定情報が入力される(ステップS11)。すると、書き換え設定手段120は、入力された設定情報を書き換え設定蓄積手段130に記憶させる(ステップS12)。   First, the operation up to the start of application execution will be described with reference to FIG. The user creates setting information indicating a correspondence relationship between data written in the database 501 and metadata items. In the rewrite setting unit 120, setting information is input by the user (step S11). Then, the rewrite setting unit 120 stores the input setting information in the rewrite setting storage unit 130 (step S12).

その後、実行制御手段400は、アプリケーションを起動する(ステップS13)。すなわち、実行制御モジュール401に定められた順に処理モジュール301の起動通知を順次、処理実行手段300に送る処理を開始する。   Thereafter, the execution control unit 400 activates the application (step S13). That is, the process of sequentially sending the activation notifications of the processing modules 301 to the processing execution unit 300 in the order determined by the execution control module 401 is started.

また、処理実行手段300は、実行制御手段400から最初に処理モジュール301の起動通知を受けたときに、例えば、クエリ書き換え手段110を介して、メタデータ収集手段140にその旨を通知する。処理モジュール301が最初の起動通知を受けたことが通知されると、メタデータ収集手段140は、書き換え設定情報蓄積手段130に記憶された設定情報を参照し、メタデータの項目を特定する。メタデータ収集手段140は、そのメタデータの項目のうち、処理実行手段300の処理経過とともに変化しないメタデータの項目を実行制御手段400に送り、そのメタデータを要求する。利用者は、設定情報内で、メタデータの項目とともに、そのメタデータが処理実行手段300の処理経過とともに変化するか否かを定めておけばよい。メタデータ収集手段140は、変化しないと定められたメタデータの項目を特定し、そのメタデータを実行制御手段400に要求する。実行制御手段400は要求されたメタデータをメタデータ収集手段140に送り、メタデータ収集手段140は実行制御手段400から受け取ったメタデータをメタデータ蓄積手段150に記憶させる(ステップS14)。   Further, when the processing execution unit 300 first receives the activation notification of the processing module 301 from the execution control unit 400, for example, the processing execution unit 300 notifies the metadata collection unit 140 via the query rewriting unit 110. When notified that the processing module 301 has received the first activation notification, the metadata collection unit 140 refers to the setting information stored in the rewrite setting information storage unit 130 and identifies the item of the metadata. The metadata collection unit 140 sends metadata items that do not change with the progress of processing of the processing execution unit 300 among the metadata items to the execution control unit 400 and requests the metadata. In the setting information, the user may determine whether the metadata changes along with the processing progress of the processing execution means 300 together with the metadata item. The metadata collection unit 140 identifies metadata items that are determined not to change, and requests the metadata from the execution control unit 400. The execution control unit 400 sends the requested metadata to the metadata collection unit 140, and the metadata collection unit 140 stores the metadata received from the execution control unit 400 in the metadata storage unit 150 (step S14).

処理実行手段300は、実行制御手段400から処理モジュール301の起動通知を受けると、指定された処理モジュール301の処理を開始する。処理実行手段300は、処理モジュール301に従って、データベース501にデータを書き込むクエリを生成したり、あるいはデータベース501からデータを読み込むクエリを生成したりする。以下、これらのクエリが生成された場合の動作を説明する。   When the processing execution unit 300 receives the activation notification of the processing module 301 from the execution control unit 400, the processing execution unit 300 starts the processing of the designated processing module 301. The process execution means 300 generates a query for writing data into the database 501 or a query for reading data from the database 501 according to the processing module 301. The operation when these queries are generated will be described below.

まず、図9を参照して、処理実行手段300がデータを書き込むクエリを生成する場合の動作を説明する。処理実行手段300は指定された処理モジュール301に従って処理を行い、その処理において、データベース501へのデータの書き込みを指示するクエリを生成する(ステップS15)。処理実行手段300は、例えばSQL等のデータベース言語によりクエリを生成する。   First, with reference to FIG. 9, the operation when the process execution unit 300 generates a query for writing data will be described. The processing execution means 300 performs processing according to the designated processing module 301, and generates a query that instructs writing of data to the database 501 in the processing (step S15). The process execution unit 300 generates a query using a database language such as SQL, for example.

データの書き込みを指示するクエリが生成されると、DBアクセス仮想化手段100が有するクエリ書き換え手段110(図2参照)は、そのクエリを解析する(ステップS16)。具体的には、クエリ書き換え手段110は、データが書き込まれるテーブルのテーブル名をクエリ中から読み取る。クエリの書式はデータベース言語で定められているので、クエリ書き換え手段110は、クエリの所定箇所からテーブル名を読み取ればよい。   When a query for instructing data writing is generated, the query rewriting unit 110 (see FIG. 2) included in the DB access virtualization unit 100 analyzes the query (step S16). Specifically, the query rewriting unit 110 reads the table name of the table to which data is written from the query. Since the query format is defined in the database language, the query rewriting means 110 may read the table name from a predetermined location of the query.

クエリ書き換え手段110は、書き換え設定蓄積手段130に記憶された設定情報を参照し、クエリ中で書き込み指示されているデータとともにデータベースに書き込むメタデータの項目を特定する。すなわち、クエリ書き換え手段110は、ステップS16で読み取ったテーブルに対応づけられているメタデータの項目を設定情報の中から読み取る。さらに、クエリ書き換え手段110は、その項目の中から、処理実行手段300の処理経過とともに変化するメタデータの項目を選択する。クエリ書き換え手段110は、選択した項目を指定して、その項目のメタデータを記憶するようにメタデータ蓄積手段150に要求する(ステップS17)。なお、既に述べたように、設定情報内で、メタデータの項目とともに、そのメタデータが処理実行手段300の処理経過とともに変化するか否かを定めておけばよい。そして、クエリ書き換え手段110は、変化すると定められているメタデータの項目を選択すればよい。   The query rewrite unit 110 refers to the setting information stored in the rewrite setting storage unit 130, and identifies the metadata item to be written to the database together with the data instructed to be written in the query. That is, the query rewriting unit 110 reads the metadata item associated with the table read in step S16 from the setting information. Further, the query rewriting unit 110 selects an item of metadata that changes with the progress of processing of the processing execution unit 300 from among the items. The query rewriting unit 110 specifies the selected item and requests the metadata storage unit 150 to store the metadata of the item (step S17). As already described, it is only necessary to determine whether the metadata changes with the progress of the process of the process execution means 300 together with the metadata item in the setting information. Then, the query rewriting unit 110 may select an item of metadata that is determined to change.

処理モジュール301の実行時刻等は処理実行手段300の処理経過とともに変化し、これらのメタデータはステップS14の時点では確定しないので、ステップS17でメタデータ蓄積手段150に記憶させる。   The execution time or the like of the processing module 301 changes with the progress of the processing of the processing execution unit 300, and these metadata are not fixed at the time of step S14, and are stored in the metadata storage unit 150 in step S17.

メタデータ蓄積手段150は、クエリ書き換え手段110によってメタデータの項目を指定されると、その項目をメタデータ収集手段140に通知して、メタデータ収集手段140にメタデータを収集させる。メタデータ収集手段140は、通知された項目のメタデータを実行制御手段400に要求し、実行制御手段400は、要求されたメタデータをメタデータ収集手段140に送る。メタデータ収集手段140は、実行制御手段400から受け取ったメタデータをメタデータ蓄積手段150に記憶させる。   When a metadata item is specified by the query rewriting unit 110, the metadata storage unit 150 notifies the metadata collection unit 140 of the item and causes the metadata collection unit 140 to collect metadata. The metadata collection unit 140 requests metadata of the notified item from the execution control unit 400, and the execution control unit 400 sends the requested metadata to the metadata collection unit 140. The metadata collection unit 140 stores the metadata received from the execution control unit 400 in the metadata storage unit 150.

ステップS17の後、クエリ書き換え手段110は、クエリ中で書き込み指示されているデータとともにデータベースに書き込むメタデータをメタデータ蓄積手段150に要求する。データベースに書き込むべきメタデータの項目は、設定情報においてテーブルと対応付けられている項目であり、この項目はステップS17で特定している。クエリ書き換え手段110は、その項目のメタデータをメタデータ蓄積手段150に要求する。メタデータ蓄積手段150は、要求されたメタデータをクエリ書き換え手段110に送る。さらに、クエリ書き換え手段110は、ステップS15で生成されたクエリを、データベース501に書き込むデータおよびメタデータの各フィールド名と、データおよびメタデータを含めたクエリに変換する(ステップS18)。   After step S17, the query rewriting unit 110 requests metadata to be written to the database together with the data instructed to be written in the query to the metadata storage unit 150. The metadata item to be written in the database is an item associated with the table in the setting information, and this item is specified in step S17. The query rewriting unit 110 requests the metadata storage unit 150 for the metadata of the item. The metadata storage unit 150 sends the requested metadata to the query rewrite unit 110. Further, the query rewriting unit 110 converts the query generated in step S15 into a query including each field name of data and metadata to be written in the database 501 and the data and metadata (step S18).

ステップS18の後、クエリ書き換え手段110は、変換後のクエリをDBアクセス手段200に渡す(ステップS19)。DBアクセス手段200は、そのクエリをデータベースシステム500で独自に定められているコマンドに書き換え、コマンドをデータベースシステム500に送信する。この結果、データベースシステム500は、DBアクセス手段200から受信したコマンドに従って、指定されたデータおよびメタデータをデータベース501に書き込む。また、データベースシステムはその処理結果をDBアクセス手段200に返す。DBアクセス手段200は、データベースシステム500独自の形式で記述された処理結果をデータベース言語が定める形式に書き換える。DBアクセス仮想化手段100は、その処理結果を処理実行手段300に送る(ステップS20)。   After step S18, the query rewriting unit 110 passes the converted query to the DB access unit 200 (step S19). The DB access unit 200 rewrites the query into a command uniquely defined in the database system 500 and transmits the command to the database system 500. As a result, the database system 500 writes the specified data and metadata into the database 501 in accordance with the command received from the DB access means 200. Further, the database system returns the processing result to the DB access means 200. The DB access unit 200 rewrites the processing result described in a format unique to the database system 500 into a format determined by the database language. The DB access virtualization unit 100 sends the processing result to the process execution unit 300 (step S20).

ここでは、メタデータの収集をステップS14,S17に分けて行う場合を例にして説明したが、メタデータが処理実行手段300の処理経過とともに変化するか否かによらずに、ステップS17で各メタデータを収集してもよい。ただし、ステップS14,S17に分けてメタデータを収集した方が、メタデータを効率的に収集できるので好ましい。   Here, the case of collecting metadata in steps S14 and S17 has been described as an example. However, regardless of whether the metadata changes with the progress of the processing of the processing execution unit 300, each step in step S17 Metadata may be collected. However, it is preferable to collect metadata in steps S14 and S17 because the metadata can be collected efficiently.

次に、図10を参照して、処理実行手段300がデータを読み込むクエリを生成する場合の動作を説明する。処理実行手段300は指定された処理モジュール301に従って処理を行い、その処理において、データベース501からのデータの読み込みを指示するクエリを生成する(ステップS21)。処理実行手段300は、例えばSQL等のデータベース言語によりクエリを生成する。   Next, with reference to FIG. 10, an operation when the process execution unit 300 generates a query for reading data will be described. The processing execution means 300 performs processing according to the designated processing module 301, and generates a query that instructs reading of data from the database 501 in the processing (step S21). The process execution unit 300 generates a query using a database language such as SQL, for example.

データの読み込みを指示するクエリが生成されると、DBアクセス仮想化手段100が有するクエリ書き換え手段110(図2参照)は、そのクエリを変換せずにDBアクセス手段200に送る(ステップS22)。DBアクセス手段200は、そのクエリをデータベースシステム500で独自に定められているコマンドに書き換え、コマンドをデータベースシステム500に送信する。この結果、データベースシステム500は、DBアクセス手段200から受信したコマンドに従って、データベース501からデータを読み込み、DBアクセス手段200に送信する。このときデータベース501から読み出された読み込みデータには、データ書き込み時に追加されたメタデータが含まれている場合もある。   When a query for instructing data reading is generated, the query rewriting means 110 (see FIG. 2) of the DB access virtualization means 100 sends the query to the DB access means 200 without conversion (step S22). The DB access unit 200 rewrites the query into a command uniquely defined in the database system 500 and transmits the command to the database system 500. As a result, the database system 500 reads data from the database 501 according to the command received from the DB access means 200 and transmits it to the DB access means 200. At this time, the read data read from the database 501 may include metadata added at the time of data writing.

データベースシステム500がDBアクセス手段200に送信したデータは、データベースシステム500独自の形式で記述されている。DBアクセス手段200は、そのデータをデータベース言語が定める形式に書き換え、クエリ書き換え手段110に送る。   Data transmitted from the database system 500 to the DB access means 200 is described in a format unique to the database system 500. The DB access means 200 rewrites the data into a format determined by the database language and sends it to the query rewrite means 110.

クエリ書き換え手段110は、読み込みデータをDBアクセス手段200から受けると、その読み込みデータ内にメタデータが含まれているか否かを判定する。例えば、設定情報を参照してメタデータのフィールド名を特定し、読み込みデータ中にそのフィールドのデータが含まれているか否かを判定する。クエリ書き換え手段110は、読み込みデータ中に、メタデータのフィールドのデータが存在していれば、そのメタデータを削除する(ステップS23)。そして、クエリ書き換え手段110は、メタデータを削除した後のデータを処理実行手段300に送る(ステップS24)。なお、読み込みデータにメタデータが存在していなければ、クエリ書き換え手段110は、そのデータをそのまま処理実行手段300に送る。   When the query rewrite means 110 receives the read data from the DB access means 200, the query rewrite means 110 determines whether or not the read data contains metadata. For example, the field name of the metadata is specified with reference to the setting information, and it is determined whether or not the data of the field is included in the read data. If there is metadata field data in the read data, the query rewriting means 110 deletes the metadata (step S23). Then, the query rewriting unit 110 sends the data after deleting the metadata to the process execution unit 300 (step S24). If there is no metadata in the read data, the query rewrite unit 110 sends the data to the process execution unit 300 as it is.

次に、本実施の形態の効果について説明する。
本発明のデータベース接続システムは、クエリで書き込み指示されるデータとともにデータベース501に書き込むメタデータの項目を定めた設定情報を予め記憶する。また、メタデータ収集手段140は、実行制御手段400からメタデータを収集する。そして、データベース501へのデータの書き込みを指示するクエリが生成されると、クエリ書き換え手段110は、クエリで指示されたデータだけでなく設定情報で定められたメタデータもデータベース501に書き込むようにクエリを変換する。従って、処理モジュール301を改造することなく、メタデータをデータベース501に書き込むことができる。また、各処理モジュール301の実行によってデータベース501に書き込まれたデータおよびメタデータを用いて、統合データ分析システム(図示せず。)は、各処理モジュール301の実行結果に対する分析を行うことができる。
Next, the effect of this embodiment will be described.
The database connection system according to the present invention stores in advance setting information that defines items of metadata to be written to the database 501 together with data to be written by a query. The metadata collection unit 140 collects metadata from the execution control unit 400. When a query instructing data writing to the database 501 is generated, the query rewriting unit 110 writes not only the data instructed by the query but also the metadata defined by the setting information to the database 501. Convert. Therefore, metadata can be written in the database 501 without modifying the processing module 301. Further, the integrated data analysis system (not shown) can analyze the execution result of each processing module 301 by using the data and metadata written in the database 501 by the execution of each processing module 301.

また、処理モジュール301の実行時に処理実行手段300がデータベース501からのデータの読み込みを指示するクエリを生成し、そのクエリに基づいて読み込んだ読み込みデータの中にメタデータが含まれている場合、DBアクセス仮想化手段100は、読み込みデータの中からメタデータを削除する。従って、メタデータに対する処理を行わない処理実行手段300にメタデータが送られてしまうことを防止することができる。   Further, when the processing execution unit 300 executes the processing module 301 and generates a query instructing to read data from the database 501, and the read data read based on the query includes metadata, the DB The access virtualization unit 100 deletes metadata from the read data. Therefore, it is possible to prevent the metadata from being sent to the process execution unit 300 that does not perform the process on the metadata.

また、書き換え設定手段120に設定情報が入力され、書き換え設定手段120は、入力された設定情報を書き換え設定蓄積手段130に記憶させる。従って、利用者が所望の設定情報を入力し、その設定情報に基づいてメタデータを追加することができる。   In addition, setting information is input to the rewrite setting unit 120, and the rewrite setting unit 120 stores the input setting information in the rewrite setting storage unit 130. Therefore, the user can input desired setting information and add metadata based on the setting information.

設定情報内において、処理モジュールの実行時刻がメタデータの項目として定められていることが好ましい。この場合、メタデータ収集手段140は実行制御手段400から処理モジュールの実行時刻を収集し、クエリ書き換え手段110は、その実行時刻もデータベースに書き込まれるようにクエリを書き換える。この結果、統合データ分析システム(図示せず。)は、処理モジュール301の実行時刻の時系列に沿って、データベース501に書き込まれたデータのデータ量や質がどのように変換したのかを分析することができる。   In the setting information, the execution time of the processing module is preferably defined as a metadata item. In this case, the metadata collecting unit 140 collects the execution time of the processing module from the execution control unit 400, and the query rewriting unit 110 rewrites the query so that the execution time is also written in the database. As a result, the integrated data analysis system (not shown) analyzes how the data amount and quality of the data written in the database 501 are converted along the time series of the execution time of the processing module 301. be able to.

また、設定情報内において、処理モジュール301の処理対象となるデータを作成したユーザのユーザ名が、メタデータの項目として定められていることが好ましい。この場合、ユーザ単位でのデータ分析を行うことができる。例えば、処理モジュール301がファイルクローラであり、処理実行手段300がファイルを収集するとする。この場合、設定情報においてユーザ名がメタデータとして定められていれば、統合データ分析システム(図示せず。)は、ファイル作成者毎にファイルに関する分析を行うことができる。   In the setting information, it is preferable that the user name of the user who created the data to be processed by the processing module 301 is defined as a metadata item. In this case, data analysis can be performed for each user. For example, it is assumed that the processing module 301 is a file crawler and the process execution unit 300 collects files. In this case, if the user name is defined as metadata in the setting information, the integrated data analysis system (not shown) can perform file analysis for each file creator.

また、上記の実施形態では、データベース501から読み込んだ読み込みデータからメタデータを削除する場合を説明した。全フィールドのデータを意味する記号を含むクエリであって、その全フィールドのデータの読み込みを指示するクエリを処理実行手段300が生成した場合に、クエリ書き換え手段110がそのクエリを書き換えることによって、メタデータを読み込まないようにしてもよい。この場合にも、処理実行手段300にメタデータを送らないようにすることができる。   In the above-described embodiment, the case where the metadata is deleted from the read data read from the database 501 has been described. When the processing execution unit 300 generates a query that includes symbols indicating data of all fields and instructs the reading of the data of all fields, the query rewriting unit 110 rewrites the query, Data may not be read. Also in this case, it is possible to prevent the metadata from being sent to the process execution unit 300.

この場合、クエリ書き換え手段110は、処理実行手段300が生成したクエリであって、データベース501に対してデータを書き込むことを指示するクエリで指定されたフィールド名を全て記憶しておく。そして、全フィールドのデータを意味する記号(例えば“* ”)を含むクエリであって、その全フィールドのデータの読み込みを指示するクエリを処理実行手段300が生成した場合、全フィールドのデータを意味する記号を、記憶しているフィールド名(データを書き込むことを指示するクエリで指定された各フィールド名)に置き換えればよい。この場合、データベース501から全フィールドのデータが読み込まれず、データ書き込みのためのクエリで指定されたフィールドのデータ(すなわちメタデータ以外のデータ)が読み込まれる。よって、クエリ書き換え手段110は、読み込みデータからメタデータを削除しなくてよい。また、処理実行手段300にメタデータを送らないようにすることができる。   In this case, the query rewriting unit 110 stores all the field names specified by the query generated by the process execution unit 300 and instructing to write data to the database 501. When the processing execution unit 300 generates a query including a symbol (for example, “*”) indicating data of all fields and instructing reading of the data of all fields, it means the data of all fields. May be replaced with a stored field name (each field name specified in a query instructing to write data). In this case, the data of all fields is not read from the database 501, but the data of the field specified by the query for writing data (that is, data other than the metadata) is read. Therefore, the query rewriting unit 110 does not have to delete the metadata from the read data. Further, it is possible to prevent the metadata from being sent to the process execution unit 300.

次に、本発明の動作の具体例を説明する。図11は、データベース接続システムの例を示すブロック図であり、図1に示す構成要素と同様の構成要素については、図1と同一の符号を付し、説明を省略する。図11に示すPCファイルクローラ301aおよび分析モジュール301bは、いずれも図1に示す処理モジュール301に該当する。以下、処理実行手段300が、PCファイルクローラ301aおよび分析モジュール301bに従って動作する場合を例にして説明する。また、図11では、DBアクセスモジュール201がJDBCである場合を例示している。   Next, a specific example of the operation of the present invention will be described. FIG. 11 is a block diagram illustrating an example of a database connection system. Components similar to those shown in FIG. 1 are denoted by the same reference numerals as those in FIG. Each of the PC file crawler 301a and the analysis module 301b shown in FIG. 11 corresponds to the processing module 301 shown in FIG. Hereinafter, the case where the process execution unit 300 operates according to the PC file crawler 301a and the analysis module 301b will be described as an example. FIG. 11 illustrates a case where the DB access module 201 is a JDBC.

PCファイルクローラ301aは、通信ネットワーク上のPC(パーソナルコンピュータ)に蓄積されているファイル(Webページ)に関する情報を処理実行手段300に収集させる処理モジュールである。処理実行手段300は、PCファイルクローラ301aに従って、イントラネット上のPCに蓄積されているファイルに関する情報を収集し、その情報をデータベース501に書き込むためのクエリを生成する。ここでは、処理実行手段300が収集する情報に、PC内でのファイルの位置情報とファイルの本文(テキスト)が含まれているものとする。また、ファイルの位置情報は、ファイルが格納されているフォルダのフォルダ名とファイル名とを含む。   The PC file crawler 301a is a processing module that causes the process execution unit 300 to collect information on files (Web pages) stored in a PC (personal computer) on a communication network. The process execution unit 300 collects information about files stored in the PC on the intranet according to the PC file crawler 301a, and generates a query for writing the information to the database 501. Here, it is assumed that the information collected by the process execution means 300 includes file position information in the PC and the text of the file (text). The file position information includes the folder name and file name of the folder in which the file is stored.

分析モジュール301bは、データベース501に蓄積された情報(ファイルに関する情報)を処理実行手段300に読み取らせて、その情報に対する分析を行わせる処理モジュールである。処理実行手段300は、分析モジュール301bに従って、PC内でのファイルの位置情報およびそのファイルの本文(テキスト)から、ファイルサイズを求め、検索インデックスを作成する等の処理を行う。   The analysis module 301b is a processing module that causes the process execution unit 300 to read information stored in the database 501 (information related to a file) and analyze the information. The process execution means 300 performs processes such as obtaining the file size from the position information of the file in the PC and the text (text) of the file and creating a search index according to the analysis module 301b.

PCファイルクローラ301aと分析モジュール301bとの組により、個々のPCのファイル検索(PCデスクトップ検索)を実現でき、PCファイルクローラ301aと分析モジュール301bとの組は、PC毎に用意される。   A file search (PC desktop search) of each PC can be realized by the combination of the PC file crawler 301a and the analysis module 301b, and the combination of the PC file crawler 301a and the analysis module 301b is prepared for each PC.

統合データ分析システム91は、データベース501を参照し、ある一定期間に収集されたファイルに関する情報を分析して、PC間でのファイル受け渡し状況等の時系列での変化を分析する分析システムである。   The integrated data analysis system 91 is an analysis system that refers to the database 501 and analyzes information on files collected during a certain period to analyze changes in time series such as file delivery status between PCs.

PCファイルクローラ301aは、ファイルの位置情報と本文の組をPCから収集し、ファイルのIDを付加してデータベース501に書き込む処理を処理実行手段300に実行させる。図12は、このような処理で用いられるテーブルの例を示す説明図である。PCファイルクローラ301aはメタデータを書き込む処理やメタデータを読み込む処理を処理実行手段300に行わせない。よって、PCファイルクローラ301aに従って動作する処理実行手段300がデータの読み書きを行うテーブルには、図12に例示するように、ファイルのID、位置情報、およびテキストのフィールドが含まれ、メタデータのフィールドは含まれない。データベース接続システム10が、図12に例示するテーブルを新規作成することを指示するクエリを生成する手段(図示せず。)を備えていてもよい。あるいは、データベース接続システム10以外の装置またはデータベース接続システム10の利用者によって、テーブルを新規作成することを指示するクエリが入力されてもよい。   The PC file crawler 301a causes the process execution unit 300 to execute a process of collecting file position information and a set of text from the PC, adding the file ID, and writing the data to the database 501. FIG. 12 is an explanatory diagram showing an example of a table used in such processing. The PC file crawler 301a does not cause the processing execution unit 300 to perform processing for writing metadata or processing for reading metadata. Therefore, the table in which the process execution unit 300 operating according to the PC file crawler 301a reads and writes data includes file ID, position information, and text fields as illustrated in FIG. 12, and includes metadata fields. Is not included. The database connection system 10 may include means (not shown) for generating a query that instructs to create a new table illustrated in FIG. Alternatively, a query instructing to create a new table may be input by a device other than the database connection system 10 or a user of the database connection system 10.

DBアクセス仮想化手段100がテーブルの新規作成を指示するクエリをそのままDBアクセス手段200に送ってもよい。この場合、データベースシステム500は、図12に例示するフィールドを有するテーブルを作成する。また、本例において統合データ分析システム91は、ファイルを収集した日時と、ファイルの収集対象とされたPC名をメタデータとして使用するものとする。このため、図12に例示するテーブルに対して、ファイル収集日時とファイル収集対象とされたPC名のフィールドを追加する必要がある。図13は、図12に例示するテーブルにメタデータとなる日時およびファイル名のフィールドを追加したテーブルの例を示す説明図である。クエリ書き換え手段110が、メタデータも書き込まれるようにクエリを変換し、そのクエリによりデータベースへのメタデータの書き込みを可能とするためには、図13に例示するテーブルを用意しなければならない。図12に例示するテーブルを作成した後、例えば、データベース接続システム10の利用者が手作業で、日時およびPC名のフィールドを追加してもよい。また、データベース接続システム10の利用者は、データベース501に書き込むデータに対して日時およびPC名が追加されるように定めた設定情報を書き換え設定手段120に入力し、書き換え設定手段120は、入力された設定情報を書き換え設定蓄積手段130に記憶させる。   The DB access virtualization unit 100 may send a query for instructing the creation of a new table to the DB access unit 200 as it is. In this case, the database system 500 creates a table having fields illustrated in FIG. In this example, it is assumed that the integrated data analysis system 91 uses the date and time when the file is collected and the PC name that is the collection target of the file as metadata. For this reason, it is necessary to add a file collection date and a PC name field as a file collection target to the table illustrated in FIG. FIG. 13 is an explanatory diagram showing an example of a table in which fields of date and time as metadata are added to the table illustrated in FIG. In order for the query rewriting unit 110 to convert a query so that metadata is also written, and to enable writing of metadata to the database by the query, a table illustrated in FIG. 13 must be prepared. After creating the table illustrated in FIG. 12, for example, the user of the database connection system 10 may add the date / time and PC name fields manually. Further, the user of the database connection system 10 inputs the setting information determined so that the date and the PC name are added to the data to be written in the database 501 to the rewrite setting unit 120, and the rewrite setting unit 120 is input. The set information is stored in the rewrite setting storage means 130.

また、テーブルにメタデータのフィールドを追加する処理を利用者が手作業で行うのではなく、DBアクセス仮想化手段100が自動的に行ってもよい。なお、この場合、メタデータの項目は予め設定情報で定められているものとする。DBアクセス仮想化手段100のクエリ書き換え手段110は、新規テーブルの生成を指示するクエリに対して、設定情報で定められたメタデータの項目を新たなフィールドとして新規テーブルに追加するようにクエリを変換する。例えば、図11に示すテーブルを新規に作成するためのクエリとして、例えば、create table t1 (id int,位置情報 text, テキスト text)というSQL文が入力されたとする。そして、設定情報において、メタデータとして日時およびPC名が定められているとする。クエリ書き換え手段110は、このメタデータの項目を新たなフィールドとして新規テーブルに追加するように、上記のSQL文にメタデータのフィールド名を追加する。すなわち、新規テーブルの生成を指示するSQL文(create table文)においてフィールド名を記述する部分(すなわち、create table文の括弧内)に、メタデータのフィールド名を追加する。なお、create table文では、フィールド名およびデータ型が記述されるので、クエリ書き換え手段110は、メタデータのフィールド名およびデータ型をcreate table文に追加すればよい。例えば、クエリ書き換え手段110は、入力された上記のSQL文を、create talbe t1 (id int, 位置情報text, テキスト text,PC名 text, 時刻 time)というSQL文に変換する。データ型は、例えば、設定情報において定めておけばよい。クエリ書き換え手段110は、変換後のクエリをDBアクセス手段200に送る。この結果、自動的に図13に例示するテーブルが作成される。   Further, the DB access virtualization unit 100 may automatically perform the process of adding the metadata field to the table instead of the manual operation by the user. In this case, it is assumed that metadata items are determined in advance in the setting information. The query rewriting unit 110 of the DB access virtualization unit 100 converts the query so that a metadata item defined in the setting information is added to the new table as a new field in response to the query instructing generation of the new table. To do. For example, it is assumed that an SQL statement “create table t1 (id int, position information text, text text)” is input as a query for newly creating the table shown in FIG. In the setting information, it is assumed that the date and time and the PC name are defined as metadata. The query rewriting means 110 adds the metadata field name to the above SQL statement so that the metadata item is added to the new table as a new field. In other words, the field name of the metadata is added to the part describing the field name in the SQL statement (create table statement) instructing generation of a new table (that is, in the parentheses of the create table statement). Since the create table statement describes the field name and data type, the query rewrite means 110 may add the metadata field name and data type to the create table statement. For example, the query rewriting unit 110 converts the input SQL sentence into an SQL sentence of create talbe t1 (id int, position information text, text text, PC name text, time time). The data type may be determined in the setting information, for example. The query rewriting unit 110 sends the converted query to the DB access unit 200. As a result, the table illustrated in FIG. 13 is automatically created.

次に、処理実行手段300がPCファイルクローラ301aに従ってファイル(Webページ)を収集する動作を説明する。処理実行手段300は、インターネットから順次Webページを収集し、収集したWebページのID、位置情報および本文(テキスト)をテーブルに書き込むクエリ(例えば、SQLのinsert into 文)を生成する。insert into 文では、最初にテーブル名を指定し、次のかっこ書きでフィールド名を指定し、その後に続ける文字列valuesの次の括弧で書き込むデータを指定する。なお、IDとしては、収集したWebページの順番を表す数値を用いればよい。処理実行手段300は、Webページの収集し、例えば、insert into t1 (id, 位置情報, テキスト) values (100,’c:\foo\index.html’,’<html>・・・</html>’)等のクエリを生成する。このように、処理実行手段300は、書き込むデータのフィールド名およびデータを含むクエリを生成する。   Next, an operation in which the process execution unit 300 collects files (Web pages) according to the PC file crawler 301a will be described. The process execution unit 300 sequentially collects Web pages from the Internet, and generates a query (for example, an SQL insert into statement) that writes the ID, position information, and text (text) of the collected Web pages to a table. In the insert into statement, first specify the table name, specify the field name with the next parenthesis, and specify the data to be written in the parentheses following the string value that follows. As the ID, a numerical value indicating the order of the collected Web pages may be used. The process execution means 300 collects Web pages and inserts, for example, insert into t1 (id, position information, text) values (100, 'c: \ foo \ index.html', '<html> ... </ html > ') Etc. is generated. In this way, the process execution unit 300 generates a query including the field name of the data to be written and the data.

DBアクセス仮想化手段100は、このクエリに対して、メタデータのフィールド名(PC名、日時)と、メタデータを追加する。すなわち、DBアクセス仮想化手段100は、上記のinsert into 文を、insert into t1 (id, 位置情報, テキスト,PC名, 時刻) values (100,’c:\foo\index.html’,’<html>・・・</html>’,’PC1’,’2007/1/1 10:00:01’)というinsert into 文に変換する。変換後のクエリでは、最初から定められていたデータのフィールド名およびデータに加えて、メタデータのフィールド名(PC名、 時刻)とそのメタデータ(’PC1’,’2007/1/1 10:00:01’)も含まれている。   The DB access virtualization unit 100 adds metadata field names (PC name, date and time) and metadata to the query. That is, the DB access virtualization unit 100 converts the above insert into statement into insert into t1 (id, location information, text, PC name, time) values (100, 'c: \ foo \ index.html', '< html> ... </ html> ',' PC1 ',' 2007/1/1 10:00:01 '). In the converted query, in addition to the field name and data of the data defined from the beginning, the metadata field name (PC name, time) and its metadata ('PC1', '2007/1/1 10: 00:01 ') is also included.

このDBアクセス仮想化手段100の処理をより具体的に説明する。利用者によって予め”add date as DATE; add pcname as PC名”の設定情報が書き換え設定手段120に入力され、書き換え設定手段120はその設定情報を書き換え設定蓄積手段130に記憶させているとする。なお、上記の”add date as DATE; add pcname as PC名”は設定情報の例示であり、設定情報は他の書式で記述されていてもよい。メタデータ収集手段140は、設定情報で定められたメタデータの項目(pcnameおよびdate)を実行制御手段400に要求する。実行制御手段400は、この要求に応じてPC名とデータベースへの書き込み時刻(現在時刻)をメタデータ収集手段140に提供し、メタデータ収集手段140は、PC名および時刻をメタデータ蓄積手段150に蓄積する。また、クエリ書き換え手段110は、設定情報で定められたPC名および日時をメタデータ蓄積手段150に要求し、PC名および日時を取得する。そして、処理実行手段300が生成したクエリに対して、メタデータのフィールド名およびメタデータを追加することによって、insert into t1 (id, 位置情報, テキスト,PC名, 時刻) values (100,’c:\foo\index.html’,’<html>・・・</html>’,’PC1’,’2007/1/1 10:00:01’)というクエリに変換し、変換後のクエリをDBアクセス手段200に送る。   The processing of the DB access virtualization unit 100 will be described more specifically. It is assumed that setting information “add date as DATE; add pcname as PC name” is input to the rewrite setting unit 120 in advance by the user, and the rewrite setting unit 120 stores the setting information in the rewrite setting storage unit 130. The above “add date as DATE; add pcname as PC name” is an example of setting information, and the setting information may be described in another format. The metadata collection means 140 requests the execution control means 400 for metadata items (pcname and date) defined by the setting information. In response to this request, the execution control unit 400 provides the PC name and the write time (current time) to the database to the metadata collection unit 140, and the metadata collection unit 140 supplies the PC name and time to the metadata storage unit 150. To accumulate. Further, the query rewriting unit 110 requests the metadata storage unit 150 for the PC name and date determined by the setting information, and acquires the PC name and date. Then, by adding the metadata field name and metadata to the query generated by the process execution means 300, insert into t1 (id, location information, text, PC name, time) values (100, 'c : \ foo \ index.html ',' <html> ... </ html> ',' PC1 ',' 2007/1/1 10:00:01 ') The data is sent to the DB access means 200.

DBアクセス手段200は、変換後のクエリをデータベースシステム500独自のコマンドに変換し、変換後のコマンドをデータベースシステム500に送信する。データベースシステム500は、そのコマンドに従って、処理実行手段300が指定したID、位置情報およびテキストに、メタデータ(PC名および日時)を追加したレコードをデータベース501に書き込む。   The DB access means 200 converts the converted query into a command unique to the database system 500, and transmits the converted command to the database system 500. In accordance with the command, the database system 500 writes a record in which metadata (PC name and date / time) is added to the ID, position information, and text specified by the process execution unit 300 in the database 501.

また、処理実行手段300は、分析モジュール301bに従って動作するときに、データベース501のデータを読み込むSQLを生成し、分析処理を行う。このとき、データを読み込むSQLによって、分析モジュール301bが処理対象としないメタデータもデータベース501から読み込まれることがある。例えば、PCファイルクローラ301aにより書き込まれたデータベース内のデータを全て読み込んで順次、分析処理する場合、全フィールドのデータを意味する記号を用いたクエリを生成する。例えば、全フィールドのデータを意味する“* ”記号を用いて、“select * from t1”等のSQL文を生成する。このSQL文はテーブルt1の全データを読み込むことを意味している。この分析モジュール301bはメタデータを扱わないので、図12に例示するテーブルから全データを読み込む目的で上記のSQL文が生成されたとしても、実際には図13に例示するテーブルからPC名および日時も読み込まれることになる。DBアクセス手段200が“select * from t1”をデータベースシステム500独自のコマンドに変換し、データベースシステム500はそのコマンドに基づいて、図13に例示するテーブルから、ID、位置情報、テキスト、PC名および日時の各データを全て読み込む。データベース接続システム500が読み込んだ読み込みデータは、DBアクセス手段200を介してDBアクセス仮想化手段100に送られる。DBアクセス仮想化手段100は、設定情報を参照して、PC名および日時がメタデータであると判定し、読み込みデータの中からフィールド名がPC名であるデータと、フィールド名が日時であるデータとを削除する。そして、削除後のデータを処理実行手段300に送る。この結果、処理実行手段300にはメタデータではないID、位置情報、テキストが送られ、処理実行手段300は、これらのデータを用いた分析処理を行う。   Further, when the process execution unit 300 operates in accordance with the analysis module 301b, the process execution unit 300 generates SQL for reading data in the database 501 and performs analysis processing. At this time, metadata that is not processed by the analysis module 301b may also be read from the database 501 by SQL for reading data. For example, when all the data in the database written by the PC file crawler 301a is read and sequentially analyzed, a query using symbols representing the data of all fields is generated. For example, an SQL statement such as “select * from t1” is generated using a “*” symbol indicating data of all fields. This SQL statement means reading all data in the table t1. Since the analysis module 301b does not handle metadata, even if the above SQL statement is generated for the purpose of reading all data from the table illustrated in FIG. 12, the PC name and date / time are actually determined from the table illustrated in FIG. Will also be loaded. The DB access means 200 converts “select * from t1” into a command unique to the database system 500, and the database system 500 uses the ID, position information, text, PC name, and ID from the table illustrated in FIG. 13 based on the command. Read all date and time data. The read data read by the database connection system 500 is sent to the DB access virtualization means 100 via the DB access means 200. The DB access virtualization unit 100 refers to the setting information to determine that the PC name and date / time are metadata, and from the read data, data whose field name is the PC name and data whose field name is the date / time. And delete. Then, the deleted data is sent to the process execution means 300. As a result, ID, position information, and text that are not metadata are sent to the process execution unit 300, and the process execution unit 300 performs an analysis process using these data.

なお、クエリ書き換え手段110は、処理実行手段300が生成した“select * from t1”において全フィールドのデータを意味する記号“*”を、メタデータ以外の各フィールドのデータのフィールド名に置き換える変換を行ってもよい。例えば、“select * from t1”というクエリを、“select id,url,本文 from t1 where PC名 like PC1”のようなクエリに変換してもよい。そして、その変換後のクエリに基づいて、データの読み込みを行ってもよい。   Note that the query rewriting unit 110 performs conversion by replacing the symbol “*” indicating the data of all fields in “select * from t1” generated by the processing execution unit 300 with the field names of the data of each field other than the metadata. You may go. For example, a query “select * from t1” may be converted into a query such as “select id, url, body from t1 where PC name like PC1”. Then, data may be read based on the converted query.

このように処理実行手段300が生成したデータ読み込みのためのクエリを書き換える場合、クエリ書き換え手段110は、処理実行手段300が生成したデータ書き込みのためのクエリ内で指定されたフィールド名(id、位置情報、PC名)を記憶しておく。そして、データ読み込みのためのクエリ内に、全フィールドのデータを意味する記号(例えば“* ”)が含まれている場合、その記号を、データ書き込みのためのクエリ内で指定された全フィールド名(id、位置情報、PC名)に置き換える。この場合、メタデータ以外のデータが読み出されるので、メタデータの削除処理は行わなくてよい。   When the query for data reading generated by the process execution unit 300 is rewritten as described above, the query rewrite unit 110 uses the field name (id, position) specified in the query for data writing generated by the process execution unit 300. Information, PC name). And if the query for reading data contains a symbol (for example, “*”) that means the data of all fields, the symbol is used for all field names specified in the query for writing data. Replace with (id, location information, PC name). In this case, since data other than metadata is read out, it is not necessary to delete the metadata.

このような動作により、PCファイルクローラ301aおよび分析モジュール301bを改造しなくても、データベース501には、統合データ分析システムが分析を行う際に用いるメタデータ(本例ではPC名および日時)も書き込まれるようにすることができる。また、データベース501からデータを読み出す際には、処理モジュールが処理対象としないデータのみを選別し、不要なメタデータを処理実行手段300に送らないようにすることができる。   By such an operation, even if the PC file crawler 301a and the analysis module 301b are not modified, metadata (PC name and date / time in this example) used when the integrated data analysis system performs analysis is also written in the database 501. Can be made. Further, when reading data from the database 501, it is possible to select only data not to be processed by the processing module and prevent unnecessary metadata from being sent to the processing execution means 300.

なお、上記の例のようにPC名および日時をメタデータとして追加することによって、統合データ分析システム91は、時間経過に伴って、ファイルがどのPCからどのPCに移動されたか等を分析することができる。   Note that by adding the PC name and date and time as metadata as in the above example, the integrated data analysis system 91 analyzes from which PC the file has been moved to which PC over time, etc. Can do.

例えば、時刻t1においてファイル“file1.txt”がPC1から収集され、ファイル“file2.txt”がPC2から収集されたとする。そして、“file1.txt”に関する情報がメタデータt1,PC1とともにデータベース501に書き込まれ、“file2.txt”に関する情報がメタデータt1,PC2とともにデータベース501に書き込まれたとする。同様に、時刻t2においてファイル“file1.txt”がPC1,PC3から収集され、ファイル“file2.txt”がPC3から収集されたとする。メタデータt2,PC1とともに“file1.txt”に関する情報がデータベース501に書き込まれ、メタデータt2,PC3とともに“file1.txt”に関する情報がデータベース501に書き込まれさらに、メタデータt2,PC3とともに“file2.txt”に関する情報がデータベース501に書き込まれたとする。統合データ分析システム91は、これらのデータに基づいて、PC1からPC3に“file1.txt”がコピーされ、PC2からPC3に“file2.txt”が移動されたと分析することができる。   For example, it is assumed that the file “file1.txt” is collected from the PC1 and the file “file2.txt” is collected from the PC2 at the time t1. It is assumed that information regarding “file1.txt” is written in the database 501 together with the metadata t1 and PC1, and information regarding “file2.txt” is written in the database 501 along with the metadata t1 and PC2. Similarly, it is assumed that the file “file1.txt” is collected from the PC1 and PC3 and the file “file2.txt” is collected from the PC3 at time t2. Information about “file1.txt” is written into the database 501 together with the metadata t2 and PC1, information about “file1.txt” is written into the database 501 together with the metadata t2 and PC3, and “file2. It is assumed that information regarding “txt” is written in the database 501. Based on these data, the integrated data analysis system 91 can analyze that “file1.txt” has been copied from PC1 to PC3 and “file2.txt” has been moved from PC2 to PC3.

次に、本発明の概要について説明する。図14は、本発明の概要を示す説明図である。本発明のデータベース接続システム10は、設定情報記憶手段51と、メタデータ収集手段52と、書き込みクエリ変換手段53とを備える。   Next, the outline of the present invention will be described. FIG. 14 is an explanatory diagram showing an outline of the present invention. The database connection system 10 of the present invention includes setting information storage means 51, metadata collection means 52, and write query conversion means 53.

また、メタデータ保持手段54は、メタデータを保持し、メタデータ収集手段52からの要求に応じてメタデータをメタデータ収集手段52に提供する。   The metadata holding unit 54 holds the metadata and provides the metadata to the metadata collecting unit 52 in response to a request from the metadata collecting unit 52.

設定情報記憶手段51は、設定情報を記憶している。メタデータ収集手段52は、設定情報で定められた項目のメタデータをメタデータ保持手段54に要求し、メタデータ保持手段54からメタデータを収集する。   The setting information storage unit 51 stores setting information. The metadata collection unit 52 requests the metadata holding unit 54 for metadata of items determined by the setting information, and collects metadata from the metadata holding unit 54.

そして、書き込みクエリ変換手段53は、データベースへのデータの書き込みを指示するクエリを、そのデータおよび設定情報で定められた項目のメタデータの書き込みを指示するクエリに変換する。   Then, the write query conversion means 53 converts the query for instructing writing of data into the database into a query for instructing writing of metadata of items defined by the data and setting information.

このように、本発明では、クエリを生成する処理モジュールではなく、生成されたクエリを変換する。また、本発明では、データベースへのデータの書き込みを指示するクエリから、そのデータと、設定情報で定められた項目のメタデータとを書き込むためのクエリに変換するので、変換後のクエリによってデータとメタデータの双方をデータベースに書き込むことができる。従って、本発明では、処理モジュールを改造することなく、処理モジュールが生成したクエリで書き込み指示されたデータと、メタデータの双方をデータベースに書き込むことができる。   Thus, in the present invention, the generated query is converted instead of the processing module that generates the query. Further, in the present invention, the query for instructing the writing of data to the database is converted into a query for writing the data and the metadata of the item defined in the setting information. Both metadata can be written to the database. Therefore, in the present invention, it is possible to write both the data instructed by the query generated by the processing module and the metadata to the database without modifying the processing module.

また、上記の実施形態では、データベースから読み込んだ読み込みデータの中から、設定情報で定められた項目のメタデータを削除するメタデータ削除手段を備える構成が開示されている。   Further, the above embodiment discloses a configuration including metadata deleting means for deleting metadata of items defined by setting information from read data read from a database.

また、上記の実施形態では、データベースへのデータの書き込みを指示するクエリで指定されたフィールド名を全て記憶するフィールド名記憶手段と、全フィールドのデータの読み込みを指示するクエリに含まれる全フィールドのデータを意味する記号を、フィールド名記憶手段が記憶する各フィールド名に置き換えることにより、そのクエリを変換する読み込みクエリ変換手段とを備える構成も開示されている。   In the above embodiment, the field name storage means for storing all the field names specified by the query for instructing the data writing to the database, and all the fields included in the query for instructing the reading of the data for all fields. There is also disclosed a configuration including reading query conversion means for converting the query by replacing symbols representing data with respective field names stored in the field name storage means.

また、上記の実施形態では、新規テーブルの生成を指示するクエリで指定された新規テーブルのフィールド名に、設定情報で定められたメタデータの項目を追加することにより、そのクエリを変換するテーブル生成クエリ変換手段を備える構成が開示されている。   Further, in the above embodiment, table generation for converting a query by adding a metadata item defined in the setting information to the field name of the new table specified by the query instructing generation of the new table. A configuration including query conversion means is disclosed.

また、上記の実施形態では、メタデータ収集手段が、データベースへのデータの書き込みを指示するクエリを生成する1つまたは複数のソフトウェアの中の最初のソフトウェアが起動されるときに、各ソフトウェアが順次実行されていく経過に伴って変化しないメタデータを収集し、個々のソフトウェアが起動されるときに、各ソフトウェアが順次実行されていく経過に伴って変化するメタデータを収集する構成が開示されている。   Further, in the above-described embodiment, when the first software among the one or a plurality of software that generates a query instructing writing of data to the database is started by the metadata collecting unit, each software is sequentially executed. A configuration is disclosed that collects metadata that does not change with the progress of execution and collects metadata that changes with the progress of each software when each software is started up. Yes.

また、上記の実施形態では、設定情報が入力される設定情報入力手段と、設定情報入力手段に入力された設定情報を設定情報記憶手段に記憶させる設定情報登録手段とを備える構成が開示されている。   In the above embodiment, a configuration is disclosed that includes setting information input means for inputting setting information, and setting information registration means for storing the setting information input to the setting information input means in the setting information storage means. Yes.

本発明は、クエリを生成させる処理モジュールを改造することなく、そのクエリで指定されたデータ以外のデータをデータベースに登録させるシステムに好適に適用される。   The present invention is suitably applied to a system for registering data other than data specified by a query in a database without modifying a processing module that generates the query.

本発明のデータベース接続システムの例を示すブロック図である。It is a block diagram which shows the example of the database connection system of this invention. DBアクセス仮想化手段を示すブロック図である。It is a block diagram which shows DB access virtualization means. 設定情報の例を示す説明図である。It is explanatory drawing which shows the example of setting information. 設定情報の例を示す説明図である。It is explanatory drawing which shows the example of setting information. データベースシステムとデータベース接続システムとが同一の装置である場合の構成例を示すブロック図である。It is a block diagram which shows the structural example in case a database system and a database connection system are the same apparatuses. 処理モジュールが複数台のデータベース接続システムに分散されている場合の構成例を示すブロック図である。It is a block diagram which shows the example of a structure in case a processing module is distributed by the several database connection system. データベース接続システムおよび統合データ分析システムの動作の例を示すフローチャートである。It is a flowchart which shows the example of operation | movement of a database connection system and an integrated data analysis system. 設定情報が入力されてからアプリケーション実行開始時までの動作の例を示すフローチャートである。It is a flowchart which shows the example of operation | movement from the setting information input to the time of application execution start. 処理実行手段がデータベースへのデータの書き込みを指示するクエリを生成した場合の動作の例を示すフローチャートである。It is a flowchart which shows the example of operation | movement when a process execution means produces | generates the query which instruct | indicates writing of the data to a database. 処理実行手段がデータベースからのデータの読み込みを指示するクエリを生成した場合の動作の例を示すフローチャートである。It is a flowchart which shows the example of operation | movement when a process execution means produces | generates the query which instruct | indicates reading of the data from a database. データベース接続システムの例を示すブロック図である。It is a block diagram which shows the example of a database connection system. PCファイルクローラの処理で用いられるテーブルの例を示す説明図である。It is explanatory drawing which shows the example of the table used by the process of PC file crawler. 図12に例示するテーブルにメタデータとなる日時およびファイル名のフィールドを追加したテーブルの例を示す説明図である。It is explanatory drawing which shows the example of the table which added the date and time field used as metadata to the table illustrated in FIG. 12, and a file name. 本発明の概要を示す説明図である。It is explanatory drawing which shows the outline | summary of this invention. 本発明に関連するデータベース接続システムの例を示す説明図である。It is explanatory drawing which shows the example of the database connection system relevant to this invention.

符号の説明Explanation of symbols

10 データベース接続システム
11 記憶装置
100 DBアクセス仮想化手段
101 DBアクセス仮想化モジュール
200 DBアクセス手段
201 DBアクセスモジュール
300 処理実行手段
301 処理モジュール
400 実行制御手段
401 実行制御モジュール
500 データベースシステム
501 データベース
DESCRIPTION OF SYMBOLS 10 Database connection system 11 Storage apparatus 100 DB access virtualization means 101 DB access virtualization module 200 DB access means 201 DB access module 300 Process execution means 301 Processing module 400 Execution control means 401 Execution control module 500 Database system 501 Database

Claims (18)

データベースにデータを書き込む際に当該データとともにデータベースに書き込むメタデータの項目を定めた設定情報を記憶する設定情報記憶手段と、
メタデータを保持するメタデータ保持手段に対して、設定情報で定められた項目のメタデータを要求して、前記メタデータ保持手段からメタデータを収集するメタデータ収集手段と、
データベースへのデータの書き込みを指示するクエリを、当該データおよび設定情報で定められた項目のメタデータの書き込みを指示するクエリに変換する書き込みクエリ変換手段とを備える
ことを特徴とするデータベース接続システム。
Setting information storage means for storing setting information that defines metadata items to be written to the database together with the data when the data is written to the database;
A metadata collection unit that requests metadata of an item defined in setting information to a metadata holding unit that holds metadata, and collects metadata from the metadata holding unit;
A database connection system comprising: a write query conversion unit that converts a query instructing writing of data into a database into a query instructing writing of metadata of an item defined by the data and setting information.
データベースから読み込んだ読み込みデータの中から、設定情報で定められた項目のメタデータを削除するメタデータ削除手段を備える
請求項1に記載のデータベース接続システム。
The database connection system according to claim 1, further comprising metadata deleting means for deleting metadata of an item determined by setting information from read data read from a database.
データベースへのデータの書き込みを指示するクエリで指定されたフィールド名を全て記憶するフィールド名記憶手段と、
全フィールドのデータの読み込みを指示するクエリに含まれる全フィールドのデータを意味する記号を、フィールド名記憶手段が記憶する各フィールド名に置き換えることにより、前記クエリを変換する読み込みクエリ変換手段とを備える
請求項1に記載のデータベース接続システム。
Field name storage means for storing all field names specified in a query for instructing writing of data to the database;
Read query conversion means for converting the query by replacing symbols representing the data of all fields included in the query instructing reading of data of all fields with field names stored in the field name storage means. The database connection system according to claim 1.
新規テーブルの生成を指示するクエリで指定された新規テーブルのフィールド名に、設定情報で定められたメタデータの項目を追加することにより、前記クエリを変換するテーブル生成クエリ変換手段を備える
請求項1から請求項3のうちのいずれか1項に記載のデータベース接続システム。
The table generation query conversion means for converting the query by adding an item of metadata defined by setting information to the field name of the new table specified by the query instructing generation of the new table. The database connection system according to any one of claims 3 to 4.
メタデータ収集手段は、
データベースへのデータの書き込みを指示するクエリを生成する1つまたは複数のソフトウェアの中の最初のソフトウェアが起動されるときに、各ソフトウェアが順次実行されていく経過に伴って変化しないメタデータを収集し、
個々のソフトウェアが起動されるときに、各ソフトウェアが順次実行されていく経過に伴って変化するメタデータを収集する
請求項1から請求項4のうちのいずれか1項に記載のデータベース接続システム。
Metadata collection means
Collects metadata that does not change over time as each software is executed sequentially when the first of the software or software that generates a query that directs the writing of data to the database is launched And
The database connection system according to any one of claims 1 to 4, wherein when the individual software is activated, metadata that changes as the software is sequentially executed is collected.
設定情報が入力される設定情報入力手段と、
設定情報入力手段に入力された設定情報を設定情報記憶手段に記憶させる設定情報登録手段とを備える
請求項1から請求項5のうちのいずれか1項に記載のデータベース接続システム。
A setting information input means for inputting the setting information;
The database connection system according to any one of claims 1 to 5, further comprising setting information registration means for storing the setting information input to the setting information input means in the setting information storage means.
データベースにデータを書き込む際に当該データとともにデータベースに書き込むメタデータの項目を定めた設定情報を記憶する設定情報記憶手段を備えるコンピュータに搭載されるデータベース接続用プログラムであって、
前記コンピュータに、
メタデータを保持するメタデータ保持手段に対して、設定情報で定められた項目のメタデータを要求して、前記メタデータ保持手段からメタデータを収集するメタデータ収集処理、および
データベースへのデータの書き込みを指示するクエリを、当該データおよび設定情報で定められた項目のメタデータの書き込みを指示するクエリに変換する書き込みクエリ変換処理
を実行させるためのデータベース接続用プログラム。
A database connection program installed in a computer comprising setting information storage means for storing setting information defining metadata items to be written to the database together with the data when writing data to the database,
In the computer,
A metadata collection process for collecting metadata from the metadata holding means by requesting metadata of the items defined in the setting information from the metadata holding means for holding the metadata, and data of the data to the database A database connection program for executing a write query conversion process for converting a query instructing writing into a query instructing to write metadata of an item defined by the data and setting information.
コンピュータに、
データベースから読み込んだ読み込みデータの中から、設定情報で定められた項目のメタデータを削除するメタデータ削除処理
を実行させる請求項7に記載のデータベース接続用プログラム。
On the computer,
The database connection program according to claim 7, wherein metadata deletion processing is executed to delete metadata of an item determined by setting information from read data read from a database.
コンピュータに、
データベースへのデータの書き込みを指示するクエリで指定されたフィールド名を全て記憶するフィールド名記憶処理、および
全フィールドのデータの読み込みを指示するクエリに含まれる全フィールドのデータを意味する記号を、フィールド名記憶処理で記憶した各フィールド名に置き換えることにより、前記クエリを変換する読み込みクエリ変換処理
を実行させる請求項7に記載のデータベース接続用プログラム。
On the computer,
A field name storage process that stores all the field names specified in the query that instructs to write data to the database, and a symbol that means the data of all fields included in the query that instructs to read the data of all fields. The database connection program according to claim 7, wherein a read query conversion process for converting the query is executed by replacing each field name stored in the name storage process.
コンピュータに、
新規テーブルの生成を指示するクエリで指定された新規テーブルのフィールド名に、設定情報で定められたメタデータの項目を追加することにより、前記クエリを変換するテーブル生成クエリ変換処理
を実行させる請求項7から請求項9のうちのいずれか1項に記載のデータベース接続用プログラム。
On the computer,
The table generation query conversion process for converting the query is executed by adding a metadata item defined in the setting information to the field name of the new table specified in the query instructing the generation of the new table. The database connection program according to any one of claims 7 to 9.
コンピュータに、
データベースへのデータの書き込みを指示するクエリを生成する1つまたは複数のソフトウェアの中の最初のソフトウェアが起動されるときに、各ソフトウェアが順次実行されていく経過に伴って変化しないメタデータを収集させ、
個々のソフトウェアが起動されるときに、各ソフトウェアが順次実行されていく経過に伴って変化するメタデータを収集させる
請求項7から請求項10のうちのいずれか1項に記載のデータベース接続用プログラム。
On the computer,
Collects metadata that does not change over time as each software is executed sequentially when the first of the software or software that generates a query that directs the writing of data to the database is launched Let
The database connection program according to any one of claims 7 to 10, wherein when the individual software is started, metadata that changes as the software is sequentially executed is collected. .
設定情報が入力される設定情報入力手段を備えるコンピュータに搭載され、
前記コンピュータに、
設定情報入力手段に入力された設定情報を設定情報記憶手段に記憶させる設定情報登録処理
を実行させる請求項7から請求項11のうちのいずれか1項に記載のデータベース接続用プログラム。
It is mounted on a computer having setting information input means for inputting setting information,
In the computer,
The program for database connection according to any one of claims 7 to 11, wherein a setting information registration process for storing the setting information input to the setting information input unit in the setting information storage unit is executed.
データベースにデータを書き込む際に当該データとともにデータベースに書き込むメタデータの項目を定めた設定情報を記憶する設定情報記憶手段を備えたデータベース接続システムに適用されるデータベース接続方法であって、
メタデータ収集手段が、メタデータを保持するメタデータ保持手段に対して、設定情報で定められた項目のメタデータを要求して、前記メタデータ保持手段からメタデータを収集し、
書き込みクエリ変換手段が、データベースへのデータの書き込みを指示するクエリを、当該データおよび設定情報で定められた項目のメタデータの書き込みを指示するクエリに変換する
ことを特徴とするデータベース接続方法。
A database connection method that is applied to a database connection system that includes setting information storage means for storing setting information that defines metadata items to be written to the database together with the data when the data is written to the database,
The metadata collection means requests metadata of the items defined in the setting information to the metadata holding means that holds the metadata, collects metadata from the metadata holding means,
A database connection method, wherein the write query conversion means converts a query instructing writing of data into the database into a query instructing writing of metadata of an item defined by the data and setting information.
メタデータ削除手段が、データベースから読み込んだ読み込みデータの中から、設定情報で定められた項目のメタデータを削除する
請求項13に記載のデータベース接続方法。
The database connection method according to claim 13, wherein the metadata deletion means deletes metadata of items determined by setting information from read data read from the database.
フィールド名記憶手段が、データベースへのデータの書き込みを指示するクエリで指定されたフィールド名を全て記憶し、
読み込みクエリ変換手段が、全フィールドのデータの読み込みを指示するクエリに含まれる全フィールドのデータを意味する記号を、フィールド名記憶手段が記憶する各フィールド名に置き換えることにより、前記クエリを変換する
請求項13に記載のデータベース接続方法。
The field name storage means stores all the field names specified by the query instructing writing of data to the database,
The read query conversion means converts the query by replacing symbols representing the data of all fields included in the query instructing the reading of data of all fields with each field name stored in the field name storage means. Item 14. The database connection method according to Item 13.
テーブル生成クエリ変換手段が、新規テーブルの生成を指示するクエリで指定された新規テーブルのフィールド名に、設定情報で定められたメタデータの項目を追加することにより、前記クエリを変換する
請求項13から請求項15のうちのいずれか1項に記載のデータベース接続方法。
14. The table generation query conversion means converts the query by adding an item of metadata defined by setting information to the field name of the new table specified by the query instructing generation of the new table. The database connection method according to claim 1.
メタデータ収集手段が、
データベースへのデータの書き込みを指示するクエリを生成する1つまたは複数のソフトウェアの中の最初のソフトウェアが起動されるときに、各ソフトウェアが順次実行されていく経過に伴って変化しないメタデータを収集し、
個々のソフトウェアが起動されるときに、各ソフトウェアが順次実行されていく経過に伴って変化するメタデータを収集する
請求項13から請求項16のうちのいずれか1項に記載のデータベース接続方法。
Metadata collection means
Collects metadata that does not change over time as each software is executed sequentially when the first of the software or software that generates a query that directs the writing of data to the database is launched And
The database connection method according to any one of claims 13 to 16, wherein when the individual software is activated, metadata that changes as the software is sequentially executed is collected.
設定情報が入力される設定情報入力手段を備えるデータベース接続システムに適用され、
設定情報登録手段が、設定情報入力手段に入力された設定情報を設定情報記憶手段に記憶させる
請求項13から請求項17のうちのいずれか1項に記載のデータベース接続方法。
Applied to a database connection system comprising setting information input means for inputting setting information;
The database connection method according to any one of claims 13 to 17, wherein the setting information registration unit stores the setting information input to the setting information input unit in the setting information storage unit.
JP2007208258A 2007-08-09 2007-08-09 Database connection system, database connection program, and database connection method Pending JP2009043083A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2007208258A JP2009043083A (en) 2007-08-09 2007-08-09 Database connection system, database connection program, and database connection method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2007208258A JP2009043083A (en) 2007-08-09 2007-08-09 Database connection system, database connection program, and database connection method

Publications (1)

Publication Number Publication Date
JP2009043083A true JP2009043083A (en) 2009-02-26

Family

ID=40443759

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2007208258A Pending JP2009043083A (en) 2007-08-09 2007-08-09 Database connection system, database connection program, and database connection method

Country Status (1)

Country Link
JP (1) JP2009043083A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2013246827A (en) * 2012-05-29 2013-12-09 Fujitsu Ltd Extendable method and system for storage meta data
WO2015002057A1 (en) * 2013-07-04 2015-01-08 株式会社ブロードリーフ Transmission and reception device, transmission and reception system, transmission and reception method, and program

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2013246827A (en) * 2012-05-29 2013-12-09 Fujitsu Ltd Extendable method and system for storage meta data
WO2015002057A1 (en) * 2013-07-04 2015-01-08 株式会社ブロードリーフ Transmission and reception device, transmission and reception system, transmission and reception method, and program
JP2015014899A (en) * 2013-07-04 2015-01-22 株式会社ブロードリーフ Transmission / reception device, transmission / reception system, transmission / reception method, and program

Similar Documents

Publication Publication Date Title
JP3738787B2 (en) Resource management apparatus and resource management method
CN108762743B (en) Data table operation code generation method and device
JP4141556B2 (en) Structured document management method, apparatus for implementing the method, and medium storing the processing program
CN104881285B (en) Code snippet mark and reuse system based on body
JP5600736B2 (en) Database management method and system
CN111259067B (en) Method, device and equipment for realizing DAO interface based on Spring
WO2013175560A1 (en) Information communicating system and information converting method
JP6770225B2 (en) Information processing device and its processing method and program
JP2020119348A (en) Analysis program, analysis method, and analysis device
JP5224839B2 (en) Document management system, document management apparatus, document management method, and program
JP2009043083A (en) Database connection system, database connection program, and database connection method
Pribec et al. Efficient and reliable data management for biomedical applications
US20060282402A1 (en) Information processing apparatus, method of controlling information processing apparatus, computer program, and storage medium
Musleh et al. Automatic generation of Android SQLite database components
Eyl et al. Traceability in a fine grained software configuration management system
JP2010061460A (en) Workflow management system, workflow management method and workflow management program
JP2010067233A (en) Workflow management system, workflow management method, and workflow management program
Alink XIRAF: an XML-IR approach to digital forensics
JP4846031B2 (en) Operation verification system
JP2011014138A (en) Information processor, control method of information processor, control program of information processor, and recording medium
JP2009080536A (en) Bill of materials editing device, editing program, editing system, and editing method
KR20150094006A (en) realtime compile supporting various types mobile platform, using mash-up block, and download runtime technologies
JP2010218459A (en) Apparatus and method for processing information, and program
JP2025149205A (en) Conversion support program, conversion support system, and conversion support method
JP2010218219A (en) Replica table generating apparatus, replica table generating method, and program