JP2010282298A - System, method and program for retrieving database - Google Patents

System, method and program for retrieving database Download PDF

Info

Publication number
JP2010282298A
JP2010282298A JP2009133446A JP2009133446A JP2010282298A JP 2010282298 A JP2010282298 A JP 2010282298A JP 2009133446 A JP2009133446 A JP 2009133446A JP 2009133446 A JP2009133446 A JP 2009133446A JP 2010282298 A JP2010282298 A JP 2010282298A
Authority
JP
Japan
Prior art keywords
search
user
database
authority
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
JP2009133446A
Other languages
Japanese (ja)
Inventor
Ryota Fujisawa
亮太 藤沢
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.)
Mitsubishi Electric Corp
Original Assignee
Mitsubishi Electric 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 Mitsubishi Electric Corp filed Critical Mitsubishi Electric Corp
Priority to JP2009133446A priority Critical patent/JP2010282298A/en
Publication of JP2010282298A publication Critical patent/JP2010282298A/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 retrieval system which can restrict a retrieval range. <P>SOLUTION: This database retrieval system includes: an application execution part 7 equipped with a user information storage part 71 for storing information on the authority and assignment of a user and a database 72 for storing data; a storage part 6 for setting a table which is retrievable from the database 72 for each piece of information on authority and assignment, items in the table and a retrievable range in the items; a log-in user information generation part 3 for reading the information on the authority and assignment of the user from the user information storage part 71; and a retrieval control part 4 for performing control to read the table of the database 72 retrievable by the user from the storage part 6, the items in the table, and the retrievable range in the items based on the read information on the authority and assignment of the user, and to generate a retrievable screen, and for executing retrieval according to retrieval conditions set by the user according to the operation of the retrieval screen. <P>COPYRIGHT: (C)2011,JPO&INPIT

Description

本発明は、ユーザに応じてデータベースの検索対象を制限するデータベース検索システムに関する。   The present invention relates to a database search system that limits a database search target according to a user.

従来、企業等において各種アプリケーションを実行する情報システムでは、データベースを備えている。一般的にデータベースは、テーブルと呼ばれる表形式でデータを蓄積しており、複数のテーブルで構成されている。ここで、情報システムを利用するユーザ(例えば、企業における従業員等)においては、操作が固定されたアプリケーションを実行する以外に、データベースに蓄積されたデータそのものを自由に閲覧、検索したいという要望も多い。しかし、データベースを検索するためには、データベースの構造や専門用語等の専門知識が必要であるがこれらは難解であり、一般のユーザがデータベースの検索を行うことは難しかった。   Conventionally, an information system that executes various applications in a company or the like includes a database. In general, a database stores data in a table format called a table, and is composed of a plurality of tables. Here, in addition to executing applications whose operations are fixed, users who use the information system (for example, employees in a company) may wish to freely browse and search the data stored in the database. Many. However, in order to search the database, specialized knowledge such as the structure of the database and technical terms is necessary, but these are difficult to understand, and it is difficult for general users to search the database.

そのため、専門知識を使用することなくユーザがデータベースを検索する技術として、たとえば、ユーザからの検索要求に対応して定義情報を参照し、抽出条件指定欄を備えた入力画面を提示し、指定した抽出条件に沿ってデータベースからデータを抽出して検索結果を表示する技術が、下記特許文献1に開示されている。また、データベース構成定義ファイルとテーブル構成定義ファイルとを参照して検索条件設定画面を提示し、指定された検索条件から検索文を作成して検索結果を表示する技術が、下記特許文献2に開示されている。   Therefore, as a technique for users to search the database without using specialized knowledge, for example, the definition information is referred to in response to a search request from the user, and an input screen having an extraction condition specification column is presented and specified. A technique for extracting data from a database according to extraction conditions and displaying a search result is disclosed in Patent Document 1 below. Further, a technique for presenting a search condition setting screen with reference to a database configuration definition file and a table configuration definition file, creating a search sentence from a specified search condition, and displaying a search result is disclosed in Patent Document 2 below. Has been.

特開2007−094570号公報JP 2007-0945570 A 特開平10−320247号公報JP-A-10-320247

しかしながら、上記従来の技術によれば、企業秘密の漏洩防止のためユーザの権限に応じてデータの閲覧対象を制限する場合、アプリケーションレベルでは、特定のユーザに特定のデータベースのテーブルの閲覧を禁止するような細かな制御ができない、という問題があった。また、ユーザに対してデータベースのテーブルを直接閲覧させるツールも存在するが、ユーザによって閲覧対象を制限するような制御ができない、という問題があった。   However, according to the above-described conventional technique, when restricting the data browsing target according to the authority of the user in order to prevent the leakage of trade secrets, the browsing of a specific database table is prohibited for a specific user at the application level. There was a problem that such fine control was not possible. There is also a tool that allows the user to browse the database table directly, but there is a problem in that the user cannot control to limit the browsing target.

本発明は、上記に鑑みてなされたものであって、ユーザがデータベースに蓄積されたデータを直接検索する場合において、ユーザの権限に応じた検索範囲の制限が可能なデータベース検索システムを得ることを目的とする。   This invention is made in view of the above, Comprising: When the user searches directly the data accumulate | stored in the database, the database search system which can restrict | limit the search range according to a user's authority is obtained. Objective.

上述した課題を解決し、目的を達成するために、本発明は、ユーザの権限および所属の情報を記憶するためのユーザ情報記憶部と、アプリケーションの実行に必要なデータを格納するためのデータベースと、を備えるアプリケーション実行手段と、ユーザの権限または所属の情報ごとに、前記データベースの中から検索可能なテーブル、テーブル内の項目、項目内の検索可能範囲が設定された検索対象記憶手段と、前記ユーザ情報記憶部から、前記アプリケーション実行手段で割り当てられているユーザの権限および所属の情報を読み出すログインユーザ情報生成手段と、前記ログインユーザ情報生成手段にて読み出された情報に基づいて、前記検索対象記憶手段から、ユーザが検索可能なデータベースのテーブル、テーブル内の項目、項目内の検索可能範囲を読み出し、当該検索可能範囲でユーザが検索条件を設定するための検索画面を生成する制御を行い、当該検索画面の操作によりユーザ設定された検索条件に従って検索を実行する検索制御手段と、を備えることを特徴とする。   In order to solve the above-described problems and achieve the object, the present invention provides a user information storage unit for storing user authority and affiliation information, and a database for storing data necessary for execution of an application. For each user authority or affiliation information, a table searchable from the database, items in the table, search target storage means in which a searchable range in the item is set, and Login user information generation means for reading user authority and affiliation information assigned by the application execution means from the user information storage unit, and the search based on the information read by the login user information generation means Database table that can be searched by the user from the target storage means, items in the table, items Search control means for performing a control for generating a search screen for a user to set a search condition in the searchable range, and performing a search according to the search condition set by the user by operating the search screen And.

