JP2004213348A - Data base retrieving device, data base retrieving method, program, and recording medium - Google Patents

Data base retrieving device, data base retrieving method, program, and recording medium Download PDF

Info

Publication number
JP2004213348A
JP2004213348A JP2002382470A JP2002382470A JP2004213348A JP 2004213348 A JP2004213348 A JP 2004213348A JP 2002382470 A JP2002382470 A JP 2002382470A JP 2002382470 A JP2002382470 A JP 2002382470A JP 2004213348 A JP2004213348 A JP 2004213348A
Authority
JP
Japan
Prior art keywords
search
data
database
information
server
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.)
Granted
Application number
JP2002382470A
Other languages
Japanese (ja)
Other versions
JP4109988B2 (en
Inventor
Yoshiyuki Terakado
祥幸 寺門
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.)
Canon Marketing Japan Inc
Original Assignee
Canon Marketing Japan Inc
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 Canon Marketing Japan Inc filed Critical Canon Marketing Japan Inc
Priority to JP2002382470A priority Critical patent/JP4109988B2/en
Publication of JP2004213348A publication Critical patent/JP2004213348A/en
Application granted granted Critical
Publication of JP4109988B2 publication Critical patent/JP4109988B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Images

Landscapes

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

Abstract

<P>PROBLEM TO BE SOLVED: To further improve the convenience of a user in a retrieval operation. <P>SOLUTION: A server 2 stores information associated with the past data retrieval processing to a free retrieval data base 22, and at the time of executing data retrieval to the free retrieval data base 22, the retrieval processing is executed by using the stored information. Thus, the re-retrieval processing to the data base can be executed by using information associated with the past data retrieval processing to the data base, and narrowing-down retrieval can be executed without re-inputting information for retrieval. <P>COPYRIGHT: (C)2004,JPO&NCIPI

Description