本発明によれば、ユーザの権限に応じてデータベースの検索範囲を制限できる、という効果を奏する。   According to the present invention, the database search range can be limited according to the authority of the user.

図1は、データベース検索システムの構成例を示す図である。FIG. 1 is a diagram illustrating a configuration example of a database search system. 図2は、検索対象を制御する検索制御処理を示すフローチャートである。FIG. 2 is a flowchart showing a search control process for controlling a search target. 図3は、ユーザ情報格納先設定ファイルの構成例を示す図である。FIG. 3 is a diagram illustrating a configuration example of a user information storage destination setting file. 図4は、ログインユーザ情報ファイルの構成例を示す図である。FIG. 4 is a diagram illustrating a configuration example of the login user information file. 図5は、デフォルト検索対象設定ファイルの構成例を示す図である。FIG. 5 is a diagram illustrating a configuration example of a default search target setting file. 図6は、権限別検索対象設定ファイルの構成例を示す図である。FIG. 6 is a diagram illustrating a configuration example of the authority-specific search target setting file. 図7は、所属別検索対象設定ファイルの構成例を示す図である。FIG. 7 is a diagram illustrating a configuration example of the search target setting file classified by affiliation. 図8は、テーブル別名ファイルの構成例を示す図である。FIG. 8 is a diagram illustrating a configuration example of the table alias file. 図9は、検索対象テーブル選択画面の構成例を示す図である。FIG. 9 is a diagram illustrating a configuration example of a search target table selection screen. 図10は、項目別名ファイルの構成例を示す図である。FIG. 10 is a diagram illustrating a configuration example of the item alias file. 図11は、検索画面の構成例を示す図である。FIG. 11 is a diagram illustrating a configuration example of a search screen. 図12は、データベース検索プログラムを実行可能な電子計算機の構成例を示す図である。FIG. 12 is a diagram illustrating a configuration example of an electronic computer capable of executing a database search program.

以下に、本発明にかかるデータベース検索システムの実施の形態を図面に基づいて詳細に説明する。なお、この実施の形態によりこの発明が限定されるものではない。   Embodiments of a database search system according to the present invention will be described below in detail with reference to the drawings. Note that the present invention is not limited to the embodiments.

実施の形態.
図1は、本実施の形態のデータベース検索システムの構成例を示す図である。データベース検索システムは、入力部1と、認証部2と、ログインユーザ情報生成部3と、検索制御部4と、表示部5と、記憶部6と、アプリケーション実行部7と、を備える。
Embodiment.
FIG. 1 is a diagram illustrating a configuration example of a database search system according to the present embodiment. The database search system includes an input unit 1, an authentication unit 2, a login user information generation unit 3, a search control unit 4, a display unit 5, a storage unit 6, and an application execution unit 7.

入力部1は、ユーザからのユーザIDおよびパスワードを受け付ける。認証部2は、入力されたユーザIDおよびパスワードに基づいてユーザの認証を行う。ログインユーザ情報生成部3は、認証されたユーザについて、ログインユーザ情報ファイルを生成する。検索制御部4は、認証されたユーザについて、データベースで検索可能なテーブルや項目を取得し、出力および保存を行う。表示部5は、ユーザが検索可能なテーブルや項目を示す検索画面等を表示する。記憶部6は、認証や検索条件設定に必要な情報を記憶するためのメモリである。アプリケーション実行部7は、アプリケーションを提供する既存の実行部である。   The input unit 1 receives a user ID and password from a user. The authentication unit 2 performs user authentication based on the input user ID and password. The login user information generation unit 3 generates a login user information file for the authenticated user. The search control unit 4 acquires tables and items that can be searched in the database for the authenticated user, and outputs and stores them. The display unit 5 displays a search screen showing tables and items that can be searched by the user. The storage unit 6 is a memory for storing information necessary for authentication and search condition setting. The application execution unit 7 is an existing execution unit that provides an application.

また、記憶部6は、ユーザ情報格納先設定ファイル61と、ログインユーザ情報ファイル62と、デフォルト検索対象設定ファイル63と、権限別検索対象設定ファイル64と、所属別検索対象設定ファイル65と、テーブル別名ファイル66と、項目別名ファイル67と、テーブル一覧記憶部68と、検索条件記憶部69と、を備える。   In addition, the storage unit 6 includes a user information storage destination setting file 61, a login user information file 62, a default search target setting file 63, an authority-specific search target setting file 64, an affiliation-specific search target setting file 65, and a table. An alias file 66, an item alias file 67, a table list storage unit 68, and a search condition storage unit 69 are provided.

ユーザ情報格納先設定ファイル61は、ユーザID、パスワード、権限情報および所属情報が、アプリケーション実行部7において、どのテーブルのどの項目に格納されているのかを示す設定情報のファイルである。ログインユーザ情報ファイル62は、認証されたユーザについてログイン後に生成される、検索可能テーブル等を設定するために必要なユーザID、権限、所属、の情報を示すファイルである。   The user information storage destination setting file 61 is a setting information file indicating in which table item and in which table the application execution unit 7 stores the user ID, password, authority information, and affiliation information. The log-in user information file 62 is a file indicating information on a user ID, authority, and affiliation necessary for setting a searchable table or the like generated after log-in for an authenticated user.

デフォルト検索対象設定ファイル63は、ユーザID、権限、所属、に関係なく検索可能なテーブル、対象項目、条件範囲をデフォルトで設定するファイルである。権限別検索対象設定ファイル64は、ユーザの権限別に検索可能なテーブル、対象項目、条件範囲を設定するファイルである。所属別検索対象設定ファイル65は、ユーザの所属別に検索可能なテーブル、対象項目、条件範囲を設定するファイルである。   The default search target setting file 63 is a file that sets a table, target items, and condition ranges that can be searched regardless of the user ID, authority, and affiliation by default. The authority-specific search target setting file 64 is a file for setting a searchable table, target items, and condition ranges according to user authority. The affiliation-specific search target setting file 65 is a file for setting a table, target items, and condition ranges that can be searched by user affiliation.

テーブル別名ファイル66は、テーブルの「別名」を設定するファイルである。検索画面等を表示する場合には、一般のユーザにも分かりやすいテーブルの「別名」が表示される。項目別名ファイル67は、項目の「別名」を設定するファイルである。検索画面を表示する場合には、一般のユーザにも分かりやすい項目の「別名」が表示される。   The table alias file 66 is a file for setting an “alias” of the table. When a search screen or the like is displayed, an “alias” of a table that is easy to understand for general users is displayed. The item alias file 67 is a file for setting an “alias” of an item. When the search screen is displayed, “alias” of an item that is easy to understand for general users is displayed.

テーブル一覧記憶部68は、ユーザが検索可能なテーブルの情報を記憶するためのメモリである。検索条件記憶部69は、ユーザが実際に検索したときの検索条件をファイルとして記憶するためのメモリである。記憶したファイルを起動することで、記憶時の検索条件を再現できる。   The table list storage unit 68 is a memory for storing information on tables that can be searched by the user. The search condition storage unit 69 is a memory for storing a search condition when a user actually searches as a file. By starting the stored file, the search conditions at the time of storage can be reproduced.

また、アプリケーション実行部7は、ユーザ情報記憶部71と、データベース72と、を備える。ユーザ情報記憶部71は、アプリケーション実行部7において、認証に必要なユーザIDやパスワードを格納している記憶部である。データベース72は、アプリケーションの実行に必要なデータを格納するための記憶部である。   The application execution unit 7 includes a user information storage unit 71 and a database 72. The user information storage unit 71 is a storage unit that stores a user ID and password required for authentication in the application execution unit 7. The database 72 is a storage unit for storing data necessary for executing the application.

つづいて、データベース検索システムにおいて、検索対象を制御して検索画面を自動生成し、検索を実行する処理をフローチャートに基づいて説明する。図2は、検索対象を制御する検索制御処理を示すフローチャートである。まず、データベース検索システムでは、認証部2が、表示部5にログイン画面を表示する(ステップS1)。入力部1がユーザからユーザIDおよびパスワードを取得した場合(ステップS2:Yes)、認証部2へユーザIDおよびパスワードを通知する。ユーザからユーザIDおよびパスワードの入力がなく取得していない場合(ステップS2:No)、ログイン画面の表示を継続する(ステップS1)。   Next, a process for controlling a search target to automatically generate a search screen and executing a search in the database search system will be described with reference to a flowchart. FIG. 2 is a flowchart showing a search control process for controlling a search target. First, in the database search system, the authentication unit 2 displays a login screen on the display unit 5 (step S1). When the input unit 1 acquires the user ID and password from the user (step S2: Yes), the authentication unit 2 is notified of the user ID and password. If the user has not obtained the user ID and password (step S2: No), the login screen continues to be displayed (step S1).

認証部2は、入力部1からユーザIDおよびパスワードを取得した場合(ステップS2:Yes)、ユーザ認証を行うため、まず、ユーザ情報格納先設定ファイル61を参照し、本システムを利用可能なユーザのユーザIDおよびパスワードの情報が格納されているテーブルの情報を取得する。   When the authentication unit 2 acquires the user ID and password from the input unit 1 (step S2: Yes), the user can use this system by referring to the user information storage destination setting file 61 in order to perform user authentication. The information of the table storing the user ID and password information is acquired.

図3は、ユーザ情報格納先設定ファイル61の構成例を示す図である。ユーザ情報格納先設定ファイル61は、ユーザIDおよびパスワードの格納先について、格納先テーブル名と、格納先項目名(ユーザID)と、格納先項目名(パスワード)と、を記録している。アプリケーション実行部7でユーザ情報(ユーザID/パスワード)を格納しているユーザ情報記憶部71のどのテーブルのどの項目にユーザIDおよびパスワードが格納されているかを示すものである。認証部2は、ユーザ情報格納先設定ファイル61を参照することによって、ユーザ情報記憶部71から認証に必要な情報を容易に取得できる。   FIG. 3 is a diagram illustrating a configuration example of the user information storage destination setting file 61. The user information storage location setting file 61 records the storage location table name, the storage location item name (user ID), and the storage location item name (password) for the storage location of the user ID and password. This indicates which item of which table of the user information storage unit 71 storing user information (user ID / password) in the application execution unit 7 is stored with the user ID and password. The authentication unit 2 can easily acquire information necessary for authentication from the user information storage unit 71 by referring to the user information storage destination setting file 61.

また、ユーザ情報格納先設定ファイル61は、権限格納先として、格納先テーブル名と、格納先項目名(権限種別)と、格納先項目名(権限レベル)と、検索キー項目名と、検索キーと、を記録している。これらの情報を参照することによって、上記認証時と同様に、アプリケーション実行部7からユーザの権限に関する情報を容易に取得できる。また、ユーザ情報格納先設定ファイルは、所属格納先として、格納先テーブル名と、格納先項目名(所属)と、検索キー項目名と、検索キーと、を記録している。これらの情報を参照することによって、上記認証時と同様に、アプリケーション実行部7からユーザの所属に関する情報を容易に取得できる。本システムでは、ユーザ情報格納先設定ファイル61の格納先の情報を変更することで読み出し先を変更できるため、異なるアプリケーションについても容易に対応することができる。   In addition, the user information storage destination setting file 61 includes a storage destination table name, a storage destination item name (authority type), a storage destination item name (authority level), a search key item name, and a search key as authority storage destinations. And recorded. By referring to these pieces of information, information regarding the user authority can be easily obtained from the application execution unit 7 as in the case of the authentication. The user information storage location setting file records a storage location table name, a storage location item name (affiliation), a search key item name, and a search key as the affiliation storage location. By referring to these pieces of information, information related to user affiliation can be easily obtained from the application execution unit 7 as in the case of the authentication. In this system, since the read destination can be changed by changing the storage destination information in the user information storage destination setting file 61, it is possible to easily cope with different applications.