【0001】
【発明の属する技術分野】
本発明は、複数のデータテーブルによって構成される、例えばスタースキーマ型データベースに対するデータ検索処理を行うための技術に関するものである。
【0002】
【従来の技術】
従来のデータベース検索システムにおいては、クエリー(問い合わせ)実行のためのスキーマ生成をプログラム毎に行っていた。クエリー生成の際にはデータベースの知識を必ず必要とし、知識のない一般ユーザは用意されたクエリーを実行するために、予め設定された条件パラメータに数値やテキストなどを入力し、データベースの検索を行い、検索結果を得ていた。
【0003】
しかし、これでは、クエリー実行のためのスキーマ生成に費やすソフト開発者の労力が大きく、ユーザが利用できる検索条件や検索結果の自由度が少ない。そこで、特開2002−117041号公報には、それらの問題点を解決するための技術が開示されている。本従来文献の図1に示されるように、本従来技術では、初期処理部111はユーザによって表示/入力装置11から照会対象の表名称が指定されると、指定された表の列情報をファイル装置12からデータベース管理部120を介して読み込む。そして、照会条件設定処理部112は読み込んだ列情報に基づき照会条件であるクエリーを設定する。照会処理部113は設定されたクエリーからSQL(Structured Query Language)文を組み立ててデータベース管理部120に引き渡し、また、データベースのアクセス結果をデータベース管理部120から受けると編集して表示/入力装置11に表示するものである。
【0004】
また、特開2000−187665号公報では、データベースに関する専門知識を有していないエンドユーザであっても、データベースから必要なデータを自在に導出できるようにするデータベースシステムが開示されている。本従来技術は、特に、DWH(Data Warehouse)のような複雑なリレーショナルデータベースからのデータ検索を一般ユーザが簡単に行うためにSOVF(Subject Oriented Virtual File)と呼ぶ仮想ファイルを作成しておき、データベースの知識のないユーザが簡単にデータ検索を行えるようにし、SOVFに設定されている各項目に対応するキー情報を基にSQLの自動生成を行い、データ検索を行うものである。
【0005】
【特許文献1】
特開2002−117041号公報
【特許文献2】
特開2000−187665号公報
【0006】
【発明が解決しようとする課題】
しかしながら、特開2002−11741号公報に開示されるデータ照会システムにおいては、データベースの構造(スキーマ)を理解していないユーザが容易に検索条件を設定することはできるものの、複数の表形式のデータテーブルで構成されるDWHのようなデータベースに対して同時に複数の表形式のデータテーブルを検索することに適応した場合のクエリー生成を行うことは意図されていない。
【0007】
また、特開2000−187665号公報に開示されるデータベースシステムは、複雑なスキーマのデータベースに対してデータ検索を行うことが可能であるが、ユーザの設定した仮想ファイル毎にデータベース構造に詳しい管理者が連結キーなどを理解しつつリレーショナルを意識した仮想ファイルを構築する必要があり、管理者の労力が大きい。
【0008】
また、特開2002−11741号公報或いは特開2000−187665号公報に開示されるクエリー生成は、一度きりの検索を目的としたものであり、段階的な検索、例えば検索結果に対して絞込が容易に行えるものではない。再度検索条件に検索結果に用いた出力条件(出力項目)を加えて再度最初から検索条件を設定する必要があり、不便である。
【0009】
複数の表形式のデータベースからなるリレーショナルデータベースでは、例えば特開2000−187665号公報に開示されるように、検索条件(WHERE)に連結キー情報を用いるだけであり、連結キーの情報は偶然的に出力条件にあったとしても、一度検索が終わるとその後残されていないので、絞込や出力条件(出力項目)の変更などの検索が行えない。
【0010】
本発明は、上記問題点に鑑みてなされたものであり、検索操作時におけるユーザの利便性を更に向上させることが可能なデータベース検索装置、データベース検索方法、プログラム及び記録媒体を提供することを目的とする。
【0011】
【課題を解決するための手段】
斯かる目的を達成するために、本発明のデータベース検索装置は、データベースに対する過去のデータ検索処理に係る情報を格納する格納手段を有し、前記格納手段に格納される前記情報を用いて、前記データベースに対する検索処理を再度実行することを特徴とする。
【0012】
また、本発明のデータベース検索方法は、データベースに対する過去のデータ検索処理に係る情報を格納手段に格納し、前記格納手段に格納される前記情報を用いて前記データベースに対する検索処理を再度実行することを特徴とする。
【0013】
また、本発明のプログラムは、前記データベース検索方法をコンピュータに実行させることを特徴とする。さらに、本発明のコンピュータ読み取り可能な記録媒体は、前記プログラムを記録したことを特徴とする。
【0014】
【発明の実施の形態】
以下、本発明の好適な実施形態を、添付図面を参照しながら詳細に説明する。<データベース検索システムの構成>
図1は、本発明の一実施形態に係るデータベース検索システムの構成を模式的に示した図である。
1は、ユーザが操作するクライアントPCであり、Webブラウザを用いてサーバから送信されるWebページを画面上で表示することが可能である。2は、各種データを記録した自由検索DB22(自由検索データベース)を備えたサーバであり、自由検索/自由帳票アプリケーション21(以下、単にアプリケーションと称す)によりクライアントPC1の要求に応じたデータを検索し、その結果をWebページで各クライアントPC1に送信することが可能である。3は、システムDBサーバであり、自由検索DB22に格納すべきデータを逐次或いはバッチ処理によりサーバ2に対して送信することが可能である。
【0015】
サーバ2に接続される各クライアント1は、画面上で所望の検索条件及び出力データ項目を入力し、その入力内容をサーバ2に対して送信する。当該入力内容を受けたサーバ2は、出力データ項目に挙げられたデータのうち検索条件に合致するデータを自由検索DB22から取得する。次に、サーバ2は、取得したデータを例えばCSV(Comma Separated Value)データとしてクライアントPC1に返信し、当該クライアントPC1では検索結果を画面上で確認することが可能となる。
【0016】
また、本実施形態では、上記のように検索したデータを帳票として取得することも可能である。この場合、クライアントPC1上においてユーザは帳票の出力形式を指定することが可能である。クライアントPC1上において出力形式が指定されると、その指定情報はクライアントPC1からサーバ2に対して送信される。サーバ2では、指定された帳票に必要なデータをアプリケーション21の機能により上記検索条件に照らして検索し、帳票データを生成してクライアントPC1に対して送信する。これにより、ユーザは、所望の検索条件及び出力形式で帳票データを参照することが可能となる。
【0017】
<データベース検索システムの主要動作>
次に、本実施形態に係るデータベース検索システムの動作を図2及び図3を用いて詳細に説明する。図2及び図3は、本実施形態に係るデータベース検索システムの主要動作を示したフローチャートである。
ユーザは、クライアントPC1を操作することにより、自らのユーザID及びパスワードをクライアントPC1からサーバ2に送信する。サーバ2では、クライアントPC1から受信したユーザID及びパスワードに基づいて当該ユーザの認証処理を行い(ステップS201)、認証が得られた場合は、当該ユーザの本データベース検索システムへのログインを許可する。
【0018】
続いて、サーバ2は、図4の検索条件画面を生成し、クライアントPC1に対して送信する(ステップS202)。クライアントPC1は、サーバ2から受信した検索条件画面を表示する(ステップS102)。次に、ユーザは検索画面上で検索条件を入力する。ユーザは、検索条件の入力時において、例えば、画面左欄の“データ分類”から“商品”(図4中の41)を選択し、続いてデータ分類“商品”に属するデータ項目“商品名”(図4中の42)を選択する。すると、画面上に小ウィンドウ43が表示され、ユーザはこの小ウィンドウ43内で検索内容(ここでは、M−4 小鉢 )を選択入力する。条件指定No.1についても同様の入力手法により検索条件(データ分類“期間”、データ項目“年月日”、検索内容“1996/12/09から1996/12/11まで”)を選択入力する。
【0019】
上述の“商品”或いは“期間”はそれぞれ図20及び図21に示されるデータテーブルを意味し、“商品名”或いは“年月日”はそれぞれのデータテーブル内のカラム名であり、小ウィンドウ43を用いて選択入力した“M−4 小鉢 “等は各カラムに対するデータである。つまり、図4において“データ分類”は選択したデータテーブルであり、“データ項目”はカラムであり、“検索内容”がカラム内で検索するべき内容(データ内容)である。サーバ2はユーザがデータテーブルを指定する際に、テーブル情報を参照し、テーブルに存在するカラム名を表示画面データとして作成し提供する。また、カラム名が選択された場合には小ウィンドウ43で示したようにカラム内のデータを表示画面用のデータとして生成し、提供するものである。
【0020】
条件指定No.1、条件指定No.2の欄それぞれにつき検索条件が確定する度に、その入力内容はクライアントPC1からサーバ2に送信され(ステップS104)、サーバ2では、受信した入力内容をその都度保存し(ステップS204)、当該入力内容を反映させた新たな検索条件画面を生成し、クライアントPC2に対して送信する(ステップS202)。
【0021】
続いて、図4の画面上において、ユーザが“データ出力”ボタン(図4中の44)を押下した場合(ステップS107)、クライアントPC1上においてデータ出力処理が指定された旨の情報がクライアントPC1からサーバ2に対して送信される(ステップS108)。サーバ2では、ステップS205の判断分岐により処理をステップS206に移行させる。一方、クライアントPC1では処理をステップS108に移行させる。
【0022】
サーバ2側では、ステップS206において、図5の出力項目選択画面を生成し、クライアントPC1に対して送信する。クライアントPC1では、出力項目選択画面をサーバ2から受信し、表示する(ステップS109)。ユーザは、この出力項目選択画面上で出力させたい所望の項目を選択する(ステップS110)。選択要領は、図4の検索条件の入力時と同様である。図5の例では、ユーザが選択した出力項目は、データ分類“期間”のデータ項目“年月日”、データ分類“商品”のデータ項目“商品名”、データ分類“商品”のデータ項目“標準売価”、データ分類“商品”のデータ項目“標準原価”、及び、データ分類“商品”のデータ項目“取扱開始日”である。
【0023】
ここでも、各出力項目が確定される度に、その入力内容がクライアントPC1からサーバ2に送信され(ステップS111)、サーバ2では、受信した入力内容をその都度保存し(ステップS208)、当該入力内容を反映させた新たな検索条件画面を生成し、クライアントPC1に対して送信する(ステップS206)。
【0024】
ユーザは、所望の入力項目を全て確定させると、出力項目選択画面の“次へ”ボタン(図5中の51)を押下する(ステップS112)。クライアントPC1は、ユーザの操作により“次へ”ボタンが押下されると、その旨をサーバ2に対して通知する(ステップS113)。当該通知を受けたサーバ2は、表示指定画面を生成し、クライアントPC1に対して送信する(ステップS210)。表示指定画面の一例を図6に示す。
【0025】
続いて、ユーザは、表示指定画面上において、各出力項目につき表示方法を指定する(ステップS115)。図6の例では、各出力項目につきデータを一覧表示するか否か(図6中の61)、データのソート順(昇順、降順;図6中の62)、及び、ソート処理の優先順位を指定(図6中の63)することが可能である。ここでも、例えば、各項目の表示指定内容が確定される度に、その入力内容がクライアントPC1からサーバ2に送信され(ステップS116)、サーバ2では、受信した入力内容をその都度保存し(ステップS212)、当該入力内容を反映させた新たな検索条件画面を生成し、クライアントPC1に対して送信する(ステップS210)。
【0026】
続いて、図6の画面上において、ユーザが“検索”ボタン(図6中の64)を押下した場合(ステップS117)、ユーザから検索指定の指示入力があった旨の情報がクライアントPC1からサーバ2に対して送信される(ステップS118)。サーバ2では、ステップS213の判断分岐を経てステップS214の処理の後、処理をステップS214に移行させる。一方、クライアントPC1では処理をステップS119に移行させる。尚、ステップS214のクエリー生成処理等については後述する。
【0027】
続いて、アプリケーション21は、自由検索DB22から検索結果を受信することにより、サーバ2は、クライアントPC1に対して検索結果の一覧画面を送信する(ステップS215)。クライアントPC1では、検索結果一覧画面をサーバ2から受信し、表示する(ステップS119)。検索結果一覧画面の一例を図7に示す。図6の一覧表示指定チェックボックスにおいて、出力項目のすべての項目がチェックされているので表示結果にはすべての項目が表示されている。
【0028】
図7の検索結果一覧画面上においては、さらに出力データの絞込検索を行うことができる。ユーザの操作入力により、図7の検索結果一覧画面上において出力データが選択(図7中の71)されると(ステップS120)、その入力内容がクライアントPC1からサーバ2に送信される(ステップS121)。サーバ2では、受信した入力内容をその都度保存し(ステップS217)、当該入力内容を反映させた新たな検索結果一覧画面を生成し、クライアントPC1に対して送信する(ステップS215)。
【0029】
続いて、図7の画面上において、ユーザが“データ出力”ボタン(図7中の72)を押下した場合(ステップS122)、ユーザからデータ出力指示があったことがクライアントPC1からサーバ2に対して送信される(ステップS123)。サーバ2では、ステップS218の判断分岐を経て、アプリケーション21は保存した出力データ選択情報に基づくクエリーを生成し、自由検索DB22に対して送信する(ステップS219)。
【0030】
続いて、アプリケーション21が上記クエリーに応じて自由検索DB22から返信された検索結果を受信することにより、サーバ2は、検索ヒット件数情報をクライアントPC1に対して送信する(ステップS220)。クライアントPC1は、サーバ2から受信した検索ヒット件数情報を画面上で表示する(ステップS125)。検索ヒット件数表示画面の一例を図8に示す。ユーザは、クライアントPC1の画面上に表示された検索ヒット件数を確認した後、検索されたデータをCSVファイルとして受け取りたい場合には、図8の画面上において“実行”ボタン(図8中の81)を押下する(ステップS126)。
【0031】
この“実行”ボタンが押下されると、クライアントPC1からその旨の情報がサーバ2に対して送信され(ステップS127)、サーバ2は、CSVファイルを要求する旨の情報を受信すると、クライアントPC1に対してCSVファイルを返信する(ステップS222)。これにより、ユーザは、絞込検索による検索結果をCSVファイルで閲覧することができる。
【0032】
一方で、図7の検索結果一覧画面上において、“帳票出力”ボタン(図7中の73)が押下されると(ステップS124)、ユーザにより帳票出力の指定があったことがクライアントPC1からサーバ2に対して送信され、サーバ2では、ステップS218の判断分岐により処理をステップS223に移行させる。
【0033】
続いて、サーバ2は、例えば図9に示す帳票一覧画面をクライアントPC1に対して送信する(ステップS223)。クライアントPC1は、サーバ2から帳票一覧画面を受信し、表示する(ステップS130)。ユーザは、クライアントPC1上に表示された帳票一覧画面を参照し、所望の形式の帳票を選択する。次に、クライアントPC1は、帳票選択情報をサーバ2に対して送信する(ステップS131)。
【0034】
続いて、サーバ2がクライアントPC1から帳票選択情報を受信すると(ステップS224)、アプリケーション21はその帳票選択情報に応じたクエリーを生成し、自由検索DB22に対して送信する(ステップS225)。本クエリ−生成に関しては後述する。次に、アプリケーション21が自由検索DB22から返信された検索結果を受信すると、サーバ2は、検索ヒット件数をカウントして検索ヒット件数情報としてクライアントPC1に対して送信する(ステップS226)。
【0035】
クライアントPC1では、サーバ2から受信した検索ヒット件数情報を表示する(ステップS132)。検索ヒット件数情報の表示例を図10に示す。ユーザは、帳票を出力させたい場合、クライアントPC上で表示される検索ヒット件数情報を確認した後、図10の画面上の“実行”ボタン(図10中の101)を押下する(ステップS133)。この“実行”ボタンが押下されると、クライアントPC1からサーバ2に対して帳票出力実行の指定があったことが通知される(ステップS134)。
【0036】
帳票出力実行の指定を受けたサーバ2は、内部で検索結果を帳票作成プログラムに送信し(ステップS227)、帳票作成プログラムから帳票のPDFデータを受信する(ステップS228)。そして、サーバ2は、帳票のPDFデータと自由検索DB22から取得した検索結果データを合成した帳票画面をクライアントPC1に対して送信する(ステップS229)。この合成は、予め各帳票のPDFデータに対して、図19に示す帳票データ格納テーブルの各カラムデータの合成位置を決めてテキストデータなどで貼り付け、図18に示す帳票情報格納テーブルにあるKEY_CLM_ID毎に一枚の帳票として合成するものである。クライアントPC1では、サーバ2から受信した図11の帳票画面を表示する(ステップS135)。図11では、図9の帳票一覧画面上において“商品別店舗売上表”が選択された場合を例示しており、図7の検索結果一覧画面上における絞込検索が反映されている。即ち、図7上では、年月日“1996/12/10”、商品名“M−4 小鉢”の項目と、年月日“1996/12/11”、商品名“M−4 小鉢 ”とが選択されているため、図11の帳票画面上では、それらに該当する情報が掲載されている。
【0037】
<検索クエリー生成(初回検索時)>
次に、本発明の一実施形態に係る検索クエリー生成方法について説明する。図12は、本発明の一実施形態に係る検索クエリー生成方法の流れを示したフローチャートであり、図2のステップS214で実行される検索クエリー生成について示したものである。尚、図12及び図13に示す、検索条件格納部121、表示項目指定格納部122、リレーション情報格納テーブル123、帳票指定格納部131、検索結果格納部132、帳票情報格納テーブル133、帳票データ格納テーブル134及びリレーション情報格納テーブル135は、サーバ2内の例えばRAM等の内部記録媒体内において格納される。
【0038】
先ず、サーバ2は、図2のステップS204において保存した検索条件を検索条件格納部121から取得する(ステップS301)。ここで、取得された検索条件は、後述する検索クエリーのWHERE句の生成に用いられる。検索条件格納部121には、図4の画面上において指定された、データ分類に対応するテーブルID、データ項目に対応するカラムID及び検索内容が格納されている。
【0039】
図4の例では、条件指定No.1において、データ分類“期間”、データ項目“年月日”、検索内容“1996/12/09から1996/12/11まで”が指定されている。ここで、図14に示すテーブル情報格納テーブルを参照すると、データ分類“期間”に対応するテーブルIDは“term”である。また、図15に示すカラム情報格納テーブルを参照すると、データ項目“年月日”に対応するカラムIDは“年月日”である。従って、条件指定No.1については、検索条件格納部121にはテーブルID“term”、カラムID“年月日”、検索内容“1996/12/09から1996/12/11(BETWEEN timestamp`1996−12−09 00:00:00.000000`AND timestamp`1996−12−11 23:59:59.999999`)”が格納される。同様に、条件指定No.2については、テーブルID“goods”、カラムID“商品名”、検索内容“M−4 小鉢 ”が検索条件格納部121に格納される。
【0040】
次に、サーバ2は、表示項目指定格納部121から表示項目指定情報を取得する(ステップS302)。表示項目指定格納部122には、図5の画面上で入力された出力項目データと、図6の画面上で入力されてS212で保存された表示指定データが格納されている。図5の例では、出力項目データとして、データ分類“期間”のデータ項目“年月日”、データ分類“商品”のデータ項目“商品名”、データ分類“商品”のデータ項目“標準売価”、データ分類“商品”のデータ項目“標準原価”、及び、データ分類“商品”のデータ項目“取引開始日”が選択されている。
【0041】
、図6の例では、データ分類“商品”のデータ項目“商品名”につきソート優先順位“1”、ソート順が“昇順”と指定され、データ分類“商品”のデータ項目“取引開始日”につきソート優先順位“2”、ソート順が“昇順”と指定されている。
【0042】
従って、表示項目指定格納部122には、テーブルID“term”及びカラムID“年月日”、テーブルID“goods”、カラムID“商品名”、ソート優先順“1”及びソート順“昇順(ASC)”、テーブルID“goods”及びカラムID“標準売価”、テーブルID“goods”及びカラムID“標準原価”、テーブルID“goods”、カラムID“取引開始日”、ソート優先順“2”及びソート順“昇順(ASC)”が夫々対応付けて格納される。サーバ2は、これらの表示項目指定情報を表示項目指定格納部122から取得する。
【0043】
続いて、サーバ2は、リレーション情報格納テーブル123からリレーション情報を取得する(ステップS303)。リレーション情報格納テーブル123には、図16に示されるように、本実施形態におけるスタースキーマのデータベースにおけるディメンションテーブルである“term”、“store”、“goods”と、メインテーブルである“sls_dsgoods”とのリレーション情報を格納している。
本実施形態に適用されるスタースキーマ型リレーショナルデータベースのリレーション関係を図17に示す。
【0044】
また、本実施形態に適用可能なテーブル“goods”、“term”、“stores”、“sls_dsgoods”を、それぞれ図20、図21、図22、図23に示す。図20に示すテーブル“goods”は、カラム“対象日”、“店コード”、“商品コード”、“売上コード”等を含む。テーブル“term”は、カラム“年月日”、“年”、“月”、“日”等を含む。テーブル“stores”は、カラム“店舗コード”、“店舗名”、“規模コード”等を含む。テーブル“sls_dsgoods”は、カラム“対象日”、“店コード”、“商品コード”、“売上点数”等を含む。
【0045】
ここでは、図4や図5の画面上においてテーブル“term”、“goods”から検索項目や出力項目が選択されている。従って、サーバ2は、リレーション情報格納テーブル123からテーブル“term”、“goods”に係るリレーション情報を取得する。即ち、ここで取得されるリレーション情報は、テーブル“term”のカラム“年月日”とテーブル“sls_dsgoods”のカラム“対象日”とを対応付けたリレーション情報、及び、テーブル“goods”のカラム“商品コード”とテーブル“sls_dsgoods”のカラム“商品コード”とを対応付けたリレーション情報である。
【0046】
続いて、サーバ2は、ステップS304において、ステップS303にて取得したリレーション情報に基づいて、クエリーのWHERE句においてテーブル間の紐つけを定義するテーブルリレーション部を生成する。
具体的には、「term.年月日 = sls_dsgoods.対象日 AND goods.商品コード = sls_dsgoods.商品コード」がテーブルリレーション部として生成される。
【0047】
続いて、サーバ2は、ステップS301において取得した検索条件と、ステップS304において生成したテーブルリレーション部とに基づいて、クエリーのWHERE句(検索条件)を生成する。
【0048】
続いて、サーバは、ステップS302において取得した表示項目情報に基づいてクエリーのSELECT句を生成する。ここでは、カラム“年月日”、“商品名”、“標準売価”、“標準原価”、“取引開始日”に属するデータのうち検索条件に合致するデータをテーブル“term”、“goods”、“sls_dsgoods”から読み出すことがこのSELECT句により要求されるとともに、表示項目として選択されたテーブル“term”、“goods”の連結キーであるカラム“年月日”、“商品コード”をそれぞれ“Clm_0”、“Clm_1”と読み替えて送り返すことが同SELEDT句によって要求される。
【0049】
続いて、サーバ2は、ステップS302において取得した表示項目情報内のソート優先順、ソート順に基づいて、クエリーのORDER句を生成する。即ち、テーブル“goods”のカラム“商品名”のデータを最優先に昇順でソートし、テーブル“goods”のカラム“取引開始日”のデータを次に優先して昇順でソートすることがここで規定される。
【0050】
上記のようなクエリーの生成によって以下のSQL(Structured Query Language)文が生成される。
「SELECT DISTINCT term.年月日,goods.商品名,goods.標準売価,goods.標準原価,goods.取引開始日,term.年月日 as cngClm_0, goods.商品コード as cngClm_1
FROM term,goods,sls_dsgoods
WHERE(term.年月日=sls_dsgoods.対象日 AND goods.商品コード=sls_dsgoods.商品コード)
AND((term.年月日 BETWEEN timestamp`1996−12−09 00:00:00.000000`AND timestamp`1996−12−11 23:59:59.000000`)
AND(goods.商品名 LIKE `%M−4小鉢 %`))
ORDER BY goods.商品名 ASC,goods.取引開始日 ASC」
【0051】
<検索クエリー生成(絞込検索時)>
次に、図3のステップS225における帳票モードのクエリー生成方法について説明する。図13は、本実施形態に係る帳票モードのクエリー生成方法の流れを示したフローチャートである。
先ず、サーバ2は、ステップS224にて受信し、そして、帳票指定格納部131において格納した商品別店舗売上表に相当する帳票IDを取得する(ステップS401)。続いて、サーバ2は、検索結果格納部132からキーカラム検索結果を取得する(ステップS402)。このキーカラム検索結果とは、ステップS215において“Clm_0”、“Clm_1”としてDBから送り返された連結キーのデータであり、特に、S217で保存したキーカラム検索結果のうち図7で選択されている2つのデータに関係するキーカラム情報を取得する。例えば、「term.年月日 = timestamp’1996−12−10 23:59:59.999999’」や「goods.商品コード = ’4973307404511’」等がこれに相当する。
【0052】
次に、サーバ2は、帳票情報格納テーブル133から帳票データ情報を取得する(ステップS403)。帳票情報格納テーブルは、図18に示すように、帳票ID“REPORT_ID”、メインテーブルID“MAIN_TBL_ID”、キーカラムID“KEY_CLM_ID”、オーバーレイフォーム名“FORM_NM”などを対応付けて格納している。サーバ2は、ステップS401において取得した帳票IDに該当する帳票データ情報を帳票情報格納テーブルから取得する。即ち、ステップS401において取得される帳票IDは“803”であるため、図18の例では、帳票ID“803”、メインテーブルID“goods”、キーカラムID“商品コード”、オーバーレイフォーム名“rs_sURIAGE3.fcp”などが帳票データ情報として取得される。
【0053】
次に、サーバ2は、帳票データ格納テーブルから帳票構成項目情報を取得する(ステップS404)。帳票データ格納テーブルは、図19に示すように、帳票ID“REPORT_ID”、テーブルID“TBL_ID”、カラムID“CLM_ID”、データ生成順“SORT_ORDER”などを対応付けて格納している。サーバ2は、ステップS401において取得した帳票IDに該当する帳票構成項目情報を帳票データ格納テーブルから取得する。即ち、ステップS401において取得された帳票IDは“803”であり、図19に示す帳票データ格納テーブルの全てのレコードが読み出される。
【0054】
続いて、サーバ2は、図16のリレーション情報格納テーブルからリレーション情報を取得する(ステップS405)。ここで取得されるリレーション情報は、図19に示すように、帳票として出力されるべき出力項目のテーブルとして“goods”、“store”、“term”が含まれるため、リレーション情報格納テーブルから3つのリレーション情報が取得される。即ち、第1のリレーション情報として、テーブルID(TBL_ID)“term”、カラムID(CLM_ID)“年月日”、リレーションテーブルID(CNG_ID)“sls_dsgoods”、リレーションカラムID(CNGCLM_ID)“対象日”が取得される。第2のリレーション情報として、テーブルID(TBL_ID)“store”、カラムID(CLM_ID)“店舗コード”、リレーションテーブルID(CNG_ID)“sls_dsgoods”、リレーションカラムID(CNGCLM_ID)“店コード”が取得される。また、第3のリレーション情報として、テーブルID(TBL_ID)“goods”、カラムID(CLM_ID)“商品コード”、リレーションテーブルID(CNG_ID)“sls_dsgoods”、リレーションカラムID(CNGCLM_ID)“商品コード”が取得される。
ここでは、繰り返しを避けるためにフローチャートには記載しないが、図12のステップS301で行った検索条件取得をステップS406の実行前に実行する。
【0055】
続いて、サーバ2は、ステップS405において取得したリレーション情報からテーブルリレーション部を生成する(ステップS406)。ここでは、テーブル“goods”、“store”、“term”がそれぞれの連結キーによりテーブル“sls_dsgoods”に紐つけされていることを示すものとして、“term.年月日=sls_dsgoods.対象日 AND goods.商品コード=sls_dsgoods.商品コード AND store.店舗コード=sls_dsgoods.店コード”がテーブルリレーション部として生成される。
【0056】
続いて、サーバ2は、検索条件を示すWHERE句を生成する(ステップS407)。ここでは、図2のステップS204において検索条件格納部に格納した検索条件、及び、ステップS406において生成したテーブルリレーション部のほか、ステップS402において検索結果格納部から取得した検索結果キー情報(連結キー)、ここでは、ステップS120において選択された第1の出力項目“年月日:1996/12/10、商品名:M−4小鉢 ”に対する“timestamp`1996−12−10 23:59:59.999999`”及び“4973307404511”のデータ、並びに、同じくステップS120において選択された第2の出力項目“年月日:1996/12/11、商品名:M−4小鉢 ”に対する“timestamp`1996−12−11 23:59:59.999999`”、“4973307404511”のデータに基づいてWHERE句を生成する。
【0057】
続いて、サーバ2は、表示項目を示すSELECT句を生成する。ここでは、ステップS404において帳票データ格納テーブル134から取得した帳票構成項目情報に基づいて、カラム“商品コード”、“商品名”、“規模名”、“店舗コード”、“店舗名”、“年月日”、“標準売価”、“標準原価”、“売上点数”、“売上売価金額”を表示項目としてテーブル“term”、“goods”、“store”、“sls_dsgoods”から取得して表示する旨をSELECT句で規定している。
【0058】
続いて、サーバ2は、ソート順を示すORDER句を生成する。ここでは、ステップS404において取得した帳票構成項目情報の“SORT_ORDER”及び“AD_CLASS”に基づいて、テーブル“goods”のカラム“商品コード”、テーブル“store”のカラム“店舗コード”の優先順位でそれぞれを昇順でソートする旨が規定される。
【0059】
このようにして生成されるクエリーは以下のようになる。
「SELECT DISTINCT goods.商品コード,goods.商品名,store.規模名,store.店舗コード,store.店舗名,term.年月日,goods.標準売価,goods.標準原価,sls_dsgoods.売上点数,sls_dsgoods.売上売価金額
FROM term,goods,store,sls_dsgoods
WHERE ((term.年月日 BETWEEN timestamp`1996−12−09 00:00:00.000000`AND (goods.商品名 LIKE `%M−4小鉢 %`))
AND ((term.年月日 = timestamp`1996−12−10 23:59:59.999999`AND goods.商品コード = `4973307404511`)
OR (term.年月日 = timestamp`1996−12−11 23:59:59.999999`)
AND goods.商品コード = `4973307404511`))
AND (term.年月日 = sls.ds_goods.商品コード
AND goods.商品コード = sls_dsgoods.商品コード
AND store.店舗コード = sls_dsgoods.店コード
ORDER BY goods.商品コード ASC、store.店舗コード ASC」
【0060】
上記のように、絞込検索によって生成されるクエリーには、前回の出力項目を含むテーブルの連結キーに対する検索結果が新たな検索条件として反映されている(term.年月日 = timestamp`1996−12−10 23:59:59.999999`AND goods.商品コード = `4973307404511`) OR (term.年月日 = timestamp`1996−12−11 23:59:59.999999`)。例えば、前回(一回目)の検索の際に“商品コード”は出力項目或いは表示項目としては指定されていないにも係わらず自由検索DB22に対してのデータ出力条件としてSELECT句に入れ、さらにこれを保存していることにより可能とするものである。つまり、ステップS215において“Clm_0”、“Clm_1”としてデータの出力項目や表示項目とは別に連結キーを自由DB22より情報取得して保存することで、後の検索クエリー生成に備えるものである。さらには、図12を用いて詳述したステップ204のクエリ−生成においては、
「SELECT DISTINCT term.年月日,goods.商品名,goods.標準売価,goods.標準原価,goods.取引開始日FROM term,goods,sls_dsgoods
WHERE(term.年月日=sls_dsgoods.対象日 AND goods.商品コード=sls_dsgoods.商品コード)
AND((term.年月日 BETWEEN timestamp`1996−12−09 00:00:00.000000`AND timestamp`1996−12−11 23:59:59.000000`)
AND(goods.商品名 LIKE `%M−4小鉢 %`))
ORDER BY goods.商品名 ASC,goods.取引開始日 ASC」
としても図7に示す検索結果の表示を作成することは可能である。また従来の技術によれば、このようにSQL文を生成するものである。しかし、本発明は複雑に連結キーで連結されるスキーマを有するデータベースに対して更なる絞り込み検索を行い、検索結果をさまざまな出力項目を有する各種の帳票へのデータ合成を可能とするために上述のようなクエリ−生成を行うものである。
【0061】
これにより、絞込検索の際に前回の出力項目をみて、再度検索条件に反映させて再検索を行うる手間が省け、新たな絞込条件のみの入力により絞込検索を実行することが可能となり、ユーザにとって検索操作が容易になる。同じく、当該連結キーに対する検索結果が新たな検索条件に反映されることによって、前回の出力項目を含むテーブル内における出力項目の変更を前回の出力項目を反映させることなく容易に行うことが可能となる。また、複数の表形式のデータテーブルを有する複雑なスキーマのデータベースに対してデータベースの知識のないユーザが容易に、自由度の高い検索を行うも可能となる。
【0062】
つまり、複雑なスキーマを有するデータベースの検索においても、図7において「データ出力」の選択だけでなく、「帳票出力」といったデータの出力項目が変化した場合でも対応できる自由度をユーザに与えることができ、出力形態を検索実行前に指定したものだけ或いは予め決められたものだけしか出来ない従来のものとはその自由度は比べ物にならない。
【0063】
なお、2回目の検索におけるクエリー生成時に図7のデータ出力選択(ステップS121)においてすべてのデータが選択されたか否かをステップS216及びステップS217で判断する。そしてすべてのデータが出力対象の場合には、クエリ生成及び自由検索DB22でのクエリー解釈に時間がかかるために、すべてのデータに対して、個別に(term.年月日 = timestamp`1996−12−10 23:59:59.999999`AND goods.商品コード = `4973307404511`) OR (term.年月日 = timestamp`1996−12−11 23:59:59.999999`)の条件を作成せずにステップS407における処理ではステップS217で保存した出力データ選択条件を無視して、クエリーを生成することで効率的な検索を行うことも可能である。
【0064】
尚、CSVファイルについての絞込検索時における検索クエリー生成方法についての具体的な説明は省略したが、帳票作成時と同様の処理により検索クエリーを生成し、上記と同様の効果を奏することは勿論である。
【0065】
図24は、本実施形態におけるサーバ2のハードウェア構成を示した図である。
CPU201は、システムバス204に接続される各デバイスを統括的に制御する。また、ROM203或いは外部メモリ211には、CPU201の制御プログラムであるオペレーティングシステムプログラム(以下、OSと称す)や、各サーバ或いは各PCの実行する機能を実現するために必要な後述する各種プログラム等が記憶されている。RAM202は、CPU201の主メモリ、ワークエリア等として機能する。
【0066】
キーボードコントローラ(KBC)205は、キーボード209や不図示のポインティングデバイスからのキー入力を制御する。CRTコントローラ(CRTC)206は、CRTディスプレイ(CRT)210の表示を制御する。これらは必要に応じて管理者が使用するものである。本発明には直接関係あるものではない。
【0067】
外部メモリコントローラ(MC)207は、ブートプログラム、ブラウザソフトウェア、各種のアプリケーション、フォントデータ、ユーザファイル、編集ファイル、データベースマネージメントシステム(DBMS)、各種データ等を記憶するハードディスク(HD)やフレキシブルディスク(FD)或いはPCMCIAカードスロットにアダプタを介して接続されるコンパクトフラッシュ(R)メモリ等の外部メモリ211へのアクセスを制御する。
【0068】
通信I/Fコントローラ208は、ネットワークを介して外部機器と接続するものであり、ネットワークでの通信制御処理を実行する。例えば、TCP/IPを用いたインターネット通信等が可能である。なお、CPU201は、例えばRAM202内の表示情報用領域へアウトラインフォントの展開(ラスタライズ)処理を実行することにより、CRT210上での表示を可能としている。また、CPU201は、CRT210上の不図示のマウスカーソル等でのユーザ指示を可能とする。上述の動作フローチャートで説明した各処理に係わるプログラムや自由検索DB22は外部メモリ211に記憶され、各種プログラムは必要に応じてRAM202に読み出されてCPU201が実行するものである。
【0069】
また、本発明の目的は、前述した実施形態の機能を実現するソフトウェアのプログラムコードを記録した記憶媒体を、システム或いは装置に供給し、そのシステム或いは装置のコンピュータ(またはCPUやMPU)が記憶媒体に格納されたプログラムコードを読み出し実行することによっても、達成されることは言うまでもない。
【0070】
この場合、記憶媒体から読み出されたプログラムコード自体が前述した実施形態の機能を実現することになり、プログラムコード自体及びそのプログラムコードを記憶した記憶媒体は本発明を構成することになる。
【0071】
プログラムコードを供給するための記憶媒体としては、例えば、フレキシブルディスク、ハードディスク、光ディスク、光磁気ディスク、CD−ROM、CD−R、磁気テープ、不揮発性のメモリカード、ROM等を用いることができる。
【0072】
また、コンピュータが読み出したプログラムコードを実行することにより、前述した実施形態の機能が実現されるだけでなく、そのプログラムコードの指示に基づき、コンピュータ上で稼動しているOSなどが実際の処理の一部又は全部を行い、その処理によって前述した実施形態の機能が実現される場合も含まれることは言うまでもない。
【0073】
さらに、記憶媒体から読み出されたプログラムコードが、コンピュータに挿入された機能拡張ボードやコンピュータに接続された機能拡張ユニットに備わるメモリに書込まれた後、そのプログラムコードの指示に基づき、その機能拡張ボードや機能拡張ユニットに備わるCPU等が実際の処理の一部又は全部を行い、その処理によって前述した実施形態の機能が実現される場合も含まれることは言うまでもない。
【0074】
【発明の効果】
本発明によれば、データベースに対する過去のデータ検索処理に係る情報を用いて、当該データベースに対する検索処理を再度実行可能に構成したので、絞込検索を実行するとき等、過去の検索処理に係る情報が必要な検索処理を実行する場合において、ユーザは、その過去の検索処理に係る情報を再度入力するために以前検索した画面を参照する手間等から回避され、検索操作時におけるユーザの利便性を向上させることができる。
【図面の簡単な説明】
【図1】本発明の一実施形態に係るデータベース検索システムの構成を模式的に示した図である。
【図2】本発明の一実施形態に係るデータベース検索システムの主要動作を示したフローチャートである。
【図3】本発明の一実施形態に係るデータベース検索システムの主要動作を示したフローチャートである。
【図4】検索条件画面の一例を示した図である。
【図5】出力項目選択画面の一例を示した図である。
【図6】表示指定画面の一例を示した図である。
【図7】検索結果一覧画面の一例を示した図である。
【図8】検索ヒット件数表示画面の一例を示した図である。
【図9】帳票一覧画面の一例を示した図である。
【図10】検索ヒット件数表示画面の一例を示した図である。
【図11】帳票画面の一例を示した図である。
【図12】本発明の一実施形態に係る検索クエリー生成方法の流れを示したフローチャートである。
【図13】本発明の一実施形態に係る検索クエリー生成方法の流れを示したフローチャートである。
【図14】テーブル情報格納テーブルの一構成例を示した図である。
【図15】カラム情報格納テーブルの一構成例を示した図である。
【図16】リレーション情報格納テーブルの一構成例を示した図である。
【図17】本発明の一実施形態に適用されるスタースキーマ型リレーショナルデータベースのリレーション関係を示した図である。
【図18】帳票情報格納テーブルの一構成例を示した図である。
【図19】帳票データ格納テーブルの一構成例を示した図である。
【図20】テーブル“goods”の一構成例を示した図である。
【図21】テーブル“term”の一構成例を示した図である。
【図22】テーブル“stores”の一構成例を示した図である。
【図23】テーブル“sls_dsgoods”の一構成例を示した図である。
【図24】本発明の一実施形態におけるサーバのハードウェア構成を示した図である。
【符号の説明】
1:クライアントPC
2:サーバ
3:システムDBサーバ
21:自由検索/自由帳票アプリケーション
22:自由検索DB
121:検索条件格納部
122:表示項目指定格納部
123:リレーション情報格納テーブル
131:帳票指定格納部
132:検索結果格納部
133:帳票情報格納テーブル
134:帳票データ格納テーブル
135:リレーション情報格納テーブル
[0001]
TECHNICAL FIELD OF THE INVENTION
The present invention relates to a technique for performing a data search process for a star schema type database constituted by a plurality of data tables, for example.
[0002]
[Prior art]
In a conventional database search system, a schema for executing a query (query) is generated for each program. When generating a query, knowledge of the database is always required, and a general user without knowledge must enter a numerical value or text in the preset condition parameters and execute a prepared query to search the database. , Had obtained the search results.
[0003]
However, in this case, a software developer spends a great deal of effort in generating a schema for executing a query, and the degree of freedom of search conditions and search results available to the user is small. Therefore, Japanese Patent Application Laid-Open No. 2002-117041 discloses a technique for solving those problems. As shown in FIG. 1 of the related art, in the related art, when a user specifies a table name to be queried from the display / input device 11, the initial processing unit 111 stores column information of the specified table in a file. The data is read from the device 12 via the database management unit 120. Then, the query condition setting processing unit 112 sets a query as a query condition based on the read column information. The query processing unit 113 assembles an SQL (Structured Query Language) statement from the set query and delivers it to the database management unit 120. Further, when the database access result is received from the database management unit 120, it is edited and transmitted to the display / input device 11. To display.
[0004]
Also, Japanese Patent Application Laid-Open No. 2000-187665 discloses a database system that enables an end user who does not have specialized knowledge about a database to freely derive necessary data from the database. In this prior art, a virtual file called a SOVF (Subject Oriented Virtual File) is created in order to allow a general user to easily retrieve data from a complicated relational database such as a DWH (Data Warehouse). A user who does not have knowledge of the above can easily perform data search, and automatically generates an SQL based on key information corresponding to each item set in the SOVF to perform data search.
[0005]
[Patent Document 1]
JP 2002-117041 A [Patent Document 2]
JP 2000-187665 A
[Problems to be solved by the invention]
However, in the data query system disclosed in Japanese Patent Application Laid-Open No. 2002-11741, although a user who does not understand the structure (schema) of the database can easily set search conditions, a plurality of tabular data It is not intended to generate a query when it is adapted to simultaneously search a plurality of tabular data tables in a database such as a DWH composed of tables.
[0007]
The database system disclosed in Japanese Patent Application Laid-Open No. 2000-187665 is capable of performing a data search on a database having a complicated schema. However, it is necessary to construct a relational-aware virtual file while understanding the connection key and the like, which requires a great deal of effort from the administrator.
[0008]
Further, the query generation disclosed in JP-A-2002-11741 or JP-A-2000-187665 is intended for a one-time search, and a stepwise search, for example, narrowing down search results. Cannot be easily performed. It is inconvenient to add the output condition (output item) used for the search result to the search condition again and to set the search condition again from the beginning.
[0009]
In a relational database composed of a plurality of tabular databases, for example, as disclosed in Japanese Patent Application Laid-Open No. 2000-187665, only the connection key information is used for the search condition (WHERE), and the information of the connection key is accidentally obtained. Even if the output condition is satisfied, once the search is completed, it is not left afterward, so that it is not possible to perform a search such as narrowing down or changing the output condition (output item).
[0010]
The present invention has been made in view of the above problems, and has as its object to provide a database search device, a database search method, a program, and a recording medium that can further improve the user's convenience during a search operation. And
[0011]
[Means for Solving the Problems]
In order to achieve such an object, a database search device of the present invention includes a storage unit that stores information related to past data search processing for a database, and uses the information stored in the storage unit to store the information. The search processing for the database is performed again.
[0012]
Further, the database search method of the present invention stores information related to a past data search process for a database in a storage unit, and executes the search process for the database again using the information stored in the storage unit. Features.
[0013]
A program according to the present invention causes a computer to execute the database search method. Furthermore, a computer-readable recording medium according to the present invention is characterized in that the program is recorded.
[0014]
BEST MODE FOR CARRYING OUT THE INVENTION
Hereinafter, preferred embodiments of the present invention will be described in detail with reference to the accompanying drawings. <Configuration of database search system>
FIG. 1 is a diagram schematically showing a configuration of a database search system according to one embodiment of the present invention.
Reference numeral 1 denotes a client PC operated by a user, which can display a Web page transmitted from a server using a Web browser on a screen. Reference numeral 2 denotes a server provided with a free search DB 22 (free search database) in which various data are recorded. The free search / free form application 21 (hereinafter, simply referred to as an application) searches for data in response to a request from the client PC 1. The result can be transmitted to each client PC 1 on a Web page. Reference numeral 3 denotes a system DB server, which can transmit data to be stored in the free search DB 22 to the server 2 sequentially or by batch processing.
[0015]
Each client 1 connected to the server 2 inputs desired search conditions and output data items on the screen, and transmits the input contents to the server 2. The server 2 having received the input content obtains, from the free search DB 22, data matching the search condition among the data listed in the output data item. Next, the server 2 returns the acquired data to the client PC 1 as, for example, CSV (Comma Separated Value) data, and the client PC 1 can check the search result on the screen.
[0016]
In the present embodiment, the data searched as described above can be acquired as a form. In this case, on the client PC 1, the user can specify the output format of the form. When an output format is specified on the client PC 1, the specified information is transmitted from the client PC 1 to the server 2. The server 2 searches the data required for the specified form by the function of the application 21 according to the above search conditions, generates form data, and transmits the form data to the client PC 1. Thus, the user can refer to the form data in a desired search condition and output format.
[0017]
<Main operations of the database search system>
Next, the operation of the database search system according to the present embodiment will be described in detail with reference to FIGS. 2 and 3 are flowcharts showing main operations of the database search system according to the present embodiment.
The user transmits his / her user ID and password from the client PC 1 to the server 2 by operating the client PC 1. The server 2 performs authentication processing of the user based on the user ID and password received from the client PC 1 (step S201), and when authentication is obtained, permits the user to log in to the database search system.
[0018]
Subsequently, the server 2 generates the search condition screen of FIG. 4 and transmits it to the client PC 1 (Step S202). The client PC 1 displays the search condition screen received from the server 2 (Step S102). Next, the user inputs search conditions on the search screen. At the time of input of the search condition, the user selects, for example, “product” (41 in FIG. 4) from “data classification” in the left column of the screen, and then selects the data item “product name” belonging to data classification “product” (42 in FIG. 4) is selected. Then, a small window 43 is displayed on the screen, and the user selects and inputs a search content (here, M-4 small bowl) in the small window 43. Condition designation No. With respect to No. 1, search conditions (data classification “period”, data item “year / month / day”, and search content “from 1996/12/09 to 1996/12/11”) are selected and input by the same input method.
[0019]
The above “commodity” or “period” means the data tables shown in FIGS. 20 and 21, respectively, and “commodity name” or “year / month / day” is a column name in each data table. “M-4 small bowl” and the like selected and input using are data for each column. That is, in FIG. 4, “data classification” is the selected data table, “data item” is a column, and “search content” is the content (data content) to be searched in the column. When the user specifies a data table, the server 2 refers to the table information and creates and provides column names existing in the table as display screen data. When a column name is selected, the data in the column is generated and provided as data for the display screen as shown in the small window 43.
[0020]
Condition designation No. 1, condition designation No. Every time the search condition is determined for each of the two fields, the input content is transmitted from the client PC 1 to the server 2 (step S104), and the server 2 saves the received input content each time (step S204). A new search condition screen reflecting the content is generated and transmitted to the client PC 2 (step S202).
[0021]
Subsequently, when the user presses the "data output" button (44 in FIG. 4) on the screen of FIG. 4 (step S107), information indicating that data output processing has been specified on the client PC1 is displayed on the client PC1. Is transmitted to the server 2 (step S108). The server 2 shifts the processing to step S206 according to the determination branch of step S205. On the other hand, the client PC 1 shifts the processing to step S108.
[0022]
On the server 2 side, in step S206, the output item selection screen of FIG. 5 is generated and transmitted to the client PC1. The client PC 1 receives the output item selection screen from the server 2 and displays it (step S109). The user selects a desired item to be output on the output item selection screen (step S110). The selection procedure is the same as that for inputting the search condition in FIG. In the example of FIG. 5, the output items selected by the user include the data item “year / month / day” of the data category “period”, the data item “product name” of the data category “product”, and the data item “data item” of the data category “product”. The standard selling price, the data item "standard cost" of the data category "product", and the data item "handling start date" of the data category "product".
[0023]
Also here, each time an output item is determined, the input content is transmitted from the client PC 1 to the server 2 (step S111), and the server 2 stores the received input content each time (step S208), and A new search condition screen reflecting the contents is generated and transmitted to the client PC 1 (step S206).
[0024]
When all the desired input items are confirmed, the user presses a “next” button (51 in FIG. 5) on the output item selection screen (step S112). When the “next” button is pressed by the operation of the user, the client PC 1 notifies the server 2 to that effect (step S113). The server 2 that has received the notification generates a display designation screen and transmits it to the client PC 1 (step S210). FIG. 6 shows an example of the display designation screen.
[0025]
Subsequently, the user specifies a display method for each output item on the display specifying screen (Step S115). In the example of FIG. 6, whether or not to list the data for each output item (61 in FIG. 6), the sort order of the data (ascending order, descending order; 62 in FIG. 6), and the priority of the sort process It is possible to specify (63 in FIG. 6). Here, for example, each time the display designation content of each item is determined, the input content is transmitted from the client PC 1 to the server 2 (step S116), and the server 2 saves the received input content each time (step S116). In step S212, a new search condition screen reflecting the input contents is generated and transmitted to the client PC 1 (step S210).
[0026]
Subsequently, when the user presses a "search" button (64 in FIG. 6) on the screen of FIG. 6 (step S117), information indicating that the user has input a search designation is transmitted from the client PC1 to the server. 2 (step S118). In the server 2, after the processing of step S214 via the determination branch of step S213, the processing is shifted to step S214. On the other hand, the client PC 1 shifts the processing to step S119. The query generation processing in step S214 will be described later.
[0027]
Subsequently, the application 21 receives the search result from the free search DB 22, and the server 2 transmits a search result list screen to the client PC 1 (Step S215). The client PC 1 receives the search result list screen from the server 2 and displays it (step S119). FIG. 7 shows an example of the search result list screen. In the list display specification check box in FIG. 6, all the items of the output items are checked, so that all the items are displayed in the display result.
[0028]
On the search result list screen of FIG. 7, further narrowing search of output data can be performed. When the output data is selected on the search result list screen of FIG. 7 (71 in FIG. 7) by the user's operation input (step S120), the input content is transmitted from the client PC 1 to the server 2 (step S121). ). The server 2 saves the received input content each time (step S217), generates a new search result list screen reflecting the input content, and transmits it to the client PC 1 (step S215).
[0029]
Subsequently, when the user presses a “data output” button (72 in FIG. 7) on the screen in FIG. 7 (step S122), the client PC 1 instructs the server 2 to output data from the user. Is transmitted (step S123). In the server 2, the application 21 generates a query based on the stored output data selection information and transmits it to the free search DB 22 through the determination branch of step S218 (step S219).
[0030]
Subsequently, when the application 21 receives the search result returned from the free search DB 22 in response to the query, the server 2 transmits search hit number information to the client PC 1 (step S220). The client PC 1 displays the search hit number information received from the server 2 on the screen (Step S125). FIG. 8 shows an example of the search hit number display screen. After checking the number of search hits displayed on the screen of the client PC 1 and wishing to receive the searched data as a CSV file, the user clicks the “execute” button (81 in FIG. 8) on the screen of FIG. ) Is pressed (step S126).
[0031]
When the "execute" button is pressed, information indicating that is transmitted from the client PC 1 to the server 2 (step S127). When the server 2 receives the information requesting the CSV file, the server 2 transmits the information to the client PC 1. In response, a CSV file is returned (step S222). Thereby, the user can browse the search result by the narrowed search in the CSV file.
[0032]
On the other hand, when the "form output" button (73 in FIG. 7) is pressed on the search result list screen in FIG. 7 (step S124), the client PC 1 determines that the user has specified the form output and the server 2 and the server 2 shifts the processing to step S223 by the decision branch of step S218.
[0033]
Subsequently, the server 2 transmits, for example, the form list screen shown in FIG. 9 to the client PC 1 (Step S223). The client PC 1 receives and displays the form list screen from the server 2 (Step S130). The user refers to the form list screen displayed on the client PC 1 and selects a form in a desired format. Next, the client PC 1 transmits the form selection information to the server 2 (Step S131).
[0034]
Subsequently, when the server 2 receives the form selection information from the client PC 1 (step S224), the application 21 generates a query corresponding to the form selection information and transmits it to the free search DB 22 (step S225). This query-generation will be described later. Next, when the application 21 receives the search result returned from the free search DB 22, the server 2 counts the number of search hits and transmits the result to the client PC 1 as search hit number information (step S226).
[0035]
The client PC 1 displays the search hit number information received from the server 2 (step S132). FIG. 10 shows a display example of the search hit number information. When the user wants to output the form, after confirming the search hit number information displayed on the client PC, the user presses the “execute” button (101 in FIG. 10) on the screen in FIG. 10 (step S133). . When the “execute” button is pressed, the client PC 1 notifies the server 2 that the form output execution has been specified (step S134).
[0036]
The server 2 that has received the specification of the form output execution internally transmits the search result to the form creation program (step S227), and receives the PDF data of the form from the form creation program (step S228). Then, the server 2 transmits a form screen in which the PDF data of the form and the search result data obtained from the free search DB 22 are combined to the client PC 1 (step S229). In this combination, the combining position of each column data of the form data storage table shown in FIG. 19 is determined in advance and pasted with text data or the like to the PDF data of each form, and KEY_CLM_ID in the form information storage table shown in FIG. Each sheet is synthesized as one form. The client PC 1 displays the form screen of FIG. 11 received from the server 2 (step S135). FIG. 11 illustrates a case where “store sales table by product” is selected on the form list screen of FIG. 9, and the refined search on the search result list screen of FIG. 7 is reflected. That is, in FIG. 7, the item of the date “1996/12/10” and the product name “M-4 small bowl” and the date “1996/12/11” and the product name “M-4 small bowl” are displayed. Is selected on the form screen of FIG. 11, information corresponding to them is described.
[0037]
<Search query generation (first search)>
Next, a search query generation method according to an embodiment of the present invention will be described. FIG. 12 is a flowchart showing the flow of the search query generation method according to one embodiment of the present invention, and shows the search query generation executed in step S214 of FIG. 12 and 13, a search condition storage unit 121, a display item specification storage unit 122, a relation information storage table 123, a form specification storage unit 131, a search result storage unit 132, a form information storage table 133, and a form data storage. The table 134 and the relation information storage table 135 are stored in an internal recording medium such as a RAM in the server 2.
[0038]
First, the server 2 acquires the search condition stored in step S204 of FIG. 2 from the search condition storage unit 121 (step S301). Here, the obtained search condition is used for generating a WHERE phrase of a search query described later. The search condition storage unit 121 stores a table ID corresponding to the data classification, a column ID corresponding to the data item, and a search content specified on the screen of FIG.
[0039]
In the example of FIG. In 1, the data classification “period”, the data item “year / month / day”, and the search content “from 1996/12/09 to 1996/12/11” are specified. Here, referring to the table information storage table shown in FIG. 14, the table ID corresponding to the data classification “period” is “term”. Referring to the column information storage table shown in FIG. 15, the column ID corresponding to the data item “year / month / day” is “year / month / day”. Therefore, the condition designation No. In the case of No. 1, the search condition storage unit 121 stores a table ID “term”, a column ID “year / month / day”, and a search content “1996/12/09 to 1996/12/11 (BETWEEN timestamps 1996-12-0900: 00: 00.000000 {AND timestamp {1996-12-11 23: 59: 59.9999999}) ”is stored. Similarly, condition designation No. For 2, the table ID “goods”, the column ID “product name”, and the search content “M-4 small bowl” are stored in the search condition storage unit 121.
[0040]
Next, the server 2 acquires display item designation information from the display item designation storage unit 121 (Step S302). The display item specification storage unit 122 stores output item data input on the screen of FIG. 5 and display specification data input on the screen of FIG. 6 and stored in S212. In the example of FIG. 5, as the output item data, the data item “year / month / day” of the data classification “period”, the data item “product name” of the data classification “product”, and the data item “standard selling price” of the data classification “product” The data item “standard cost” of the data category “product” and the data item “transaction start date” of the data category “product” are selected.
[0041]
In the example of FIG. 6, the data item "product name" of the data category "product" has the sort priority "1" and the sort order is specified as "ascending order", and the data item "transaction start date" of the data category "product". , The sort priority is designated as “2”, and the sort order is designated as “ascending order”.
[0042]
Therefore, the display item designation storage unit 122 stores the table ID “term” and the column ID “year / month / day”, the table ID “goods”, the column ID “product name”, the sort priority “1”, and the sort order “ascending ( ASC) ", table ID" goods "and column ID" standard selling price ", table ID" goods "and column ID" standard cost ", table ID" goods ", column ID" transaction start date ", sort priority" 2 " And the sort order “ascending order (ASC)” are stored in association with each other. The server 2 acquires the display item specification information from the display item specification storage unit 122.
[0043]
Subsequently, the server 2 acquires relation information from the relation information storage table 123 (Step S303). As shown in FIG. 16, the relation information storage table 123 includes “term”, “store”, “goods”, which are dimension tables in the star schema database according to the present embodiment, and “sls_dsgoods”, which is a main table. The relation information of is stored.
FIG. 17 shows a relational relationship of the star schema type relational database applied to the present embodiment.
[0044]
Further, tables “goods”, “term”, “stores”, and “sls_dsgoods” applicable to the present embodiment are shown in FIGS. 20, 21, 22, and 23, respectively. The table “goods” illustrated in FIG. 20 includes columns “target date”, “store code”, “product code”, “sales code”, and the like. The table “term” includes columns “year / month / day”, “year”, “month”, “day”, and the like. The table “stores” includes columns “store code”, “store name”, “scale code”, and the like. The table “sls_dsgoods” includes columns “target date”, “store code”, “product code”, “sales points”, and the like.
[0045]
Here, search items and output items are selected from the tables “term” and “goods” on the screens of FIGS. 4 and 5. Therefore, the server 2 acquires the relation information related to the tables “term” and “goods” from the relation information storage table 123. That is, the relation information acquired here includes the relation information in which the column “year / month / day” of the table “term” is associated with the column “target date” of the table “sls_dsgoods”, and the column “column of the table“ goods ”. This is relation information that associates a “product code” with a column “product code” in a table “sls_dsgoods”.
[0046]
Subsequently, in step S304, based on the relation information acquired in step S303, the server 2 generates a table relation unit that defines association between tables in a WHERE clause of the query.
Specifically, “term.date = sls_dsgoods.target date AND goods.product code = sls_dsgoods.product code” is generated as a table relation unit.
[0047]
Subsequently, the server 2 generates a WHERE clause (search condition) of the query based on the search condition acquired in step S301 and the table relation unit generated in step S304.
[0048]
Subsequently, the server generates a SELECT clause of the query based on the display item information acquired in step S302. Here, data matching the search conditions among the data belonging to the columns “year / month / day”, “product name”, “standard selling price”, “standard cost”, and “transaction start date” are stored in the tables “term”, “goods”. , "Sls_dsgoods" is required by this SELECT clause, and the columns "year / month / day" and "product code" which are the connection keys of the table "term" and "goods" selected as display items are respectively set to " It is requested by the SELEDT phrase to read back and return as "Clm_0", "Clm_1".
[0049]
Subsequently, the server 2 generates an ORDER clause of the query based on the sort priority and the sort order in the display item information acquired in step S302. That is, the data in the column "product name" of the table "goods" is sorted in the ascending order with the highest priority, and the data in the column "transaction start date" in the table "goods" is sorted in the ascending order with the next highest priority. Stipulated.
[0050]
The following SQL (Structured Query Language) statement is generated by generating the above-described query.
"SELECT DISTINCT term.date, goods.product name, goods.standard selling price, goods.standard cost, goods.transaction start date, term.date ascngClm_0, goods.product code as cngClm_1
FROM term, goods, sls_dsgoods
WHERE (term. Date = sls_dsgoods. Target date AND goods. Product code = sls_dsgoods. Product code)
AND ((term. Date BETWEEN timestamp {1996-12-09 00: 00: 00: 000000000} AND timestamp {1996-12-11 23: 59: 59.000000})
AND (goods. Trade name LIKE {% M-4 small bowl%})
ORDER BY goods. Trade name ASC, goods. Trading Start Date ASC "
[0051]
<Search query generation (at the time of refined search)>
Next, a method of generating a query in the form mode in step S225 of FIG. 3 will be described. FIG. 13 is a flowchart showing the flow of the form mode query generation method according to the present embodiment.
First, the server 2 receives the form ID received in step S224 and corresponding to the merchandise store sales table stored in the form specification storage unit 131 (step S401). Subsequently, the server 2 acquires a key column search result from the search result storage unit 132 (Step S402). The key column search result is the data of the concatenated key returned from the DB as “Clm — 0” and “Clm — 1” in step S215. Fetch key column information related to data. For example, "term. Date = timestamp '1996-12-10 23: 59: 59.999999'" or "goods. Product code = '4973307404511'" corresponds to this.
[0052]
Next, the server 2 acquires the form data information from the form information storage table 133 (Step S403). As shown in FIG. 18, the form information storage table stores form ID “REPORT_ID”, main table ID “MAIN_TBL_ID”, key column ID “KEY_CLM_ID”, overlay form name “FORM_NM”, and the like. The server 2 acquires form data information corresponding to the form ID acquired in step S401 from the form information storage table. That is, since the form ID acquired in step S401 is “803”, in the example of FIG. 18, the form ID “803”, the main table ID “goods”, the key column ID “product code”, and the overlay form name “rs_sURIAGE3. fcp "is acquired as the form data information.
[0053]
Next, the server 2 acquires form configuration item information from the form data storage table (step S404). As shown in FIG. 19, the form data storage table stores a form ID “REPORT_ID”, a table ID “TBL_ID”, a column ID “CLM_ID”, a data generation order “SORT_ORDER”, and the like. The server 2 acquires the form configuration item information corresponding to the form ID acquired in step S401 from the form data storage table. That is, the form ID acquired in step S401 is “803”, and all records in the form data storage table shown in FIG. 19 are read.
[0054]
Subsequently, the server 2 acquires relation information from the relation information storage table of FIG. 16 (Step S405). As shown in FIG. 19, the relation information acquired here includes “goods”, “store”, and “term” as tables of output items to be output as a form. Relation information is obtained. That is, table ID (TBL_ID) “term”, column ID (CLM_ID) “year / month / day”, relation table ID (CNG_ID) “sls_dsgoods”, and relation column ID (CNGCLM_ID) “target date” as the first relation information. Is obtained. As the second relation information, a table ID (TBL_ID) “store”, a column ID (CLM_ID) “store code”, a relation table ID (CNG_ID) “sls_dsgoods”, and a relation column ID (CNGCLM_ID) “store code” are acquired. . As the third relation information, a table ID (TBL_ID) “goods”, a column ID (CLM_ID) “product code”, a relation table ID (CNG_ID) “sls_dsgoods”, and a relation column ID (CNGCLM_ID) “product code” are acquired Is done.
Here, although not described in the flowchart in order to avoid repetition, the retrieval condition acquisition performed in step S301 of FIG. 12 is executed before the execution of step S406.
[0055]
Subsequently, the server 2 generates a table relation unit from the relation information acquired in Step S405 (Step S406). Here, as an indication that the tables “goods”, “store”, and “term” are linked to the table “sls_dsgoods” by their respective concatenated keys, “term.date = sls_dsgoods.target-date AND-goods .Commodity code = sls_dsgoods.commodity code AND store.store code = sls_dsgoods.store code ”is generated as a table relation unit.
[0056]
Subsequently, the server 2 generates a WHERE phrase indicating a search condition (step S407). Here, in addition to the search condition stored in the search condition storage unit in step S204 of FIG. 2 and the table relation unit generated in step S406, search result key information (link key) acquired from the search result storage unit in step S402 Here, "timestamp @ 1996-12-10 23: 59: 59.99999" for the first output item "year / month / date: 1996/12/10, trade name: M-4 small bowl" selected in step S120. $ "And" 497307404511 ", and" timestamp $ 1996-12- "for the second output item" year / month: December 11, 1996, trade name: M-4 Kobachi "also selected in step S120. 11 23: 59: 59.999999 ` ”,“ 4 The WHERE phrase is generated based on the data of 973307404111 ".
[0057]
Subsequently, the server 2 generates a SELECT phrase indicating a display item. Here, the columns “product code”, “product name”, “scale name”, “store code”, “store name”, “year” based on the form configuration item information acquired from the form data storage table 134 in step S404. “Date”, “Standard selling price”, “Standard cost”, “Sales points”, and “Sales price” are obtained as display items from the tables “term”, “goods”, “store”, and “sls_dsgoods” and displayed. Is specified in the SELECT clause.
[0058]
Subsequently, the server 2 generates an ORDER phrase indicating the sort order. Here, based on the form configuration item information “SORT_ORDER” and “AD_CLASS” acquired in step S404, the priority order of the column “product code” of the table “goods” and the column “store code” of the table “store” are respectively set. Are sorted in ascending order.
[0059]
The query generated in this way is as follows.
“SELECT DISTINCT goods. Product code, goods. Product name, store. Scale name, store. Store code, store. Store name, term. Date, goods. Sales price FROM term, goods, store, sls_dsgoods
WHERE ((term. Date BETWEEN timestamps 1996-12-09 00: 00: 00: 0.000000 {AND (goods. Brand name LIKE {% M-4 small bowl%}))
AND ((term. Date = timestamp {1996-12-10 23: 59: 59.9999999} AND goods. Product code = {497330740511})
OR (term. Date = timestamp {1996-12-11 23: 59: 59.9999999})
AND goods. Product code = {497307404511})
AND (term.date = sls.ds_goods.Product code AND goods.Product code = sls_dsgoods.Product code AND store.Store code = sls_dsgoods.Store code ORDER BYgoods.A.S.A code.
[0060]
As described above, in the query generated by the refined search, the search result for the link key of the table including the previous output item is reflected as a new search condition (term. Date = timestampt1996−). 12-10 23: 59: 59.9999999 {AND goods. Product code = {497330740511}) OR (term. Date = timestamp {1996-12-11 23: 59: 59.99999999}). For example, in the previous (first) search, "product code" is not specified as an output item or a display item, but is included in the SELECT clause as a data output condition to the free search DB 22. Is made possible by storing. In other words, in step S215, the link key is obtained and stored from the free DB 22 separately from the data output items and the display items as "Clm_0" and "Clm_1", thereby preparing for the subsequent search query generation. Further, in the query-generation in step 204 described in detail with reference to FIG.
“SELECT DISTINCT term.date, goods.brand name, goods.standard selling price, goods.standard cost, goods.transaction start date FROM term, goods, sls_dsgoods
WHERE (term. Date = sls_dsgoods. Target date AND goods. Product code = sls_dsgoods. Product code)
AND ((term. Date BETWEEN timestamp {1996-12-09 00: 00: 00: 000000000} AND timestamp {1996-12-11 23: 59: 59.000000})
AND (goods. Trade name LIKE {% M-4 small bowl%})
ORDER BY goods. Trade name ASC, goods. Trading Start Date ASC "
It is possible to create the display of the search result shown in FIG. According to the related art, an SQL sentence is generated in this way. However, according to the present invention, in order to perform a further refined search on a database having a schema that is complicatedly linked by a link key, and to enable the data to be combined into various forms having various output items, the search results are described above. The following query-generation is performed.
[0061]
As a result, it is possible to execute a refined search by inputting only new refined conditions, without having to look at the previous output items at the time of the refined search and reflecting it in the search conditions again to perform a re-search. And the search operation becomes easy for the user. Similarly, the search result for the link key is reflected in the new search condition, so that the output item in the table including the previous output item can be easily changed without reflecting the previous output item. Become. Further, a user having no knowledge of the database can easily perform a search with a high degree of freedom on a database of a complex schema having a plurality of tabular data tables.
[0062]
That is, even in the search of a database having a complicated schema, not only the selection of “data output” in FIG. 7 but also the flexibility of giving the user the flexibility to cope with a change in the data output item such as “form output” can be given. The degree of freedom is incomparable with that of the related art in which the output form can be specified only before the execution of the search or can be performed only in a predetermined manner.
[0063]
Note that it is determined in steps S216 and S217 whether all data has been selected in the data output selection (step S121) of FIG. 7 at the time of generating a query in the second search. If all data is to be output, it takes time to generate a query and interpret the query in the free search DB 22. Therefore, for all data, (term. Date = timestamp @ 1996-12) -10 23: 59: 59.99999999 {AND goods. Product code = {497330704511}) OR (term.date = timestamp {1996-12-11 23: 59: 59.99999999}) is not created. In addition, in the processing in step S407, it is possible to perform an efficient search by ignoring the output data selection condition saved in step S217 and generating a query.
[0064]
Although a specific description of a search query generation method at the time of a narrowed search for a CSV file has been omitted, a search query is generated by the same processing as that at the time of form creation, and the same effect as described above can be obtained. It is.
[0065]
FIG. 24 is a diagram illustrating a hardware configuration of the server 2 in the present embodiment.
The CPU 201 generally controls each device connected to the system bus 204. In the ROM 203 or the external memory 211, an operating system program (hereinafter, referred to as an OS), which is a control program of the CPU 201, and various programs to be described later necessary for realizing the functions executed by each server or each PC are provided. It is remembered. The RAM 202 functions as a main memory, a work area, and the like for the CPU 201.
[0066]
A keyboard controller (KBC) 205 controls key input from a keyboard 209 or a pointing device (not shown). A CRT controller (CRTC) 206 controls display on a CRT display (CRT) 210. These are used by the administrator as needed. It is not directly related to the present invention.
[0067]
An external memory controller (MC) 207 includes a boot program, browser software, various applications, font data, a user file, an edit file, a database management system (DBMS), a hard disk (HD) for storing various data, and a flexible disk (FD). ) Or controls access to an external memory 211 such as a compact flash (R) memory connected to a PCMCIA card slot via an adapter.
[0068]
The communication I / F controller 208 connects to an external device via a network, and executes communication control processing on the network. For example, Internet communication using TCP / IP is possible. Note that the CPU 201 enables the display on the CRT 210 by executing, for example, an outline font developing (rasterizing) process on a display information area in the RAM 202. Further, the CPU 201 enables a user instruction with a mouse cursor (not shown) on the CRT 210. The programs related to the respective processes described in the above-described operation flowchart and the free search DB 22 are stored in the external memory 211, and various programs are read out to the RAM 202 as necessary and executed by the CPU 201.
[0069]
Further, an object of the present invention is to provide a storage medium storing a program code of software for realizing the functions of the above-described embodiments to a system or an apparatus, and a computer (or CPU or MPU) of the system or the apparatus to store the storage medium. Needless to say, this can also be achieved by reading and executing the program code stored in the program.
[0070]
In this case, the program code itself read from the storage medium realizes the function of the above-described embodiment, and the program code itself and the storage medium storing the program code constitute the present invention.
[0071]
As a storage medium for supplying the program code, for example, a flexible disk, a hard disk, an optical disk, a magneto-optical disk, a CD-ROM, a CD-R, a magnetic tape, a nonvolatile memory card, a ROM, and the like can be used.
[0072]
When the computer executes the readout program code, not only the functions of the above-described embodiments are realized, but also the OS or the like running on the computer performs actual processing based on the instructions of the program code. It goes without saying that a case where some or all of the functions are performed and the functions of the above-described embodiments are realized by the processing is also included.
[0073]
Further, after the program code read from the storage medium is written into a memory provided in a function expansion board inserted into the computer or a function expansion unit connected to the computer, the function is executed based on the instruction of the program code. It goes without saying that a CPU or the like provided in the expansion board or the function expansion unit performs part or all of the actual processing, and the processing realizes the functions of the above-described embodiments.
[0074]
【The invention's effect】
According to the present invention, the search processing for the database is configured to be re-executable using the information related to the past data search processing for the database. When performing the necessary search processing, the user is prevented from having to refer to a previously searched screen in order to re-enter information relating to the past search processing, and the user's convenience at the time of the search operation is reduced. Can be improved.
[Brief description of the drawings]
FIG. 1 is a diagram schematically showing a configuration of a database search system according to an embodiment of the present invention.
FIG. 2 is a flowchart showing main operations of a database search system according to one embodiment of the present invention.
FIG. 3 is a flowchart showing main operations of the database search system according to one embodiment of the present invention.
FIG. 4 is a diagram showing an example of a search condition screen.
FIG. 5 is a diagram showing an example of an output item selection screen.
FIG. 6 is a diagram showing an example of a display designation screen.
FIG. 7 is a diagram showing an example of a search result list screen.
FIG. 8 is a diagram showing an example of a search hit number display screen.
FIG. 9 is a diagram showing an example of a form list screen.
FIG. 10 is a diagram showing an example of a search hit number display screen.
FIG. 11 is a diagram showing an example of a form screen.
FIG. 12 is a flowchart illustrating a flow of a search query generation method according to an embodiment of the present invention.
FIG. 13 is a flowchart illustrating a flow of a search query generation method according to an embodiment of the present invention.
FIG. 14 is a diagram showing a configuration example of a table information storage table.
FIG. 15 is a diagram illustrating a configuration example of a column information storage table.
FIG. 16 is a diagram illustrating a configuration example of a relation information storage table.
FIG. 17 is a diagram showing a relational relationship of a star schema type relational database applied to an embodiment of the present invention.
FIG. 18 is a diagram showing a configuration example of a form information storage table.
FIG. 19 is a diagram showing a configuration example of a form data storage table.
FIG. 20 is a diagram illustrating a configuration example of a table “goods”.
FIG. 21 is a diagram illustrating a configuration example of a table “term”.
FIG. 22 is a diagram illustrating a configuration example of a table “stores”.
FIG. 23 is a diagram illustrating a configuration example of a table “sls_dsgoods”.
FIG. 24 is a diagram illustrating a hardware configuration of a server according to an embodiment of the present invention.
[Explanation of symbols]
1: Client PC
2: Server 3: System DB server 21: Free search / free form application 22: Free search DB
121: search condition storage unit 122: display item specification storage unit 123: relation information storage table 131: form specification storage unit 132: search result storage unit 133: form information storage table 134: form data storage table 135: relation information storage table

Claims (10)

データベースに対する過去のデータ検索処理に係る情報を格納する格納手段を有し、
前記格納手段に格納される前記情報を用いて、前記データベースに対する検索処理を再度実行することを特徴とするデータベース検索装置。
Having storage means for storing information relating to past data search processing for the database,
A database search apparatus, wherein a search process for the database is performed again using the information stored in the storage unit.
前記データベースは、複数のデータテーブルによって構成されるリレーショナルデータベースであることを特徴とする請求項1に記載のデータベース検索装置。The database search device according to claim 1, wherein the database is a relational database including a plurality of data tables. 前記過去のデータ検索処理に係る情報は、そのデータ検索処理の検索対象となったデータテーブルの連結キーに該当するカラムの前記データ検索処理時における検索結果であることを特徴とする請求項2に記載のデータベース検索装置。The information according to the past data search process is a search result at the time of the data search process of a column corresponding to a concatenated key of a data table that is a search target of the data search process. A database search device as described. 更に、ユーザからの検索条件及びデータ出力項目となるカラム指示を受け付ける指示受信手段を有し、
前記データ検索処理に係わる情報は、前記過去のデータ検索処理の際に前記指示受信手段で受信したデータ出力項目のカラムとは別に取得されたカラム内の情報であることを特徴とする請求項1〜3の何れか1項に記載のデータベース検索装置。
Furthermore, it has an instruction receiving means for receiving a column instruction as a search condition and a data output item from the user,
2. The information related to the data search process is information in a column obtained separately from a column of a data output item received by the instruction receiving unit in the past data search process. The database search device according to any one of claims 1 to 3.
前記データ検索処理に係る情報を、検索クエリーの一部に適用して前記データベースに対する検索処理を実行することを特徴とする請求項1又は3に記載のデータベース検索装置。4. The database search device according to claim 1, wherein a search process is performed on the database by applying information related to the data search process to a part of a search query. 5. 前記過去のデータベースの検索処理はデータの絞込みのための検索であって、前記過去のデータベース検索処理の検索結果に関する全てのデータが次回の検索対象とされた場合には前記データ検索処理に係わる情報をクエリ−生成に適用しないことを特徴とする請求項5に記載のデータベース検索装置。The past database search process is a search for narrowing down data, and if all data relating to the search results of the past database search process is to be the next search target, information related to the data search process The database search device according to claim 5, wherein? Is not applied to query-generation. 前記リレーショナルデータベースは、スタースキーマ型リレーショナルデータベースであることを特徴とする請求項2〜6の何れか1項に記載のデータベース検索装置。The database search device according to any one of claims 2 to 6, wherein the relational database is a star schema type relational database. データベースに対する過去のデータ検索処理に係る情報を格納手段に格納し、前記格納手段に格納される前記情報を用いて前記データベースに対する検索処理を再度実行することを特徴とするデータベース検索方法。A database search method, wherein information relating to a past data search process for a database is stored in a storage unit, and a search process for the database is executed again using the information stored in the storage unit. 請求項8に記載のデータベース検索方法をコンピュータに実行させるためのプログラム。A program for causing a computer to execute the database search method according to claim 8. 請求項9に記載のプログラムを記録したコンピュータ読み取り可能な記録媒体。A computer-readable recording medium on which the program according to claim 9 is recorded.
JP2002382470A 2002-12-27 2002-12-27 Database search apparatus, database search method, program, and computer-readable recording medium Expired - Fee Related JP4109988B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2002382470A JP4109988B2 (en) 2002-12-27 2002-12-27 Database search apparatus, database search method, program, and computer-readable recording medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2002382470A JP4109988B2 (en) 2002-12-27 2002-12-27 Database search apparatus, database search method, program, and computer-readable recording medium

Publications (2)

Publication Number Publication Date
JP2004213348A true JP2004213348A (en) 2004-07-29
JP4109988B2 JP4109988B2 (en) 2008-07-02

Family

ID=32818017

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2002382470A Expired - Fee Related JP4109988B2 (en) 2002-12-27 2002-12-27 Database search apparatus, database search method, program, and computer-readable recording medium

Country Status (1)

Country Link
JP (1) JP4109988B2 (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2006127123A (en) * 2004-10-28 2006-05-18 Mitsubishi Electric Corp Application server, database server, web retrieval system, retrieval result acquisition method, retrieval result response method, retrieval result acquisition program and retrieval result response program
JP2009245283A (en) * 2008-03-31 2009-10-22 Japan Research Institute Ltd Data retrieval system, data retrieval method, and program
JP2009245282A (en) * 2008-03-31 2009-10-22 Japan Research Institute Ltd Data retrieval system, data retrieval method, and program

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2006127123A (en) * 2004-10-28 2006-05-18 Mitsubishi Electric Corp Application server, database server, web retrieval system, retrieval result acquisition method, retrieval result response method, retrieval result acquisition program and retrieval result response program
JP2009245283A (en) * 2008-03-31 2009-10-22 Japan Research Institute Ltd Data retrieval system, data retrieval method, and program
JP2009245282A (en) * 2008-03-31 2009-10-22 Japan Research Institute Ltd Data retrieval system, data retrieval method, and program

Also Published As

Publication number Publication date
JP4109988B2 (en) 2008-07-02

Similar Documents

Publication Publication Date Title
US7844587B2 (en) Web-based user interface for searching metadata-driven relational databases
US7401064B1 (en) Method and apparatus for obtaining metadata from multiple information sources within an organization in real time
US6480842B1 (en) Dimension to domain server
US8122009B2 (en) Dealing with composite data through data model entities
US6848077B1 (en) Dynamically creating hyperlinks to other web documents in received world wide web documents based on text terms in the received document defined as of interest to user
US8140563B2 (en) Searching in a computer network
TW591440B (en) Global query correlation attributes
US7840601B2 (en) Editable table modification
US7203675B1 (en) Methods, systems and data structures to construct, submit, and process multi-attributal searches
AU735010B3 (en) Business intelligence system
US20020107718A1 (en) &#34;Host vendor driven multi-vendor search system for dynamic market preference tracking&#34;
US20080249992A1 (en) Cross-language searching
US7158969B2 (en) Iterative data analysis process via query result augmentation and result data feedback
US20020026441A1 (en) System and method for integrating multiple applications
US20030101238A1 (en) Web-based collaborative data collection system
US20090299965A1 (en) Navigating product relationships within a search system
US7373350B1 (en) Virtual metadata analytics and management platform
US20070239666A1 (en) Method and System for a De-Normalized Electronic-Catalog
JPH10269237A (en) Document browsing system
US20050138022A1 (en) Parametric searching
US7085760B2 (en) Data query differential analysis
US20110078569A1 (en) Value help user interface system and method
US20060004708A1 (en) Predefined search queries for a search engine
JP2004213347A (en) Database retrieval query generating method, database retrieval method, database retrieval device, program and recording medium
US6934701B1 (en) Using a stored procedure to access index configuration data in a remote database management system

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20041222

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20071211

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20080212

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

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20080311

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20080407

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20110411

Year of fee payment: 3

R150 Certificate of patent or registration of utility model

Ref document number: 4109988

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

Free format text: JAPANESE INTERMEDIATE CODE: R150

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20110411

Year of fee payment: 3

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20120411

Year of fee payment: 4

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20120411

Year of fee payment: 4

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20130411

Year of fee payment: 5

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20140411

Year of fee payment: 6

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

LAPS Cancellation because of no payment of annual fees