認証部2は、ユーザ情報格納先ファイル61を参照して取得した格納先の情報に基づいてユーザ情報記憶部71の該当するテーブルを検索し、入力部1で取得したユーザIDおよびパスワードで特定されるユーザが、本システムを利用可能かどうかの認証を行う(ステップS3)。認証NGの場合(ステップS3:NG)、データベース検索システムは、認証処理を終了してログイン画面の状態に戻る(ステップS1)。認証OKの場合(ステップS3:OK)、つぎに、ログインユーザ情報生成部3において、ログインユーザ情報ファイル62を生成する(ステップS4)。   The authentication unit 2 searches the corresponding table in the user information storage unit 71 based on the storage location information acquired by referring to the user information storage destination file 61, and is specified by the user ID and password acquired by the input unit 1. The user who authenticates whether or not the system can be used (step S3). In the case of authentication NG (step S3: NG), the database search system ends the authentication process and returns to the login screen state (step S1). If the authentication is OK (step S3: OK), the login user information generation unit 3 generates a login user information file 62 (step S4).

具体的には、ログインユーザ情報生成部3では、まず、ユーザ情報格納先設定ファイル61の権限格納先を参照し、ユーザ情報記憶部71から権限に関する情報(権限種別、権限レベル)を取得する。つぎに、ユーザ情報格納先設定ファイル61の所属格納先を参照し、ユーザ情報記憶部71から所属に関する情報を取得する。そして、ユーザID、権限および所属についてログインユーザ情報ファイル62としてまとめる。図4は、ログインユーザ情報ファイル62の構成例を示す図である。ログインユーザ情報ファイル62は、ユーザIDと、権限と、所属と、の情報を記録している。ユーザの検索可能なテーブル、項目等を選択する際に使用するファイルである。   Specifically, the login user information generation unit 3 first refers to the authority storage destination of the user information storage destination setting file 61 and acquires information (authority type, authority level) related to authority from the user information storage unit 71. Next, the affiliation storage location of the user information storage location setting file 61 is referred to, and information related to affiliation is acquired from the user information storage unit 71. Then, the user ID, authority, and affiliation are collected as a login user information file 62. FIG. 4 is a diagram illustrating a configuration example of the login user information file 62. The login user information file 62 records information on user ID, authority, and affiliation. This file is used to select a table, items, etc. that can be searched by the user.

データベース検索システムでは、ログインユーザ情報ファイル62を生成後、つぎに、検索制御部4において、具体的に、ユーザが検索可能なテーブル、項目についての情報を取得する。まず、デフォルト検索対象設定ファイル63を参照し、デフォルト設定として、全てのユーザが検索可能な検索可能テーブルおよび項目の情報を取得する(ステップS5)。   In the database search system, after the login user information file 62 is generated, the search control unit 4 acquires information about tables and items that can be specifically searched by the user. First, the default search target setting file 63 is referred to, and as a default setting, a searchable table and item information searchable by all users are acquired (step S5).

図5は、デフォルト検索対象設定ファイル63の構成例を示す図である。デフォルト検索対象設定ファイル63は、全てのユーザが検索可能な、対象テーブル、対象項目、条件範囲、について設定している。例えば、TABLE1では、対象項目は、KOU1〜3が検索可能であり、KOU1、KOU2については、その条件範囲についても制限されている。一方、TABLE2〜5では、全ての項目画検索可能であるが、TABLE4については、条件範囲がユーザの所属範囲に制限されている。なお、全てのユーザが検索可能な検索可能テーブルおよび項目については、設定しないことも可能である。   FIG. 5 is a diagram illustrating a configuration example of the default search target setting file 63. The default search target setting file 63 sets a target table, target items, and condition ranges that can be searched by all users. For example, in TABLE1, KOU1 to KOU3 can be searched for the target item, and the condition range of KOU1 and KOU2 is also limited. On the other hand, in TABLEs 2 to 5, all item images can be searched, but for TABLE 4, the condition range is limited to the user's affiliation range. Note that the searchable table and items that can be searched by all users may not be set.

つぎに、検索制御部4は、権限別検索対象設定ファイル64を参照し、権限(権限種別、権限レベル)に基づいて、検索可能な項目、範囲についての情報を取得する(ステップS6)。図6は、権限別検索対象設定ファイル64の構成例を示す図である。権限別検索対象設定ファイル64は、権限種別、権限レベル、対象テーブル、対象項目、条件範囲、について設定しているファイルである。例えば、ログインしたユーザの権限種別「顧客マスタ閲覧権限」が、権限レベルが「1」の場合、検索対象テーブルは「MST_CUSTOMER」であり、対象項目は「ALL」で条件範囲は「TANTOU」であるが、権限レベル「2」の場合では、条件範囲は「ALL」となる。権限種別「社員マスタ閲覧権限」についても、権限レベルに応じて対象項目や条件範囲が異なる。   Next, the search control unit 4 refers to the authority-specific search object setting file 64 and acquires information on searchable items and ranges based on authority (authority type, authority level) (step S6). FIG. 6 is a diagram illustrating a configuration example of the authority-specific search target setting file 64. The authority-specific search target setting file 64 is a file in which authority types, authority levels, target tables, target items, and condition ranges are set. For example, when the authority type “customer master browsing authority” of the logged-in user is “1”, the search target table is “MST_CUSTOMER”, the target item is “ALL”, and the condition range is “TANTOU”. However, in the case of the authority level “2”, the condition range is “ALL”. Regarding the authority type “employee master browsing authority”, the target items and condition ranges differ depending on the authority level.

ここでは、図4のログインユーザ情報ファイル62の例に従って、権限種別「顧客マスタ閲覧制限」については権限レベル「1」、権限種別「社員マスタ閲覧権限」については権限レベル「2」で設定された範囲で項目の検索が可能とする。   Here, according to the example of the login user information file 62 of FIG. 4, the authority type “customer master viewing restriction” is set at the authority level “1”, and the authority type “employee master viewing authority” is set at the authority level “2”. Search for items by range.

つぎに、検索制御部4では、所属別検索対象設定ファイル65を参照し、所属に基づいて、検索可能な項目、範囲についての情報を取得する(ステップS7)。図7は、所属別検索対象設定ファイル65の構成例を示す図である。所属別検索対象設定ファイル65は、所属、対象テーブル、対象項目、条件範囲、について設定している。例えば、ログインしたユーザの所属が「本社/人事部」の場合、対象テーブル「MST_EMPLOYEE」について、対象項目および条件範囲については全て検索可能(「ALL」)であるが、その他の所属の場合、対象項目や、条件範囲について制限されることになる。   Next, the search control unit 4 refers to the affiliation-specific search target setting file 65 and acquires information about searchable items and ranges based on the affiliation (step S7). FIG. 7 is a diagram illustrating a configuration example of the affiliation-specific search target setting file 65. The affiliation search target setting file 65 is set for affiliation, target table, target item, and condition range. For example, if the logged-in user's affiliation is “Headquarters / Human Resources Department”, the target table “MST_EMPLOYEE” can be searched for all target items and condition ranges (“ALL”), but if the affiliation is other, the target Items and condition ranges will be limited.

ここでは、図4のログインユーザ情報ファイル62の例に従って、所属「東京支社/人事部」および「東京支社/総務部」で設定された範囲で項目の検索が可能とする。なお、複数の所属があり、それぞれにおいて検索可能な対象項目や条件範囲が異なる場合は、複数の所属で許可された最も広い範囲で検索可能とする。   Here, according to the example of the log-in user information file 62 in FIG. 4, it is possible to search for items within the range set by the affiliation “Tokyo branch / HR department” and “Tokyo branch / general affairs department”. In addition, when there are a plurality of affiliations and the target items and condition ranges that can be searched for are different, the search is made possible in the widest range permitted by the affiliations.

つぎに、検索制御部4では、検索可能なテーブルが1つも無かった場合は、処理を終了する(ステップS8:No)。検索可能なテーブルが1つ以上存在した場合は(ステップS8:Yes)、テーブル別名ファイルに基づいてテーブルの別名を取得し、名称を変換する(ステップS9)。図8は、テーブル別名ファイル66の構成例を示す図である。通常、データベース内の各テーブルの名称は一般のユーザには分かりにくいので、分かりやすい名称に変換するものである。例えば、テーブル名「MST_EMPLOYEE」は「社員マスタ」に変換し、検索画面では「社員マスタ」として表示する。   Next, when there is no searchable table, the search control unit 4 ends the process (step S8: No). When one or more searchable tables exist (step S8: Yes), the table alias is acquired based on the table alias file, and the name is converted (step S9). FIG. 8 is a diagram illustrating a configuration example of the table alias file 66. Normally, the name of each table in the database is difficult to understand for general users, and is therefore converted to an easy-to-understand name. For example, the table name “MST_EMPLOYEE” is converted to “employee master” and displayed as “employee master” on the search screen.

テーブル名を変換後、検索制御部4は、検索可能テーブルを表示部5に表示する(ステップS10)。図9は、検索可能テーブル選択画面の構成例を示す図である。検索可能なテーブルが複数ある場合は、1つのテーブルを選び、選択ボタンを押すことで、検索対象のテーブルを選択できる。   After converting the table name, the search control unit 4 displays the searchable table on the display unit 5 (step S10). FIG. 9 is a diagram illustrating a configuration example of a searchable table selection screen. When there are a plurality of searchable tables, a table to be searched can be selected by selecting one table and pressing a selection button.

ここで、テーブルが選択されるまでは表示を継続し(ステップS11:No)、テーブルが選択された場合(ステップS11:Yes)、検索制御部4は、選択されたテーブルについて、検索可能な対象項目、条件範囲を取得する(ステップS12)。具体的には、図5〜図7のファイルに示す各テーブルにおける、対象項目、条件範囲に示す内容である。また、検索制御部4は、項目別名ファイル67に基づいて項目の別名を取得し、名称を変換する(ステップS13)。図10は、項目別名ファイル67の構成例を示す図である。例えば、ステップS12で社員マスタのテーブルが選択された場合、MST_EMPLOYEEの各項目を別名にして表示する。具体的には、項目「ID」については、別名「社員番号」として表示するように、一般のユーザに分かりやすい名称に変換する。   Here, the display is continued until the table is selected (step S11: No), and when the table is selected (step S11: Yes), the search control unit 4 can search for the selected table. Items and condition ranges are acquired (step S12). Specifically, it is the contents shown in the target item and the condition range in each table shown in the files of FIGS. Further, the search control unit 4 acquires an item alias based on the item alias file 67, and converts the name (step S13). FIG. 10 is a diagram illustrating a configuration example of the item alias file 67. For example, when the employee master table is selected in step S12, each item of MST_EMPLOYEE is displayed as an alias. Specifically, the item “ID” is converted into a name that is easy for a general user to understand so as to be displayed as an alias “employee number”.

項目名を変換後、検索制御部4は、ステップS11で選択したテーブルの検索画面を表示する(ステップS14)。図11は、検索画面の構成例を示す図である。ここでは、検索条件について、検索可能な項目をOr条件で追加することができる。また、検索範囲が制限されている場合は、Andとして、検索画面下部の検索可能条件範囲で自動的に条件が設定される。そして、検索制御部4は、指定された条件に基づいて、データベース72の検索を行う(ステップS15)。項目や範囲が自動的に制限されることを除けば、検索する方法は一般的なデータベースの検索方法と同様である。   After converting the item name, the search control unit 4 displays a search screen for the table selected in step S11 (step S14). FIG. 11 is a diagram illustrating a configuration example of a search screen. Here, as search conditions, searchable items can be added under the Or condition. If the search range is limited, the condition is automatically set as And in the searchable condition range at the bottom of the search screen. And the search control part 4 searches the database 72 based on the designated conditions (step S15). The search method is the same as a general database search method except that items and ranges are automatically limited.

このように対象項目や条件範囲を制限することによって、ユーザが直接データベース72を検索する場合においても、ユーザに応じて検索対象を制限することができる。また、ユーザに対して、検索可能な範囲で検索画面を表示することによって、検索可能な範囲での操作を指示することができる。   By limiting the target items and condition ranges in this way, even when the user directly searches the database 72, the search target can be limited according to the user. Further, by displaying a search screen within a searchable range, the user can be instructed to perform an operation within the searchable range.

なお、本システムでは、検索画面で設定した特定の検索条件をファイル形式で記憶することができる(ステップS16)。具体的には、図11に示す検索画面において、ユーザが検索条件保存ボタンを押すことで記憶する。これにより、当該ファイルを起動することで、頻繁に同一条件で検索を行う場合に、設定時間を短縮することができる。また、ファイルを配布することで、他のユーザにも同一検索条件を示すことができる。   In this system, specific search conditions set on the search screen can be stored in a file format (step S16). Specifically, the search screen shown in FIG. 11 is stored when the user presses a search condition save button. Thus, by starting the file, the set time can be shortened when searching frequently under the same conditions. Further, by distributing the file, the same search condition can be shown to other users.

以上説明したように、本実施の形態では、ユーザがデータベースを直接検索する場合に、既存のアプリケーションレベルで規定されているユーザの権限および所属の情報に基づいて、検索対象のテーブルや項目を細かく制限できることとした。これにより、不要な情報の開示を制限することで、情報の漏洩を防止することができる。また、ユーザがデータベースを検索したときの検索条件を記憶できることとした。これにより、頻繁に同一条件で検索を行う場合の設定時間を短縮することができる。   As described above, according to the present embodiment, when a user directly searches a database, a table and items to be searched are finely divided based on user authority and affiliation information defined at an existing application level. It was decided that it could be restricted. Thereby, leakage of information can be prevented by limiting the disclosure of unnecessary information. It is also possible to store search conditions when the user searches the database. Thereby, it is possible to shorten the set time when the search is frequently performed under the same conditions.

なお、図12は、本実施の形態にかかる検索画面自動生成システムとしての機能を備え、本実施の形態のデータベース検索プログラムを実行可能な電子計算機の構成例を示す図である。   FIG. 12 is a diagram illustrating a configuration example of an electronic computer that has a function as a search screen automatic generation system according to the present embodiment and can execute the database search program according to the present embodiment.

この電子計算機は、たとえば、CPUを含む制御ユニット101(上記認証部2、ログインユーザ情報生成部3、検索制御部4に相当)と、メモリユニット102(上記記憶部6に相当)と、表示ユニット103(上記表示部5に相当)と、入力ユニット104(上記入力部1に相当)と、CD−ROMドライブユニット105と、ディスクユニット106と、外部I/Fユニット107と、を備え、これらの各ユニットは、それぞれシステムバスAを介して接続されている。   The electronic computer includes, for example, a control unit 101 including a CPU (corresponding to the authentication unit 2, the login user information generation unit 3, and the search control unit 4), a memory unit 102 (corresponding to the storage unit 6), a display unit, and the like. 103 (corresponding to the display unit 5), an input unit 104 (corresponding to the input unit 1), a CD-ROM drive unit 105, a disk unit 106, and an external I / F unit 107. The units are connected to each other via a system bus A.

図12において、制御ユニット101は、上記データベース検索プログラムを実行する。メモリユニット102は、RAM、ROM等の各種メモリを含み、上記制御ユニット101が実行すべきプログラム、処理の過程で得られた必要なデータ等を記憶する。表示ユニット103は、CRTやLCD(液晶表示パネル)等で構成され、電子計算機の使用者に対して各種画面を表示する。入力ユニット104は、キーボード、マウス等で構成され、電子計算機の使用者が、各種情報の入力を行うために使用する。また、図示のCD−ROM200には、本実施の形態の処理を記述したデータベース検索プログラムが格納されている。   In FIG. 12, the control unit 101 executes the database search program. The memory unit 102 includes various memories such as RAM and ROM, and stores programs to be executed by the control unit 101, necessary data obtained in the course of processing, and the like. The display unit 103 is composed of a CRT, LCD (liquid crystal display panel), or the like, and displays various screens to the user of the electronic computer. The input unit 104 includes a keyboard, a mouse, and the like, and is used by a user of an electronic computer to input various information. The illustrated CD-ROM 200 stores a database search program that describes the processing of the present embodiment.

ここで、上記データベース検索プログラムが実行可能な状態になるまでの電子計算機の動作例について説明する。まず、上記のように構成される電子計算機には、CD−ROMドライブユニット105にセットされたCD−ROM200から、データベース検索プログラムがディスクユニット106にインストールされる。そして、電子計算機の起動時またはプログラムの実行時に、ディスクユニット106から読み出されたプログラムがメモリユニット102に格納される。この状態で、制御ユニット101は、メモリユニット102に格納されたプログラムにしたがって、データベース検索処理を実行する。   Here, an operation example of the electronic computer until the database search program becomes executable will be described. First, in the electronic computer configured as described above, a database search program is installed in the disk unit 106 from the CD-ROM 200 set in the CD-ROM drive unit 105. Then, the program read from the disk unit 106 is stored in the memory unit 102 when the electronic computer is activated or when the program is executed. In this state, the control unit 101 executes database search processing according to a program stored in the memory unit 102.

なお、本実施の形態においては、CD−ROM200にて上記データベース検索プログラムを提供しているが、このプログラムの記録媒体は、これに限定されることなく、システムを構成するコンピュータに応じて、たとえば、フロッピー(登録商標)ディスク、DVD等の他の記録媒体を用いることも可能である。また、電子メール、インターネット等の伝送媒体により提供されたプログラムを用いることとしてもよい。   In the present embodiment, the database search program is provided by the CD-ROM 200. However, the recording medium of the program is not limited to this, and may be, for example, according to the computer constituting the system. Other recording media such as a floppy (registered trademark) disk and DVD can also be used. Moreover, it is good also as using the program provided by transmission media, such as an email and the internet.

以上のように、本発明にかかるデータベース検索システムは、データベースの検索に有用であり、特に、ユーザに応じてデータベースの検索範囲を制限可能な検索システムに適している。   As described above, the database search system according to the present invention is useful for searching a database, and is particularly suitable for a search system that can limit the search range of a database according to a user.

1 入力部
2 認証部
3 ログインユーザ情報生成部
4 検索制御部
5 表示部
6 記憶部
7 アプリケーション実行部
61 ユーザ情報格納先設定ファイル
62 ログインユーザ情報ファイル
63 デフォルト検索対象設定ファイル
64 権限別検索対象設定ファイル
65 所属別検索対象設定ファイル
66 テーブル別名ファイル
67 項目別名ファイル
68 テーブル一覧記憶部
69 検索条件記憶部
71 ユーザ情報記憶部
72 データベース
DESCRIPTION OF SYMBOLS 1 Input part 2 Authentication part 3 Login user information generation part 4 Search control part 5 Display part 6 Storage part 7 Application execution part 61 User information storage location setting file 62 Login user information file 63 Default search object setting file 64 Search object setting by authority File 65 Search target setting file by affiliation 66 Table alias file 67 Item alias file 68 Table list storage unit 69 Search condition storage unit 71 User information storage unit 72 Database

Claims (7)

ユーザの権限および所属の情報を記憶するためのユーザ情報記憶部と、アプリケーションの実行に必要なデータを格納するためのデータベースと、を備えるアプリケーション実行手段と、
ユーザの権限または所属の情報ごとに、前記データベースの中から検索可能なテーブル、テーブル内の項目、項目内の検索可能範囲が設定された検索対象記憶手段と、
前記ユーザ情報記憶部から、前記アプリケーション実行手段で割り当てられているユーザの権限および所属の情報を読み出すログインユーザ情報生成手段と、
前記ログインユーザ情報生成手段にて読み出された情報に基づいて、前記検索対象記憶手段から、ユーザが検索可能なデータベースのテーブル、テーブル内の項目、項目内の検索可能範囲を読み出し、当該検索可能範囲でユーザが検索条件を設定するための検索画面を生成する制御を行い、当該検索画面の操作により設定された検索条件に従って検索を実行する検索制御手段と、
を備えることを特徴とするデータベース検索システム。
Application execution means comprising: a user information storage unit for storing user authority and affiliation information; and a database for storing data necessary for execution of the application;
A search target storage unit in which a table that can be searched from the database, items in the table, and a searchable range in the items are set for each user authority or affiliation information;
Login user information generation means for reading out user authority and affiliation information assigned by the application execution means from the user information storage unit,
Based on the information read by the login user information generating means, the database table that can be searched by the user, the items in the table, the searchable range in the items are read from the search target storage means, and the search is possible Search control means for performing a control for generating a search screen for a user to set a search condition in a range, and executing a search according to the search condition set by operation of the search screen;
A database search system comprising:
さらに、
前記ユーザ情報記憶部が備えるユーザの権限および所属の情報を記憶しているテーブル名およびテーブル内の項目名の情報を記憶するためのユーザ情報格納先記憶手段、
を備え、
前記ログインユーザ情報生成手段は、
前記ユーザ情報格納先記憶手段から、ユーザの権限および所属の情報を記憶しているテーブル名およびテーブル内の項目名を読み出し、当該読み出したテーブル名および項目名に基づいて、前記ユーザ情報記憶部からユーザの権限および所属の情報を読み出す、
ことを特徴とする請求項1に記載のデータベース検索システム。
further,
User information storage destination storage means for storing information of table names and item names in the table storing user authority and affiliation information provided in the user information storage unit,
With
The login user information generation means includes:
From the user information storage destination storage means, the table name storing the authority and affiliation information of the user and the item name in the table are read, and based on the read table name and item name, the user information storage unit Read user authority and affiliation information,
The database search system according to claim 1.
さらに、
ユーザにより設定された検索条件を記憶するための検索条件記憶手段、
を備え、
前記検索制御手段が、前記検索条件記憶手段に記憶された検索条件を読み出し、当該読み出した検索条件に基づいて検索画面を再現可能とする、
ことを特徴とする請求項1または2に記載のデータベース検索システム。
further,
Search condition storage means for storing search conditions set by a user;
With
The search control means reads the search condition stored in the search condition storage means, and enables the search screen to be reproduced based on the read search condition.
The database search system according to claim 1, wherein the database search system is a database search system.
データベース検索システムのデータベース検索方法であって、
前記データベース検索システムが、
ユーザの権限および所属の情報を記憶するためのユーザ情報記憶部と、アプリケーションの実行に必要なデータを格納するためのデータベースと、を備えるアプリケーション実行手段と、
ユーザの権限または所属の情報ごとに、前記データベースの中から検索可能なテーブル、テーブル内の項目、項目内の検索可能範囲が設定された検索対象記憶手段と、
データベースを検索する制御手段と、
を備えることとし、
前記制御手段が、前記ユーザ情報記憶部から、前記アプリケーション実行手段で割り当てられているユーザの権限および所属の情報を読み出すログインユーザ情報生成ステップと、
前記制御手段が、前記ログインユーザ情報生成ステップにて読み出された情報に基づいて、前記検索対象記憶手段から、ユーザが検索可能なデータベースのテーブル、テーブル内の項目、項目内の検索可能範囲を読み出し、当該検索可能範囲でユーザが検索条件を設定するための検索画面を生成する制御を行い、当該検索画面の操作により設定された検索条件に従って検索を実行する検索制御ステップと、
を含むことを特徴とするデータベース検索方法。
A database search method for a database search system,
The database search system is
Application execution means comprising: a user information storage unit for storing user authority and affiliation information; and a database for storing data necessary for execution of the application;
A search target storage unit in which a table that can be searched from the database, items in the table, and a searchable range in the items are set for each user authority or affiliation information;
Control means for searching the database;
With
A log-in user information generation step for reading out the authority and affiliation information of the user assigned by the application execution unit from the user information storage unit;
Based on the information read in the logged-in user information generation step, the control means stores a database table, items in the table, and searchable ranges in the items that can be searched by the user from the search target storage means. A search control step for performing a control to generate a search screen for the user to set a search condition in the searchable range, and to execute a search according to the search condition set by operating the search screen;
A database search method comprising:
前記データベース検索システムが、さらに、
前記ユーザ情報記憶部が備えるユーザの権限および所属の情報を記憶しているテーブル名およびテーブル内の項目名の情報を記憶するためのユーザ情報格納先記憶手段、
を備えることとし、
前記ログインユーザ情報生成ステップでは、前記制御手段が、前記ユーザ情報格納先記憶手段から、ユーザの権限および所属の情報を記憶しているテーブル名およびテーブル内の項目名を読み出し、当該読み出したテーブル名および項目名に基づいて、前記ユーザ情報記憶部からユーザの権限および所属の情報を読み出す、
ことを特徴とする請求項4に記載のデータベース検索方法。
The database search system further comprises:
User information storage destination storage means for storing information of table names and item names in the table storing user authority and affiliation information provided in the user information storage unit,
With
In the login user information generation step, the control means reads out the table name storing the user's authority and affiliation information and the item name in the table from the user information storage destination storage means, and the read table name And based on the item name, read the authority and affiliation information of the user from the user information storage unit,
The database search method according to claim 4.
前記データベース検索システムが、さらに、
ユーザにより設定された検索条件を記憶するための検索条件記憶手段、
を備えることとし、
前記制御手段が、ユーザにより設定された検索条件を前記検索条件記憶手段に記憶する検索条件記憶ステップと、
前記制御手段が、前記検索条件記憶手段に記憶された検索条件を読み出し、当該読み出した検索条件に基づいて検索画面を再現する検索画面再現ステップと、
を含むことを特徴とする請求項4または5に記載のデータベース検索方法。
The database search system further comprises:
Search condition storage means for storing search conditions set by a user;
With
A search condition storage step in which the control means stores a search condition set by a user in the search condition storage means;
A search screen reproduction step in which the control means reads the search condition stored in the search condition storage means, and reproduces the search screen based on the read search condition;
The database search method according to claim 4, further comprising:
請求項4、5または6に記載のデータベース検索方法をコンピュータに実行させることを特徴とするデータベース検索プログラム。   A database search program for causing a computer to execute the database search method according to claim 4, 5 or 6.
JP2009133446A 2009-06-02 2009-06-02 System, method and program for retrieving database Pending JP2010282298A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2009133446A JP2010282298A (en) 2009-06-02 2009-06-02 System, method and program for retrieving database

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2009133446A JP2010282298A (en) 2009-06-02 2009-06-02 System, method and program for retrieving database

Publications (1)

Publication Number Publication Date
JP2010282298A true JP2010282298A (en) 2010-12-16

Family

ID=43538991

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2009133446A Pending JP2010282298A (en) 2009-06-02 2009-06-02 System, method and program for retrieving database

Country Status (1)

Country Link
JP (1) JP2010282298A (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH08241337A (en) * 1994-12-16 1996-09-17 Mitsubishi Electric Corp Data base device
JPH1196183A (en) * 1997-09-16 1999-04-09 Nippon Steel Corp Method and device for access control over data base, and management system
JPH11338825A (en) * 1998-05-29 1999-12-10 Hitachi Ltd Access control method considering configuration of organization
JPH11345211A (en) * 1998-06-02 1999-12-14 Casio Comput Co Ltd Data processor and storage medium
JP2000137735A (en) * 1998-10-29 2000-05-16 Casio Comput Co Ltd Access controller and program recording medium therefor

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH08241337A (en) * 1994-12-16 1996-09-17 Mitsubishi Electric Corp Data base device
JPH1196183A (en) * 1997-09-16 1999-04-09 Nippon Steel Corp Method and device for access control over data base, and management system
JPH11338825A (en) * 1998-05-29 1999-12-10 Hitachi Ltd Access control method considering configuration of organization
JPH11345211A (en) * 1998-06-02 1999-12-14 Casio Comput Co Ltd Data processor and storage medium
JP2000137735A (en) * 1998-10-29 2000-05-16 Casio Comput Co Ltd Access controller and program recording medium therefor

Similar Documents

Publication Publication Date Title
RU2427896C2 (en) Annotation of documents in jointly operating applications by data in separated information systems
JP4865642B2 (en) Access right setting device, access right setting method, and access right setting program
JP2007249613A (en) Thermal analysis measurement system, and method of automatically setting measurement data file name
WO2020067531A1 (en) Help information display system, help information display method, and help information display program
JP4940198B2 (en) Document management apparatus, document management program, and recording medium
US10324975B2 (en) Bulk keyword management application
KR20130126614A (en) Application file system access
JP2010282298A (en) System, method and program for retrieving database
JP2008276672A (en) Information processing program, information processor, and information processing system
JP5141164B2 (en) Database system, server, information browsing restriction method by region, program, and recording medium
JP6123519B2 (en) Information processing apparatus and information processing program
JP2006252045A (en) Device, method, and program for displaying file classification
JP2008299816A (en) Information processor, data displaying method and data display program
JP5045963B2 (en) Content selection device and program thereof
JP2021039624A (en) Information processing device and information processing system
JP4611778B2 (en) Database system, database search server, program, and recording medium
JP5443231B2 (en) Information processing apparatus, information processing method, and program
JP4723885B2 (en) SEARCH DEVICE, SEARCH PROGRAM, AND SEARCH METHOD
JP2011008372A (en) Program and apparatus for processing information
JP2009211165A (en) Information processor, document preparation system and program
JP4791109B2 (en) Content information output support apparatus and content information browsing system
JP2017219897A (en) Program and recording medium
JP2023064364A (en) Document management apparatus, document management system, document management method, and program
JP6519150B2 (en) Program, control device and control method
JP4770206B2 (en) File classification display device and file classification display program

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20120528

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20130723

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20130730

A02 Decision of refusal

Free format text: JAPANESE INTERMEDIATE CODE: A02

Effective date: 20131210