JP2014081905A - Device for providing graphical interface for assisting preparation of logic formula - Google Patents

Device for providing graphical interface for assisting preparation of logic formula Download PDF

Info

Publication number
JP2014081905A
JP2014081905A JP2012243132A JP2012243132A JP2014081905A JP 2014081905 A JP2014081905 A JP 2014081905A JP 2012243132 A JP2012243132 A JP 2012243132A JP 2012243132 A JP2012243132 A JP 2012243132A JP 2014081905 A JP2014081905 A JP 2014081905A
Authority
JP
Japan
Prior art keywords
expression
tree
character string
logical
subexpression
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
JP2012243132A
Other languages
Japanese (ja)
Inventor
Kentaro Hoshino
健太郎 星野
Kosuke Nakamura
浩介 中村
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.)
GREEN IT SYSTEMS Inc
Original Assignee
GREEN IT SYSTEMS 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 GREEN IT SYSTEMS Inc filed Critical GREEN IT SYSTEMS Inc
Priority to JP2012243132A priority Critical patent/JP2014081905A/en
Publication of JP2014081905A publication Critical patent/JP2014081905A/en
Pending legal-status Critical Current

Links

Images

Landscapes

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

Abstract

PROBLEM TO BE SOLVED: To facilitate the preparation of a logic formula for retrieving data.SOLUTION: The device has: terms; means for storing a logic character string consisting of the combination of subexpression character strings in which the terms are combined by the logic operator; means for dividing the logic character string into the terms or dividing the terms as a subexpression tree consisting of the recursive structure of the subexpression tree in which the terms are combined by the logic operator; and number-of-cases storage means for storing the number of cases retrieved by the subexpression character string. Further, the device has display means for displaying the subexpression character string and the subexpression tree accompanied with the stored number of cases in the number-of-cases storage means, and includes means for selecting whether the subexpression tree is not displayed with the subexpression character string left as it is or whether the subexpression tree is displayed together with the subexpression character string. The user of the device can easily grasp the hierarchic structure of the logic formula, and can recognize the number of cases, and can edit the subexpression character string and the subexpression tree displayed by the display means. The device further includes means for retaining the input subexpression character string as a hysteresis.

Description

この発明はデータを検索するための論理式の作成を補助するグラフィカルインターフェースを提供する装置に関わる。  The present invention relates to an apparatus for providing a graphical interface that assists in creating a logical expression for retrieving data.

近年、インターネット上の情報はもとより、社内や組織内で保持する情報から、必要な情報を見つけるために、キーワードを指定して、キーワードに該当する情報を検索する方法を採ることが多い。  In recent years, in order to find necessary information from information held in the company or organization as well as information on the Internet, a method of specifying a keyword and searching for information corresponding to the keyword is often employed.

しかしながら、保持される情報はますます増え、希望する情報を見つける事は、情報の量に比例して難しくなってきている。  However, more and more information is held, and finding desired information has become difficult in proportion to the amount of information.

このような大量の情報から希望する情報を出来る限り特定できるように、単純なキーワードによる検索だけではなく、キーワードを含めた論理式を記述出来る事が一般的である。利用者は、キーワードをAND条件でつなぐ事で情報を絞り込んだり、OR条件でつなぐ事で該当する範囲を広めたりしながら希望する情報を探して行く。  In general, not only simple keyword searches but also logical expressions including keywords can be described so that desired information can be specified as much as possible from such a large amount of information. The user searches for desired information while narrowing down information by connecting keywords with an AND condition or expanding a corresponding range by connecting with an OR condition.

特開2012−78966号公報JP 2012-78966 A

検索のキーワードに論理式を記述する方法では、論理式が複雑になるとAND条件やOR条件の結合の範囲や論理式の階層関係を把握することが困難であるという課題があった。同様の理由から論理式の修正が困難であるという課題があった。  In the method of describing a logical expression as a search keyword, there is a problem that when the logical expression becomes complicated, it is difficult to grasp the range of combination of AND conditions and OR conditions and the hierarchical relation of logical expressions. For the same reason, there is a problem that it is difficult to correct the logical expression.

また、情報を絞り込んだり、該当する範囲を広めたりする場合に、該当件数は一つの判断材料となるが、該当件数を求めるためには、実際に検索を行う必要があった。実際に検索を行ったとしても、論理式全体の該当件数しかわからず、論理式を構成する一部の論理式について、該当件数を求めることはできなかった。  In addition, when narrowing down information or expanding the applicable range, the number of hits can be used as a judgment material, but in order to find the number of hits, it was necessary to actually perform a search. Even if the search is actually performed, only the number of cases corresponding to the entire logical expression is known, and the number of cases cannot be obtained for some of the logical expressions constituting the logical expression.

本発明は、データベースと、項と、項を論理演算子で組み合わせた部分式文字列の組み合わせからなる論理式文字列を記憶する手段と、前記論理式文字列を項、または、項を論理演算子で組み合わせた部分式ツリーの再帰構造からなる部分式ツリーとして分割する手段を持つ。  The present invention provides a means for storing a logical expression character string composed of a combination of a database, a term, and a partial expression character string obtained by combining terms with a logical operator; It has a means to divide as a subexpression tree consisting of a recursive structure of subexpression trees combined with children.

前記部分式文字列を前記データベースにて検索した際の件数を記憶する件数記憶手段と、前記部分式文字列、または、部分式ツリー、または、部分式文字列および部分式ツリーの両方を、前記件数記憶手段に記憶された件数を伴って表示する表示手段を持つ。  The number storage means for storing the number of cases when the partial expression character string is searched in the database, the partial expression character string, or the partial expression tree, or both the partial expression character string and the partial expression tree, Display means for displaying the number of cases stored in the number storage means.

前記表示手段は、利用者の操作により部分式文字列を残し部分式ツリーを非表示とするか、部分式文字列とともに部分式ツリーを表示するかを選択する手段を備える。  The display means includes means for selecting whether to leave the partial expression character string by the user's operation and hide the partial expression tree, or to display the partial expression tree together with the partial expression character string.

前記表示手段は、部分式ツリーを2分木で表示することを特徴とする。  The display means displays the partial expression tree as a binary tree.

前記表示手段は、部分式ツリーをN分木で表示することを特徴とする。  The display means displays the partial expression tree as an N-ary tree.

前記表示手段が表示した部分式文字列を履歴として保存する手段を備え、前記表示手段は更に前記履歴として保存する手段から履歴を取得し表示することを特徴とする。  The sub-character string displayed by the display means is stored as a history, and the display means further obtains and displays the history from the history storage means.

前記表示手段が表示した部分式文字列を利用者が編集することができる。  The user can edit the partial expression character string displayed by the display means.

前記表示手段が表示した部分式ツリーを利用者が編集することができる。  The user can edit the partial expression tree displayed by the display means.

論理式を部分式ツリーの再帰構造からなる部分式ツリーとして分割し視覚的に表示することで、利用者は複雑な論理式の構造を容易に把握することが出来るという効果を有する。  By dividing the logical expression as a partial expression tree composed of a recursive structure of the partial expression tree and visually displaying it, the user can easily grasp the structure of a complicated logical expression.

論理式を部分式文字列として分割して表示することで、利用者は複雑な論理式を分解して理解することが出来る。この部分式文字列を前記部分式ツリーと合わせて表示することで、利用者は複雑な論理式の構造を容易に把握することが出来るという効果を有する。  By dividing and displaying a logical expression as a partial expression character string, a user can decompose and understand a complicated logical expression. By displaying this sub-expression character string together with the sub-expression tree, there is an effect that the user can easily grasp the structure of a complicated logical expression.

部分式ツリーは、検索した際の件数が合わせて表示されるため、利用者は実際に検索を行わなくても、論理式に該当する件数を知ることが出来る。部分式ツリーは再帰構造となっているため、利用者は検索に用いた論理式全体の件数だけでなく、論理式の個々の部分についても件数を把握できる。これにより、論理式を見直すための判断材料を得ることが出来るという効果を有する。  The sub-expression tree is displayed together with the number of cases when it is searched, so that the user can know the number of cases corresponding to the logical expression without actually performing the search. Since the sub-expression tree has a recursive structure, the user can grasp not only the total number of logical expressions used for the search but also the number of individual parts of the logical expression. Thereby, there is an effect that a judgment material for reviewing the logical expression can be obtained.

部分式ツリーは、利用者の操作により、部分式文字列を残し部分式ツリーを非表示とするか、部分式文字列とともに部分式ツリーを表示するかを選択できるため、不必要な部分式ツリーを非表示にすることで複雑な論理式の把握をより容易にすることが出来るという効果を有する。  The sub-expression tree can be selected by the user's operation to leave the sub-expression string and hide the sub-expression tree, or to display the sub-expression tree together with the sub-expression string. By hiding, it is possible to make it easier to comprehend complex logical expressions.

これら、論理式の構造を容易に把握することができる効果は、論理式を編集する際にも効果的であることは言うまでもない。  Needless to say, the effect that the structure of the logical expression can be easily grasped is also effective when the logical expression is edited.

論理式の編集は、部分式文字列を編集する方法と部分式ツリーを編集する方法のいずれも可能である。そのため状況に応じてより適した方法で編集することが出来るという効果がある。  The logical expression can be edited by either a method of editing the sub-expression character string or a method of editing the sub-expression tree. Therefore, there is an effect that editing can be performed by a more suitable method according to the situation.

例えば、部分式文字列を編集する方式では、論理式はテキスト形式となるため、論理式の一部をオペレーティングシステムのクリップボード機能でテキスト形式としてコピーして、別の場所に張り付けたり、有用な部分式文字列をテキストファイル形式でローカルファイルシステムに保存したりすることが可能である。部分式ツリーを編集する方式では、論理式の構造を視覚的に把握した状態で編集を行うことが可能である。また、マウス等ポインティングデバイスによって編集操作を可能にすることもできる。  For example, in the method of editing a sub-expression character string, the logical expression is in text format, so a part of the logical expression is copied as text format with the clipboard function of the operating system and pasted to another place or a useful part It is possible to store the expression string in a text file format in the local file system. In the method of editing the sub-expression tree, it is possible to perform editing while visually grasping the structure of the logical expression. Further, the editing operation can be made possible by a pointing device such as a mouse.

部分式ツリーはその全部又は一部を履歴として保存できるため、編集を間違えた場合に元に戻したり、過去の有用な部分式文字列を再利用する等して、論理式の編集をより容易にすることが出来るという効果がある。  Since all or part of the partial expression tree can be saved as a history, it is easier to edit a logical expression by returning to the original if you make a mistake or by reusing a past useful partial expression string. There is an effect that can be made.

特許文献1「特開2012−78966」は検索クエリーの作成を支援する装置の発明であり、論理式をツリー構造で表示、編集することが出来るが、部分式文字列を表示する手段がなく、不必要な部分式ツリーを非表示にする手段がない。本発明では不必要な部分式ツリーを非表示にし、部分式文字列と件数のみの表示にすることが可能である。また、論理式の編集を文字列で行う手段がない。本発明では、部分式文字列の編集を行うことが出来る。  Patent Document 1 “Japanese Patent Application Laid-Open No. 2012-78966” is an invention of an apparatus that supports the creation of a search query. A logical expression can be displayed and edited in a tree structure, but there is no means for displaying a partial expression character string. There is no way to hide unnecessary subexpression trees. In the present invention, it is possible to hide an unnecessary sub-expression tree and display only a sub-expression character string and the number of cases. In addition, there is no means for editing a logical expression with a character string. In the present invention, a partial character string can be edited.

発明を実施するために最適な形態の一つを図を使って示す。  One of the best modes for carrying out the invention is shown in the drawings.

図1は検索画面である。検索画面は検索テキストボックス(701)と論理式作成補助ボタン(702)、検索ボタン(703)、検索結果表示部(704)からなる。利用者が検索テキストボックス(701)に論理式を入力し、検索ボタン(703)を押下すると、検索結果が検索結果表示部(704)に表示される。また、利用者が検索テキストボックス(701)に論理式を入力し、論理式作成補助ボタン(702)を押下すると、論理式に文法上の間違いが無ければ、論理式作成補助ダイアログ(705)が表示される。なお、論理式作成補助ボタン(702)の押下は、タブキー等の任意のキーを押下した場合に、同じ動作をするようにしても良い。  FIG. 1 shows a search screen. The search screen includes a search text box (701), a logical expression creation auxiliary button (702), a search button (703), and a search result display section (704). When the user inputs a logical expression in the search text box (701) and presses the search button (703), the search result is displayed in the search result display section (704). When the user inputs a logical expression in the search text box (701) and presses the logical expression creation auxiliary button (702), if there is no grammatical error in the logical expression, the logical expression creation auxiliary dialog (705) is displayed. Is displayed. Note that the logical expression creation auxiliary button (702) may be pressed in the same manner when an arbitrary key such as a tab key is pressed.

図2に、検索テキストボックス(701)に論理式として検索キーワードのみを入力した後、論理式作成補助ダイアログ(705)を表示した検索画面を示す。論理式作成補助ダイアログ(705)は、論理式の木構造を視覚的に表示し、編集を行うためのダイアログである。論理式作成補助ダイアログ(705)は、閉じるボタン(706)と全体論理式ラベル(707)、履歴移動ボタン(708)、部分式ツリー表示部(709)からなる。  FIG. 2 shows a search screen in which a logical expression creation assistance dialog (705) is displayed after only a search keyword is entered as a logical expression in the search text box (701). The logical expression creation auxiliary dialog (705) is a dialog for visually displaying and editing the tree structure of the logical expression. The logical expression creation auxiliary dialog (705) includes a close button (706), an overall logical expression label (707), a history movement button (708), and a partial expression tree display section (709).

閉じるボタン(706)は、論理式作成補助ダイアログ(705)を終了するためのボタンである。全体論理式ラベル(707)には、論理式作成補助ダイアログ(705)にて編集した結果の論理式と前記論理式で検索した結果該当となる件数が表示される。履歴移動ボタン(708)は、論理式の編集内容の履歴を辿ることが出来るボタンである。履歴移動ボタン(708)の左ボタンを押下すると、ひとつ前の状態に戻すことが出来る。
履歴移動ボタン(708)の右ボタンを押下すると、前に戻した状態から編集後の状態へ再度進める事が出来る。部分式ツリー表示部(709)は、論理式が部分式ツリーの再帰構造で視覚的に表示される領域である。
The close button (706) is a button for ending the logical expression creation assistance dialog (705). The overall logical expression label (707) displays the logical expression as a result of editing in the logical expression creation assistance dialog (705) and the number of cases corresponding to the result of searching with the logical expression. The history movement button (708) is a button for tracing the history of the edit contents of the logical expression. When the left button of the history movement button (708) is pressed, the previous state can be restored.
By pressing the right button of the history movement button (708), it is possible to proceed again from the previous state to the state after editing. The partial expression tree display section (709) is an area where logical expressions are visually displayed in a recursive structure of the partial expression tree.

部分式ツリー表示部(709)は、表示する論理式が検索キーワードのみの場合、論理式の範囲を示す枠(710)が表示され、論理式の範囲を示す枠(710)の中に操作ボタン(711)とターム及び演算子選択ボックス(712)、ターム入力ボックス(713)、ターム表示ラベル(714)が表示される。操作ボタン(711)は、論理式に対して行うことが出来る操作を呼び出すことが出来るボタンである。操作の種類は、「入れ替え」、「削除」、「コピー」、「切り取り」及び「貼り付け」がある。ターム及び演算子選択ボックス(712)は、AND、OR、NOT、タームのいずれかが選択でき、初期時はタームが選択される。ターム入力ボックス(713)は、検索キーワードを入力するテキストボックスである。ターム表示ラベル(714)は、検索キーワードと検索キーワードで検索した場合の該当件数が表示される。  When the logical expression to be displayed is only a search keyword, the sub-expression tree display section (709) displays a frame (710) indicating the range of the logical expression, and an operation button in the frame (710) indicating the range of the logical expression. (711), a term and operator selection box (712), a term input box (713), and a term display label (714) are displayed. The operation button (711) is a button that can call an operation that can be performed on the logical expression. The types of operations include “replacement”, “deletion”, “copy”, “cut”, and “paste”. In the term and operator selection box (712), any of AND, OR, NOT, and term can be selected, and the term is initially selected. The term input box (713) is a text box for inputting a search keyword. The term display label (714) displays the search keyword and the number of hits when searching with the search keyword.

ターム及び演算子選択ボックス(712)にてAND、OR、NOTのいずれかを選択すると、選択した演算子と新しい検索キーワード入力行が追加される。図3にANDを選択した直後の論理式作成補助ダイアログが表示された検索画面を示す。ここで新たに、ツリー開閉ボタン(715)、論理演算子選択ボックス(716)、部分式編集ボタン(718)が表示される。  When one of AND, OR, and NOT is selected in the term and operator selection box (712), the selected operator and a new search keyword input line are added. FIG. 3 shows a search screen on which a logical expression creation assistance dialog is displayed immediately after AND is selected. Here, a tree open / close button (715), a logical operator selection box (716), and a partial expression edit button (718) are displayed.

ツリー開閉ボタン(715)を押下すると、図4のように論理演算子選択ボックス(716)と部分式表示ラベル(717)、部分式編集ボタン(718)を残し他の要素が非表示となる。再度ツリー開閉ボタン(715)を押下すると、非表示された項目が表示され図3の状態に戻る。論理演算子選択ボックス(716)は、上下の検索キーワード同士の関係を、AND、OR、NOTから選択できる。部分式表示ラベル(717)は、部分式文字列と、検索を行った場合の該当件数を表示する。部分式編集ボタン(718)は、部分式文字列を直接編集するためのボタンである。部分式編集ボタン(718)を押下すると、図5に示すように、部分式表示ラベル(717)が、入力可能な部分式入力ボックス(719)に変わる。部分式入力ボックス(719)は、論理式を直接入力することが出来る。入力を終えて編集終了ボタン(720)を押下すると、入力した論理式に従い木構造が再度作成される。このとき入力された論理式に間違いがあれば、その旨のエラーを表示する事も出来る。  When the tree open / close button (715) is pressed, the logical operator selection box (716), the partial expression display label (717), and the partial expression edit button (718) are left and other elements are hidden as shown in FIG. When the tree open / close button (715) is pressed again, the non-displayed items are displayed and the state returns to the state shown in FIG. The logical operator selection box (716) can select the relationship between the upper and lower search keywords from AND, OR, and NOT. The sub-expression display label (717) displays the sub-expression character string and the number of cases corresponding to the search. The partial expression edit button (718) is a button for directly editing the partial expression character string. When the partial expression edit button (718) is pressed, as shown in FIG. 5, the partial expression display label (717) is changed to an inputable partial expression input box (719). In the partial expression input box (719), a logical expression can be directly input. When the input is finished and the edit end button (720) is pressed, a tree structure is created again according to the input logical expression. If there is an error in the input logical expression, an error to that effect can be displayed.

論理式の範囲を示す枠(710)は、入れ子にすることができる。これにより論理式の木構造を階層的に表示する。図6は、図3にOR条件を追加した画面の例である。この入れ子は何段でも行うことが出来る。  The frame (710) indicating the range of logical expressions can be nested. As a result, the tree structure of the logical expression is displayed hierarchically. FIG. 6 is an example of a screen in which an OR condition is added to FIG. This nesting can be done in any number of stages.

操作ボタン(711)について詳細を説明する。操作ボタン(711)は、表示された位置により操作の対象となる範囲が違う。タームの左にある操作ボタン(711)の場合は、操作の対象となる範囲は、同一行のタームが操作の対象となる。論理演算子の左にある操作ボタン(711)の場合は、自身を含む論理式の範囲を示す枠(710)で囲われた部分が操作の対象となる。操作ボタン(711)を押下すると、操作選択メニュー(721)が表示される。操作選択メニュー(721)には「入れ替え」、「削除」、「コピー」、「切り取り」及び「貼り付け」が表示され、利用者に選択された操作が実行される。「入れ替え」を選択すると、論理演算子を中心に第1項目と第2項目が入れ替えられる。「削除」を選択すると操作の対象となる範囲の論理式が削除される。このとき不要になる論理演算子もあわせて削除される。「コピー」を選択すると、操作の対象となる範囲の論理式がメモリ上にコピーされる。「切り取り」を選択すると、操作の対象となる範囲の論理式が削除されるとともにメモリ上にコピーされる。事前に「コピー」又は「切り取り」を実施した後に、「貼り付け」を選択すると、メモリ上にコピーされていた論理式がAND条件で接続される。  Details of the operation button (711) will be described. The operation button (711) has a different range to be operated depending on the displayed position. In the case of the operation button (711) on the left of the term, the operation target is the term in the same row. In the case of the operation button (711) on the left of the logical operator, the portion surrounded by a frame (710) indicating the range of the logical expression including itself is the target of the operation. When the operation button (711) is pressed, an operation selection menu (721) is displayed. In the operation selection menu (721), “replace”, “delete”, “copy”, “cut”, and “paste” are displayed, and the operation selected by the user is executed. When “exchange” is selected, the first item and the second item are exchanged around the logical operator. When “Delete” is selected, the logical expression in the range to be operated is deleted. At this time, unnecessary logical operators are also deleted. When “Copy” is selected, the logical expression in the range to be operated is copied onto the memory. When “Cut” is selected, the logical expression in the range to be operated is deleted and copied to the memory. When “Paste” is selected after “Copy” or “Cut” is performed in advance, the logical expressions copied on the memory are connected with an AND condition.

また、ユーザーインターフェースにマウス等のポインティングデバイスを使っている場合、ドラッグアンドドロップで論理式の移動を行うことを可能にしても良い。この場合操作ボタン(711)の上でマウスの左ボタンを押下し、そのまま移動を行いたい箇所までポインタを移動(ドラッグ)し、左ボタンを開放(ドロップ)すると、ポインタが指し示す箇所に論理式が移動する。  Further, when a pointing device such as a mouse is used for the user interface, it may be possible to move a logical expression by drag and drop. In this case, when the left button of the mouse is pressed on the operation button (711), the pointer is moved (dragged) to the position to be moved, and the left button is released (dropped), the logical expression is displayed at the position indicated by the pointer. Moving.

利用者は、以上で説明したターム及び論理演算子の選択、タームの編集、論理演算子の選択、部分式文字列の編集、入れ替え、削除、コピー、切り取り、貼り付け等の操作を組み合わせて論理式を編集する。希望の論理式が出来たならば、全体論理式ラベル(707)を押下すると、論理式が検索テキストボックス(701)に入力され、検索が実行される。また、論理式全体だけでなく論理式の一部についても、部分式表示ラベル(717)を押下する事で同様に検索を行うことが出来る。  The user can combine the above-mentioned operations such as selection of terms and logical operators, editing of terms, selection of logical operators, selection of logical operators, editing, replacement, deletion, copying, cutting, and pasting of subexpression character strings. Edit the expression. When the desired logical expression is completed, when the entire logical expression label (707) is pressed, the logical expression is input to the search text box (701), and the search is executed. Further, not only the whole logical expression but also a part of the logical expression can be similarly searched by pressing the partial expression display label (717).

本発明を実現する装置は、前記した検索画面(200)と、検索画面(200)を表示するWEBブラウザ(100)と、検索画面(200)を保存する画面配信装置(300)と、論理式を解析するための論理式解析装置(400)と、論理式の該当件数を求めるための件数検索装置(500)と、論理式にて検索を行う検索装置(600)を備える。これら装置の関係をあらわしたブロック図を図7に示す。  An apparatus for realizing the present invention includes a search screen (200), a WEB browser (100) that displays the search screen (200), a screen distribution device (300) that stores the search screen (200), and a logical expression. A logical expression analysis device (400) for analyzing the number of cases, a number search device (500) for obtaining the corresponding number of logical expressions, and a search device (600) for performing a search using logical expressions. A block diagram showing the relationship between these devices is shown in FIG.

利用者は、WEBブラウザ(100)を使って、画面配信装置(300)から検索画面(200)を取得する。WEBブラウザは検索画面(200)を表示する。利用者が検索画面(200)の検索テキストボックス(701)に論理式を入力し、702作成補助ボタンを押下すると、検索画面(200)が持つ論理式送信ロジック(201)を使って、検索テキストボックス(701)に入力された論理式を論理式解析装置(400)に非同期で送信する。ここで、非同期とは通信の返答を待っている間にほかの処理を実行可能とし、ほかの処理を行っている間に返答があれば、受信処理を実行する通信方式を指す。  The user acquires the search screen (200) from the screen distribution device (300) using the WEB browser (100). The WEB browser displays a search screen (200). When a user inputs a logical expression into the search text box (701) of the search screen (200) and presses the 702 creation auxiliary button, the search text is searched using the logical expression transmission logic (201) of the search screen (200). The logical expression input in the box (701) is asynchronously transmitted to the logical expression analyzer (400). Asynchronous refers to a communication method in which other processing can be executed while waiting for a communication response, and if there is a response while other processing is being performed, reception processing is executed.

論理式解析装置(400)は、二分木に構造化された論理式に変換する。二分木に構造化された論理式とは、二分木の各枝に検索キーワードを持ち、節に論理演算子を持つ二分木である。二分木に構造化された論理式の概念図を図8に示す。  The logical expression analyzer (400) converts the logical expression into a logical expression structured in a binary tree. A logical expression structured in a binary tree is a binary tree having a search keyword in each branch of the binary tree and a logical operator in a clause. A conceptual diagram of a logical expression structured in a binary tree is shown in FIG.

論理式解析装置(400)が、送られた論理式から二分木に構造化された論理式に変換する処理は図20−1及び図20−2に示すフローにそって次のように行う。論理式解析装置(400)は、まず事前処理S01にて二分木を保存するスタックを用意する。次に単語分解処理S02により送られた論理式を前から1文字ずつ読み、文字列から単語を取り出す。単語がなければ処理は終了である。単語が“(”の場合、スタック作成処理S03により新しい二分木をスタックに積み単語分解処理S02に戻る。単語が“)”でありスタックに二分木が二つ以上積まれていた場合、スタック取り出し処理S04によりスタックから二分木を一つ取り出し、次のスタックの二分木の枝に取り出した二分木を設定する。単語がいずれでもない場合、二分木の枝に検索キーワードとして判別した単語を設定する。  The logical expression analyzer (400) converts the sent logical expression into a logical expression structured into a binary tree as follows in accordance with the flow shown in FIGS. 20-1 and 20-2. The logical expression analyzer (400) first prepares a stack for storing the binary tree in the pre-processing S01. Next, the logical expression sent by the word decomposition process S02 is read character by character from the front, and the word is extracted from the character string. If there are no words, the process ends. If the word is “(”, the stack creation process S03 stacks a new binary tree on the stack and returns to the word decomposition process S02. If the word is “)” and two or more binary trees are stacked on the stack, the stack is extracted. In step S04, one binary tree is extracted from the stack, and the extracted binary tree is set in the branch tree branch of the next stack. If the word is not any, the determined word is set as a search keyword on the branch of the binary tree.

次に単語分解処理S06により空白以外の文字が見つかるまで読み進め、単語がなかったならば処理を終了する。単語があったならば単語の種類によって処理を切り替える。単語が“AND”、“OR”又は“NOT”の場合、ひとつ前の演算子と優先順位を比較し、優先順位が低いか同じであれば、節作成処理S07により演算子の節を作成し、作成した節の枝に前の節を設定し、単語分解処理S02に戻る。優先順位が高ければ、節作成処理S08により演算子の節を作成し、最後に設定した枝に置き換え、枝を節の下に移動し、単語分解処理S02に戻る。単語がいずれでもなかった場合、“AND”が存在したものとし、ひとつ前の演算子と優先順位を比較する。優先順位が低いか同じであれば、節作成処理S07によりAND演算子の節を作成し、作成した節の枝に前の節を設定し、単語による分岐B02に戻る。優先順位が高ければ、節作成処理S08によりAND演算子の節を作成し、最後に設定した枝に置き換え、枝を節の下に移動し、単語による分岐B02に戻る。  Next, reading is continued until a character other than a blank is found in the word decomposition process S06. If there is no word, the process ends. If there is a word, the process is switched depending on the type of word. When the word is “AND”, “OR” or “NOT”, the priority is compared with the previous operator, and if the priority is low or the same, the clause of the operator is created by the clause creation processing S07. Then, the previous section is set in the created section branch, and the process returns to the word decomposition process S02. If the priority is high, a clause for the operator is created by the clause creation processing S08, replaced with the last set branch, the branch is moved below the clause, and the processing returns to the word decomposition processing S02. If there is no word, it is assumed that “AND” exists, and the priority is compared with the previous operator. If the priorities are low or the same, a clause for an AND operator is created by clause creation processing S07, the previous clause is set to the branch of the created clause, and the process returns to word branch B02. If the priority is high, a clause of the AND operator is created by the clause creation process S08, replaced with the last set branch, the branch is moved below the clause, and the process returns to the word branch B02.

論理式解析装置(400)は、二分木に構造化された論理式を検索画面(200)に返却する。返却する形式はいずれでも構わないが、当該実施例ではJSONを利用する。JSONで表現した二分木に構造化された論理式を図9に示す。  The logical expression analyzer (400) returns the logical expression structured in the binary tree to the search screen (200). Any format can be returned, but JSON is used in this embodiment. FIG. 9 shows a logical expression structured in a binary tree expressed in JSON.

検索画面(200)は二分木に構造化された論理式を受け取ると二分木表示ロジック(202)使って画面に表示する。  When the search screen (200) receives the logical expression structured in the binary tree, the search screen (200) displays it on the screen using the binary tree display logic (202).

二分木表示ロジック(202)は、受け取った二分木に構造化された論理式の節を論理式の範囲を示す枠(710)を表すHTML要素に、節に設定された演算子を論理演算子選択ボックス(716)を表すHTML要素に、枝に設定された検索キーワードをターム入力ボックス(713)及びターム表示ラベル(714)を表すHTML要素に変換する。同時に二分木に構造化された論理式の節から演算子を取り出し、枝の検索キーワードと連結していくことで整形された論理式を求め、部分式表示ラベル(717)を表すHTMLの要素に変換する。  The binary tree display logic (202) converts a logical expression clause structured in the received binary tree into an HTML element representing a frame (710) indicating a range of the logical expression, and an operator set in the clause as a logical operator. The search keyword set in the branch is converted into an HTML element representing a selection box (716) and an HTML element representing a term input box (713) and a term display label (714). At the same time, an operator is taken out from the clause of the logical expression structured in the binary tree, and a logical expression that is shaped by connecting with the branch search keyword is obtained, and the HTML element representing the subexpression display label (717) is obtained. Convert.

検索画面(200)は、二分木に構造化された論理式から求めた整形された論理式を件数検索装置(500)に非同期で送信する。件数検索装置(500)は送信された論理式で検索を行い、該当件数を返却する。検索画面(200)は、返却された件数を全体論理式ラベル(707)、ターム表示ラベル(714)及び部分式表示ラベル(717)に表示する。テキストボックスへの論理式の入力から、件数の表示までのシーケンスを図10に示す。  The search screen (200) asynchronously transmits the shaped logical formula obtained from the logical formula structured in the binary tree to the number search device (500). The number search device (500) performs a search using the transmitted logical expression and returns the number of cases. The search screen (200) displays the number of returned items on the whole logical expression label (707), the term display label (714), and the partial expression display label (717). FIG. 10 shows a sequence from inputting a logical expression to the text box to displaying the number of cases.

この論理式を解析し、件数を表示するまでの処理は、部分式文字列及び部分式ツリーの編集を行ったときも同様に行う。また、複数の部分式文字列及び部分式ツリーについて変更がある場合は、変更箇所毎に処理は非同期かつ並列で行う。  The processing from the analysis of the logical expression to the display of the number of cases is similarly performed when the partial expression character string and the partial expression tree are edited. In addition, when there are changes in a plurality of sub-expression character strings and sub-expression trees, processing is performed asynchronously and in parallel for each changed portion.

実施例1を元に、検索した論理式の履歴を保存し再利用することを可能にした場合の例を示す。
実施例1で用意した装置に加えて、論理式を保存する装置(900)を備える。また、検索画面の検索結果表示部(704)のヘッダ部分に、論理式保存ボタン(724)を設け、論理式作成補助ダイアログ(705)に保存済み論理式表示ボタン(725)を追加する。さらに、保存済みの論理式の一覧をを表示するために、保存済み論理式一覧表示パネル(726)を用意する。この画面イメージを図11、図12及び図13に示す
Based on the first embodiment, an example in which the history of retrieved logical expressions can be saved and reused is shown.
In addition to the apparatus prepared in the first embodiment, an apparatus (900) for storing a logical expression is provided. Also, a logical expression save button (724) is provided in the header portion of the search result display section (704) of the search screen, and a saved logical expression display button (725) is added to the logical expression creation assistance dialog (705). Further, a stored logical expression list display panel (726) is prepared to display a list of stored logical expressions. This screen image is shown in FIG. 11, FIG. 12 and FIG.

実施例1で示したように、検索画面にて利用者が検索テキストボックス(701)に論理式を入力し、検索ボタン(703)を押下すると、検索結果が検索結果表示部(704)に表示される。このとき検索画面は、検索装置600に論理式を送信すると同時に、送信した論理式をWebブラウザのメモリ上に履歴として保存する。また、検索結果表示部(704)に設けた、論理式保存ボタン(724)を押下すると、この時検索を行った論理式が論理式を保存する装置900へ送信され、論理式を保存する装置900は受け取った論理式を保存する。  As shown in the first embodiment, when the user inputs a logical expression in the search text box (701) on the search screen and presses the search button (703), the search result is displayed on the search result display unit (704). Is done. At this time, the search screen transmits the logical expression to the search device 600 and simultaneously stores the transmitted logical expression as a history in the memory of the Web browser. Further, when a logical expression storage button (724) provided in the search result display section (704) is pressed, the logical expression searched at this time is transmitted to the apparatus 900 for storing the logical expression, and the apparatus for storing the logical expression 900 stores the received logical expression.

保存した論理式を利用するときは、利用者が保存済み論理式表示ボタン(725)を押下し保存済み論理式一覧表示パネル(726)を表示する。保存済み論理式一覧表示パネル(726)は、選択タブ(727)、論理式一覧(728)、論理式コピーボタン(729)及び削除ボタン(730)で構成される。  When using the stored logical expression, the user presses the stored logical expression display button (725) to display the stored logical expression list display panel (726). The saved logical expression list display panel (726) includes a selection tab (727), a logical expression list (728), a logical expression copy button (729), and a delete button (730).

選択タブ(727)は、検索を実行した際に自動保存された論理式の一覧と、利用者が論理式保存ボタン(724)を押下して明示的に保存した論理式の一覧を切り替えるためのタブボタンである。論理式一覧(728)は保存された論理式の一覧が表示される領域である。履歴タブを選択するとブラウザのメモリ上に保存された論理式の一覧が表示される。お気に入りタブを選択すると、検索画面は論理式を保存する装置900から保存されている論理式を取得し、取得した論理式の一覧が表示される。自動保存した論理式の一覧と明示的に保存した論理式の一覧で表示される項目に違いはない。利用者が論理式一覧(728)から挿入したい論理式を選択し論理式コピーボタン(729)を押下すると、選択した保存済みの論理式がメモリ上にコピーされる。利用者が挿入したい位置の操作ボタン(711)を押下し、「貼り付け」を選択すると、メモリ上にコピーされていた論理式がAND条件で接続される。論理式一覧(728)に表示された論理式の一覧に不要な論理式があれば、削除ボタン(730)を押下して削除することも出来る。  The selection tab (727) is used to switch between a list of logical expressions automatically saved when the search is executed and a list of logical expressions explicitly saved by the user pressing the logical expression save button (724). Tab button. The logical expression list (728) is an area in which a list of stored logical expressions is displayed. Selecting the History tab displays a list of logical expressions stored in the browser memory. When the favorite tab is selected, the search screen acquires the logical expressions stored from the apparatus 900 for storing logical expressions, and a list of the acquired logical expressions is displayed. There is no difference between the items displayed in the list of automatically saved formulas and the list of explicitly saved formulas. When the user selects a logical expression to be inserted from the logical expression list (728) and presses the logical expression copy button (729), the selected saved logical expression is copied onto the memory. When the user depresses the operation button (711) at the position to be inserted and selects "Paste", the logical expressions copied on the memory are connected by the AND condition. If there is an unnecessary logical expression in the list of logical expressions displayed in the logical expression list (728), it can be deleted by pressing the delete button (730).

また、ユーザーインターフェースにマウス等のポインティングデバイスを使っている場合、ドラッグアンドドロップで保存した論理式の挿入を行うことを可能にしても良い。この場合論理式一覧(728)に表示された論理式の上でマウスの左ボタンを押下し、そのまま挿入を行いたいターム又は部分式文字列の上までポインタを移動(ドラッグ)し、左ボタンを開放(ドロップ)すると、ポインタが指し示す箇所のターム又は部分式文字列に選択した論理式がAND条件で接続される。  Further, when a pointing device such as a mouse is used for the user interface, it may be possible to insert a logical expression stored by drag and drop. In this case, press the left mouse button on the logical expression displayed in the logical expression list (728), move (drag) the pointer over the term or sub-expression character string you want to insert, and click the left button. When released (dropped), the selected logical expression is connected to the term or sub-expression character string at the location indicated by the pointer using an AND condition.

実施例2を元に、部分式文字列を保存し再利用することを可能にした場合の例を示す。  Based on the second embodiment, an example in which the sub-expression character string can be stored and reused is shown.

実施例2で用意した装置及び変更した画面に加え、論理式作成補助ダイアログ(705)に、部分式保存ボタン(731)を設ける。この画面イメージを図14に示す  In addition to the device prepared in the second embodiment and the changed screen, a partial expression saving button (731) is provided in the logical expression creation assistance dialog (705). This screen image is shown in FIG.

利用者が再利用したいと考えた部分式文字列について、当該部分式文字列の近傍に表示した部分式保存ボタン(731)を押下すると、900部分式を保存する装置に論理式である部分式文字列が送信され保存される。  When the user saves the subexpression save button (731) displayed in the vicinity of the subexpression character string for the subexpression character string that the user wants to reuse, the subexpression that is a logical expression in the device that stores 900 subexpressions. The string is sent and saved.

保存した論理式を利用するときは、実施例2と同様に、利用者が保存済み論理式表示ボタン(725)を押下し保存済み論理式一覧表示パネル(726)を表示する。  When using the saved logical expression, as in the second embodiment, the user presses the saved logical expression display button (725) to display the saved logical expression list display panel (726).

選択タブ(727)は、検索を実行した際に自動保存された論理式の一覧と、利用者が論理式保存ボタン(724)又は部分式保存ボタン(722)を押下して明示的に保存した論理式の一覧を切り替えるためのタブボタンである。論理式一覧(728)は保存された論理式の一覧が表示される領域である。お気に入りタブを選択すると、検索画面は論理式を保存する装置900から保存されている論理式を取得し、取得した論理式の一覧が表示される。自動保存した論理式の一覧と明示的に保存した論理式の一覧で表示される項目に違いはない。利用者が論理式一覧(728)から挿入したい論理式を選択し論理式コピーボタン(729)を押下すると、選択した保存済みの論理式がメモリ上にコピーされる。利用者が挿入したい位置の操作ボタン(711)を押下し、「貼り付け」を選択すると、メモリ上にコピーされていた論理式がAND条件で接続される。論理式一覧(728)に表示された論理式の一覧に不要な論理式があれば、削除ボタン(730)を押下して削除することも出来る。  The selection tab (727) is a list of logical expressions that are automatically saved when the search is executed, and is explicitly saved by the user pressing the logical expression save button (724) or the partial expression save button (722). A tab button for switching a list of logical expressions. The logical expression list (728) is an area in which a list of stored logical expressions is displayed. When the favorite tab is selected, the search screen acquires the logical expressions stored from the apparatus 900 for storing logical expressions, and a list of the acquired logical expressions is displayed. There is no difference between the items displayed in the list of automatically saved formulas and the list of explicitly saved formulas. When the user selects a logical expression to be inserted from the logical expression list (728) and presses the logical expression copy button (729), the selected saved logical expression is copied onto the memory. When the user depresses the operation button (711) at the position to be inserted and selects "Paste", the logical expressions copied on the memory are connected by the AND condition. If there is an unnecessary logical expression in the list of logical expressions displayed in the logical expression list (728), it can be deleted by pressing the delete button (730).

また、ユーザーインターフェースにマウス等のポインティングデバイスを使っている場合、ドラッグアンドドロップで保存した論理式の挿入を行うことを可能にしても良い。この場合論理式一覧(728)に表示された論理式の上でマウスの左ボタンを押下し、そのまま挿入を行いたいターム又は部分式文字列の上までポインタを移動(ドラッグ)し、左ボタンを開放(ドロップ)すると、ポインタが指し示す箇所のターム又は部分式文字列に選択した論理式がAND条件で接続される。  Further, when a pointing device such as a mouse is used for the user interface, it may be possible to insert a logical expression stored by drag and drop. In this case, press the left mouse button on the logical expression displayed in the logical expression list (728), move (drag) the pointer over the term or sub-expression character string you want to insert, and click the left button. When released (dropped), the selected logical expression is connected to the term or sub-expression character string at the location indicated by the pointer using an AND condition.

実施例1を元に、論理式をN分木に構造化するように改良した場合の例を示す。実施例1に示す方法では、論理式を表す木構造を二分木としていた。二分木は構造が単純であり、実装が容易である反面、列挙する検索キーワードが多いときに、階層が深くなってしまうという問題があった。本実施例では、論理式を表す木構造としてN分木を用いることで、この問題を解決する。  Based on the first embodiment, an example in which the logical expression is improved to be structured into an N-ary tree will be described. In the method shown in the first embodiment, the tree structure representing the logical expression is a binary tree. Although the binary tree has a simple structure and is easy to implement, there is a problem that the hierarchy becomes deep when there are many search keywords to enumerate. In this embodiment, this problem is solved by using an N-ary tree as a tree structure representing a logical expression.

図13は論理式をN分木に構造化するようにした場合の、論理式作成補助ダイアログの例である。論理式の範囲を示す枠(801)内には、実施例1では、ターム又は部分式ツリーいずれか二つまでしか記述できなかったが、この例ではN個のターム又は部分式ツリーを記述できる。それに伴い論理演算子選択ボックス(802)で選択された演算子の意味は、2つのターム又は部分式ツリーの関係ではなく、N個のターム又は部分式ツリーの関係となっている。それにともない部分式表示ラベル(803)の表示位置は、論理式の範囲を示す枠内の1行目とした。  FIG. 13 shows an example of a logical expression creation assistance dialog when a logical expression is structured into an N-ary tree. In the frame (801) indicating the range of the logical expression, only up to two terms or subexpression trees can be described in the first embodiment, but in this example, N terms or subexpression trees can be described. . Accordingly, the meaning of the operator selected in the logical operator selection box (802) is not a relationship between two terms or subexpression trees but a relationship between N terms or subexpression trees. Accordingly, the display position of the partial expression display label (803) is the first line in the frame indicating the range of the logical expression.

N分木となったことで、新たなタームを追加する場合、論理式の範囲を示す枠(801)内の他のタームと同列に追加するか、新しい論理式の範囲を示す枠(801)を設けて、一つ下位に追加するかを選択する必要がある。そこで操作選択メニュー(804)の選択肢として、同列に追加と下位に追加を用意する。  When a new term is added because it is an N-ary tree, it is added in the same row as another term in the frame (801) indicating the range of the logical expression, or a frame (801) indicating the range of the new logical expression It is necessary to select whether to add one lower level. Therefore, as an option of the operation selection menu (804), an addition in the same row and an addition in the lower level are prepared.

実施例4を実現する装置は、実施例1と同様に、検索画面(200)を表示するWEBブラウザ(100)と、検索画面(200)を保存する画面配信装置(300)と、論理式を解析するための論理式解析装置(400)と、論理式の該当件数を求めるための件数検索装置(500)と、論理式にて検索を行う検索装置(600)を備える。このうち検索画面(200)と論理式解析装置(400)の変更が必要である。  As in the first embodiment, the apparatus that implements the fourth embodiment includes a WEB browser (100) that displays the search screen (200), a screen distribution apparatus (300) that stores the search screen (200), and a logical expression. A logical expression analysis apparatus (400) for analysis, a number search apparatus (500) for obtaining the number of corresponding logical expressions, and a search apparatus (600) for performing a search using a logical expression are provided. Of these, the search screen (200) and logical expression analyzer (400) need to be changed.

利用者は、WEBブラウザ(100)を使って、画面配信装置(300)から検索画面(200)を取得する。WEBブラウザは検索画面(200)を表示する。利用者が検索画面(200)の検索テキストボックス(701)に論理式を入力し、702作成補助ボタンを押下すると、検索画面(200)が持つ論理式送信ロジック(201)を使って、検索テキストボックス(701)に入力された論理式を論理式解析装置(400)に非同期で送信する。  The user acquires the search screen (200) from the screen distribution device (300) using the WEB browser (100). The WEB browser displays a search screen (200). When a user inputs a logical expression into the search text box (701) of the search screen (200) and presses the 702 creation auxiliary button, the search text is searched using the logical expression transmission logic (201) of the search screen (200). The logical expression input in the box (701) is asynchronously transmitted to the logical expression analyzer (400).

論理式解析装置(400)は、N分木に構造化された論理式に変換する。N分木に構造化された論理式とは、N分木の各枝に検索キーワードを持ち、節に論理演算子を持つN分木である。N分木に構造化された論理式の概念図を図14に示す。  The logical expression analyzer (400) converts the logical expression into a logical expression structured in an N-ary tree. A logical expression structured in an N-ary tree is an N-ary tree having a search keyword in each branch of the N-ary tree and a logical operator in a clause. A conceptual diagram of a logical expression structured in an N-ary tree is shown in FIG.

論理式解析装置(400)が、送られた論理式からN分木に構造化された論理式に変換する処理は図21−1及び図21−2に示すフローにそって次のように行う。論理式解析装置(400)は、まず事前処理S21にてN分木を保存するスタックを用意する。次に単語分解処理S22により送られた論理式を前から1文字ずつ読み、文字列から単語を取り出す。単語がなければ処理は終了である。単語が“(”の場合、スタック作成処理S23により新しいN分木をスタックに積み単語分解処理S22に戻る。単語が“)”でありスタックにN分木が二つ以上積まれていた場合、スタック取り出し処理S24によりスタックからN分木を一つ取り出し、次のスタックのN分木の枝に取り出したN分木を設定する。単語がいずれでもない場合、N分木の枝に検索キーワードとして判別した単語を設定する。  The logical expression analyzer (400) converts the sent logical expression into a logical expression structured into an N-ary tree as follows according to the flow shown in FIGS. 21-1 and 21-2. . The logical expression analyzer (400) first prepares a stack for storing the N-ary tree in the pre-processing S21. Next, the logical expression sent by the word decomposition process S22 is read character by character from the front, and the word is extracted from the character string. If there are no words, the process ends. When the word is “(”, a new N-ary tree is stacked on the stack by the stack creation process S23 and the process returns to the word decomposition process S22. When the word is “)” and two or more N-ary trees are stacked on the stack, One N branch tree is extracted from the stack by stack extraction processing S24, and the extracted N branch tree is set to the branch of the N tree of the next stack. If the word is not any, the determined word is set as a search keyword on the branch of the N-ary tree.

次に単語分解処理S26により空白以外の文字が見つかるまで読み進め、単語がなかったならば処理を終了する。単語があったならば単語の種類によって処理を切り替える。単語が“AND”、“OR”又は“NOT”の場合、ひとつ前の演算子と優先順位を比較し、優先順位が低ければ、節作成処理S27により演算子の節を作成し、作成した節の枝に前の節を設定し、単語分解処理S22に戻る。優先順位が高ければ、節作成処理S28により演算子の節を作成し、最後に設定した枝に置き換え、枝を節の下に移動し、単語分解処理S22に戻る。演算子が同じであれば、空の枝を追加し、単語分解処理S22に戻る。単語がいずれでもなかった場合、“AND”が存在したものとし、ひとつ前の演算子と優先順位を比較する。優先順位が低ければ、節作成処理S27によりAND演算子の節を作成し、作成した節の枝に前の節を設定し、単語による分岐B22に戻る。優先順位が高ければ、節作成処理S28によりAND演算子の節を作成し、最後に設定した枝に置き換え、枝を節の下に移動し、単語による分岐B22に戻る。演算子が同じであれば、空の枝を追加し、単語分解処理S22に戻る。  Next, reading is continued until a character other than a blank is found in the word decomposition process S26, and if there is no word, the process ends. If there is a word, the process is switched depending on the type of word. When the word is “AND”, “OR” or “NOT”, the priority is compared with the previous operator. If the priority is low, the clause of the operator is created by the clause creation processing S27, and the created clause is created. The previous section is set to the branch of, and the process returns to the word decomposition process S22. If the priority is high, a clause for the operator is created by the clause creation processing S28, replaced with the last set branch, the branch is moved below the clause, and the processing returns to the word decomposition processing S22. If the operators are the same, an empty branch is added, and the process returns to the word decomposition process S22. If there is no word, it is assumed that “AND” exists, and the priority is compared with the previous operator. If the priority is low, a clause for the AND operator is created by the clause creation process S27, the previous clause is set to the branch of the created clause, and the process returns to the word branch B22. If the priority is high, a clause of the AND operator is created by the clause creation processing S28, replaced with the last set branch, the branch is moved below the clause, and the process returns to the word branch B22. If the operators are the same, an empty branch is added, and the process returns to the word decomposition process S22.

論理式解析装置(400)は、N分木に構造化された論理式を検索画面(200)に返却する。返却する形式はいずれでも構わないが、当該実施例ではJSONを利用する。JSONで表現したN分木に構造化された論理式の例を[図15]に示す。The logical expression analyzer (400) returns the logical expression structured in the N-ary tree to the search screen (200). Any format can be returned, but JSON is used in this embodiment. An example of a logical expression structured in an N-ary tree expressed in JSON is shown in FIG.

検索画面(200)は返却されたN分木に構造化された論理式を画面に表示する。検索画面(200)は、N分木に構造化された論理式から整形された論理式を求め、求めた論理式を件数検索装置(500)に非同期で送信する。件数検索装置(500)は送信された論理式で検索を行い、該当件数を返却する。検索画面(200)は、返却された件数をターム表示ラベル(805)及び部分式表示ラベル(803)に表示する。  The search screen (200) displays a logical expression structured on the returned N-ary tree on the screen. The search screen (200) obtains a logical expression shaped from a logical expression structured in an N-ary tree and transmits the obtained logical expression to the number search device (500) asynchronously. The number search device (500) performs a search using the transmitted logical expression and returns the number of cases. The search screen (200) displays the number of returned items on the term display label (805) and the partial expression display label (803).

この論理式を解析し、件数を表示するまでの処理は、部分式文字列及び部分式ツリーの編集を行ったときも同様に行う。また、複数の部分式文字列及び部分式ツリーについて変更がある場合は、変更箇所毎に処理は非同期かつ並列で行う。  The processing from the analysis of the logical expression to the display of the number of cases is similarly performed when the partial expression character string and the partial expression tree are edited. In addition, when there are changes in a plurality of sub-expression character strings and sub-expression trees, processing is performed asynchronously and in parallel for each changed portion.

実施例1を元に、タームにフィールド名を指定できるようにした場合の例を示す。  An example in which a field name can be specified for a term based on the first embodiment will be described.

検索対象のデータが属性毎のフィールドに区切られて保存されている場合、フィールド名を指定して検索を行うことがで、より正確に検索を行うことができる。  When the search target data is stored by being divided into fields for each attribute, the search can be performed more accurately by specifying the field name and performing the search.

図16は、タームにフィールド名を指定できるようにした、論理式作成補助ダイアログである。ターム入力ボックスの前に、新たにフィールド名入力ボックス(806)を設ける。  FIG. 16 shows a logical expression creation auxiliary dialog in which a field name can be specified as a term. A field name input box (806) is newly provided before the term input box.

実施例5を実現する装置は、実施例1と同様に、検索画面(200)を表示するWEBブラウザ(100)と、検索画面(200)を保存する画面配信装置(300)と、論理式を解析するための論理式解析装置(400)と、論理式の該当件数を求めるための件数検索装置(500)と、論理式にて検索を行う検索装置(600)を備える。このうち検索画面(200)と論理式解析装置(400)の変更が必要である。  As in the first embodiment, the apparatus that implements the fifth embodiment includes a WEB browser (100) that displays the search screen (200), a screen distribution apparatus (300) that stores the search screen (200), and a logical expression. A logical expression analysis apparatus (400) for analysis, a number search apparatus (500) for obtaining the number of corresponding logical expressions, and a search apparatus (600) for performing a search using a logical expression are provided. Of these, the search screen (200) and logical expression analyzer (400) need to be changed.

利用者は、WEBブラウザ(100)を使って、画面配信装置(300)から検索画面(200)を取得する。WEBブラウザは検索画面(200)を表示する。利用者が検索画面(200)の検索テキストボックス(701)に論理式を入力し、702作成補助ボタンを押下すると、検索画面(200)が持つ論理式送信ロジック(201)を使って、検索テキストボックス(701)に入力された論理式を論理式解析装置(400)に非同期で送信する。  The user acquires the search screen (200) from the screen distribution device (300) using the WEB browser (100). The WEB browser displays a search screen (200). When a user inputs a logical expression into the search text box (701) of the search screen (200) and presses the 702 creation auxiliary button, the search text is searched using the logical expression transmission logic (201) of the search screen (200). The logical expression input in the box (701) is asynchronously transmitted to the logical expression analyzer (400).

論理式解析装置(400)は、二分木に構造化された論理式に変換する。二分木に構造化された論理式とは、二分木の各枝にフィールド名と検索キーワードを持ち、節に論理演算子を持つ二分木である。実施例5における論理式解析装置(400)の処理は実施例1とほぼ同じだが、各枝が検索キーワードだけでなく、フィールド名を持つ点が違う。実施例1の処理に加え、フィールド名が省略されていた場合はフィールド名の補完を行う。論理式解析装置(400)は、二分木に構造化された論理式を検索画面(200)に返却する。返却する形式はいずれでも構わないが、実施例4と同様にJSONを利用する。フィールドを指定可能にした論理式のJSON表記の例を図17に示す。  The logical expression analyzer (400) converts the logical expression into a logical expression structured in a binary tree. A logical expression structured in a binary tree is a binary tree having field names and search keywords in each branch of the binary tree and logical operators in clauses. The processing of the logical expression analyzer (400) in the fifth embodiment is almost the same as that in the first embodiment, except that each branch has not only a search keyword but also a field name. In addition to the processing of the first embodiment, if the field name is omitted, the field name is complemented. The logical expression analyzer (400) returns the logical expression structured in the binary tree to the search screen (200). Any format can be used, but JSON is used as in the fourth embodiment. FIG. 17 shows an example of a JSON expression of a logical expression in which a field can be specified.

検索画面(200)は返却された二分木に構造化された論理式を画面に表示する。このとき、フィールド名も検索キーワードの前に区切り文字で区切って表示するようにする。  The search screen (200) displays a logical expression structured on the returned binary tree on the screen. At this time, the field name is also displayed by being separated by a delimiter before the search keyword.

検索画面(200)は、二分木に構造化された論理式から整形された論理式を求め、求めた論理式を件数検索装置(500)に非同期で送信する。件数検索装置(500)は送信された論理式で検索を行い、該当件数を返却する。検索画面(200)は、返却された件数を全体論理式ラベル(707)、ターム表示ラベル(714)及び部分式表示ラベル(717)に表示する。  The search screen (200) obtains a logical expression shaped from a logical expression structured in a binary tree, and asynchronously transmits the obtained logical expression to the number search device (500). The number search device (500) performs a search using the transmitted logical expression and returns the number of cases. The search screen (200) displays the number of returned items on the whole logical expression label (707), the term display label (714), and the partial expression display label (717).

この論理式を解析し、件数を表示するまでの処理は、部分式文字列及び部分式ツリーの編集を行ったときも同様に行う。また、複数の部分式文字列及び部分式ツリーについて変更がある場合は、変更箇所毎に処理は非同期かつ並列で行う。  The processing from the analysis of the logical expression to the display of the number of cases is similarly performed when the partial expression character string and the partial expression tree are edited. In addition, when there are changes in a plurality of sub-expression character strings and sub-expression trees, processing is performed asynchronously and in parallel for each changed portion.

なお、前記の実施例のうち、いくつか、または全てを組み合わせてシステムを構成することは可能である。また、webシステムにおける実施例が主に記載されているが、javaによるアプレット、C言語等によるネイティブアプリケーションにて実施することも可能である。更に通信プロトコルとしてHTTPのみならず様々なプロトコルを適用することも可能である。  Note that it is possible to configure the system by combining some or all of the above-described embodiments. In addition, although the embodiment in the web system is mainly described, it is also possible to implement it by an applet by Java, a native application by C language or the like. Furthermore, it is possible to apply not only HTTP but also various protocols as communication protocols.

検索画面のイメージ図Image of search screen 論理式作成補助ダイアログを表示した検索画面のイメージ図Image of search screen displaying formula creation assistance dialog ANDを選択した直後の論理式作成補助ダイアログが表示された検索画面のイメージ図Image diagram of the search screen displaying the logical expression creation assistance dialog immediately after selecting AND ツリーを閉じた論理式作成補助ダイアログのイメージ図Image of the formula creation assistant dialog with the tree closed 論理式を編集可能な状態の論理式作成補助ダイアログのイメージ図Image diagram of the dialog box for creating a formula when the formula can be edited 条件を追加した論理式作成補助ダイアログのイメージ図Conceptual diagram of formula creation auxiliary dialog with added conditions 本発明を実現するために必要な構成要素のブロック図Block diagram of components necessary to implement the present invention 二分木に構造化された論理式の概念図Conceptual diagram of a logical expression structured in a binary tree JSONで表現した二分木に構造化された論理式の例Example of a logical expression structured in a binary tree expressed in JSON テキストボックスへの論理式の入力から、件数の表示までのシーケンスSequence from entering the formula in the text box to displaying the number of records 論理式保存ボタンを追加した検索画面のイメージ図Image of search screen with the Add Formula Save button 保存した論理式を挿入ボタンを追加した論理式作成補助ダイアログのイメージ図Image diagram of the formula creation auxiliary dialog with the button to insert a saved formula 保存済み論理式一覧表示ペインを表示した論理式作成補助ダイアログのイメージ図Image diagram of formula creation auxiliary dialog showing saved formula list display pane 部分式保存ボタンを設けた論理式作成補助ダイアログのイメージ図Image of logical formula creation support dialog with a partial formula save button 論理式をN分木に構造化するようにした場合の、論理式作成補助ダイアログのイメージ図Image of the formula creation auxiliary dialog when the formula is structured into an N-ary tree N分木に構造化された論理式の概念図Conceptual diagram of a logical expression structured in an N-ary tree JSONで表現した二分木に構造化された論理式の例Example of a logical expression structured in a binary tree expressed in JSON タームにフィールド名を指定できるようにした、論理式作成補助ダイアログのイメージ図Image diagram of the formula creation auxiliary dialog that allows field names to be specified for terms フィールドを指定可能にした論理式のJSON表記の例Example of JSON representation of logical expression that allows field specification 論理式を二分木に変換する処理のフローチャート(前半)Flow chart of processing to convert logical expression to binary tree (first half) 論理式を二分木に変換する処理のフローチャート(後半)Flow chart of processing to convert logical expression to binary tree (second half) 論理式をN分木に変換する処理のフローチャート(前半)Flow chart of processing to convert logical expression to N-ary tree (first half) 論理式をN分木に変換する処理のフローチャート(後半)Flow chart of processing to convert logical expression to N-ary tree (second half)

100 WEBブラウザ
200 検索画面
300 画面配信装置
400 論理式構文解析装置
500 件数検索装置
600 検索装置
900 部分式を保存する装置
DESCRIPTION OF SYMBOLS 100 WEB browser 200 Search screen 300 Screen distribution apparatus 400 Logical expression syntax analysis apparatus 500 Number search apparatus 600 Search apparatus 900 Apparatus for storing partial expressions

Claims (8)

データベースと、
項と、項を論理演算子で組み合わせた部分式文字列の組み合わせからなる論理式文字列を記憶する手段と、
前記論理式文字列を項、または、項を論理演算子で組み合わせた部分式ツリーの再帰構造からなる部分式ツリーとして分割する手段と、
前記部分式文字列を前記データベースにて検索した際の件数を記憶する件数記憶手段と、
前記部分式文字列、または、部分式ツリー、または、部分式文字列および部分式ツリーの両方を、前記件数記憶手段に記憶された件数を伴って表示する表示手段
を備えた情報処理装置において、
前記表示手段は、利用者の操作により部分式文字列を残し部分式ツリーを非表示とするか、部分式文字列とともに部分式ツリーを表示するかを選択する手段を備えた情報処理装置
A database,
Means for storing a logical expression character string composed of a combination of a term and a partial expression character string obtained by combining terms with logical operators;
Means for dividing the logical expression string as a sub-expression tree composed of a term or a recursive structure of a sub-expression tree obtained by combining terms with logical operators;
Number storage means for storing the number of cases when the partial expression character string is searched in the database;
In the information processing apparatus provided with display means for displaying the partial expression character string, or the partial expression tree, or both of the partial expression character string and the partial expression tree with the number of cases stored in the number storage means,
An information processing apparatus comprising: means for selecting whether to display the partial expression tree together with the partial expression character string, or to display the partial expression tree together with the partial expression character string by the user operation
前記表示手段は、部分式ツリーを2分木で表示することを特徴とする請求項1記載の情報処理装置  The information processing apparatus according to claim 1, wherein the display unit displays the partial expression tree as a binary tree. 前記表示手段は、部分式ツリーをN分木で表示することを特徴とする請求項1記載の情報処理装置  The information processing apparatus according to claim 1, wherein the display unit displays the partial expression tree as an N-ary tree. 前記表示手段が表示した部分式文字列を履歴として保存する手段を備え、前記表示手段は更に前記履歴として保存する手段から履歴を取得し表示することを特徴とする請求項1乃至3の情報処理装置  4. The information processing according to claim 1, further comprising means for storing the partial expression character string displayed by the display means as a history, wherein the display means further acquires and displays the history from the means for saving as the history. apparatus 前記表示手段が表示した部分式文字列を利用者が編集することができる請求項1乃至4の情報処理装置  5. The information processing apparatus according to claim 1, wherein a user can edit the partial expression character string displayed by the display means. 前記表示手段が表示した部分式ツリーを利用者が編集することができる請求項1乃至5の情報処理装置  6. The information processing apparatus according to claim 1, wherein a user can edit the partial expression tree displayed by the display means. データベースを有する情報処理装置において実行され、利用者の操作により論理式を編集するための編集プログラムであって、
前記プログラムは、
項と、項を論理演算子で組み合わせた部分式文字列の組み合わせからなる論理式文字列を記憶するステップと、
前記論理式文字列を項、または、項を論理演算子で組み合わせた部分式ツリーの再帰構造からなる部分式ツリーとして分割するステップと、
前記部分式文字列を前記データベースにて検索した際の件数を記憶するステップと、
前記部分式文字列、または、部分式ツリー、または、部分式文字列および部分式ツリーの両方を、前記件数記憶手段に記憶された件数を伴って表示するステップと、
利用者の操作により部分式文字列を残し部分式ツリーを非表示とするか、部分式文字列とともに部分式ツリーを表示するかを選択するステップを備えたことを特徴とする編集プログラム
An editing program that is executed in an information processing apparatus having a database and edits a logical expression by a user operation,
The program is
Storing a logical expression character string composed of a combination of a term and a subexpression character string obtained by combining terms with logical operators;
Splitting the logical expression string as a subexpression tree consisting of a term or a recursive structure of subexpression trees combining terms with logical operators;
Storing the number of cases when the partial expression character string is searched in the database;
Displaying the sub-expression string, or the sub-expression tree, or both the sub-expression string and the sub-expression tree, with the number of cases stored in the number storage means;
An editing program comprising a step for selecting whether to display a subexpression tree together with a subexpression character string, or to display a subexpression tree together with a subexpression character string by leaving a subexpression character string by a user operation
データベースを有する情報処理装置において、利用者の操作により論理式を編集するための論理式編集方法であって、
前記論理式編集方法は、
項と、項を論理演算子で組み合わせた部分式文字列の組み合わせからなる論理式文字列を記憶するステップと、
前記論理式文字列を項、または、項を論理演算子で組み合わせた部分式ツリーの再帰構造からなる部分式ツリーとして分割するステップと、
前記部分式文字列を前記データベースにて検索した際の件数を記憶するステップと、
前記部分式文字列、または、部分式ツリー、または、部分式文字列および部分式ツリーの両方を、前記件数記憶手段に記憶された件数を伴って表示するステップと、
利用者の操作により部分式文字列を残し部分式ツリーを非表示とするか、部分式文字列とともに部分式ツリーを表示するかを選択するステップからなることを特徴とする論理式編集方法。
A logical expression editing method for editing a logical expression by a user's operation in an information processing apparatus having a database,
The logical expression editing method is:
Storing a logical expression character string composed of a combination of a term and a subexpression character string obtained by combining terms with logical operators;
Splitting the logical expression string as a subexpression tree consisting of a term or a recursive structure of subexpression trees combining terms with logical operators;
Storing the number of cases when the partial expression character string is searched in the database;
Displaying the sub-expression string, or the sub-expression tree, or both the sub-expression string and the sub-expression tree, with the number of cases stored in the number storage means;
A logical expression editing method comprising a step of selecting whether to display a subexpression tree together with a subexpression character string, or to display a subexpression tree together with a subexpression character string by leaving a subexpression character string by a user operation.
JP2012243132A 2012-10-18 2012-10-18 Device for providing graphical interface for assisting preparation of logic formula Pending JP2014081905A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2012243132A JP2014081905A (en) 2012-10-18 2012-10-18 Device for providing graphical interface for assisting preparation of logic formula

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2012243132A JP2014081905A (en) 2012-10-18 2012-10-18 Device for providing graphical interface for assisting preparation of logic formula

Publications (1)

Publication Number Publication Date
JP2014081905A true JP2014081905A (en) 2014-05-08

Family

ID=50786011

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2012243132A Pending JP2014081905A (en) 2012-10-18 2012-10-18 Device for providing graphical interface for assisting preparation of logic formula

Country Status (1)

Country Link
JP (1) JP2014081905A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2016218805A (en) * 2015-05-21 2016-12-22 日本電気株式会社 Retrieval expression visualization device, retrieval system, retrieval expression visualization method, and retrieval expression visualization program
CN111767024A (en) * 2020-07-09 2020-10-13 北京猿力未来科技有限公司 Simple operation-oriented answering method and device
US11741375B2 (en) 2019-11-15 2023-08-29 International Business Machines Corporation Capturing the global structure of logical formulae with graph long short-term memory

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2016218805A (en) * 2015-05-21 2016-12-22 日本電気株式会社 Retrieval expression visualization device, retrieval system, retrieval expression visualization method, and retrieval expression visualization program
US11741375B2 (en) 2019-11-15 2023-08-29 International Business Machines Corporation Capturing the global structure of logical formulae with graph long short-term memory
CN111767024A (en) * 2020-07-09 2020-10-13 北京猿力未来科技有限公司 Simple operation-oriented answering method and device

Similar Documents

Publication Publication Date Title
CN107423053B (en) Web model packaging and distributed processing method for remote sensing image processing
Lehmann et al. Discovering unknown connections–the DBpedia relationship finder
US20080082962A1 (en) User interface for defining a text file transformation
JP4769005B2 (en) Information processing support system and information processing support program
US20140006913A1 (en) Visual template extraction
US20220164526A1 (en) Method And Apparatus For Structured Documents
US20150254211A1 (en) Interactive data manipulation using examples and natural language
US20210405977A1 (en) Method of converting source code in a universal hybrid programming environment
US7908586B1 (en) Collapse on content property
CN112052343A (en) Knowledge graph display method and device, electronic equipment and storage medium
JP2014081905A (en) Device for providing graphical interface for assisting preparation of logic formula
JP2013182410A (en) Business analysis design support device, business analysis design support method, and business analysis design support program
CN112182310B (en) Method for realizing built-in real-time search general tree-shaped component
EP3245599A1 (en) Storage and retrieval of structured content in unstructured user-editable content stores
US20230244218A1 (en) Data Extraction in Industrial Automation Systems
JP2015162004A (en) Inter-development document trace link generation support device and method and program
WO2007052680A1 (en) Document processing device and document processing method
US20090228678A1 (en) Mapping definition creation system and mapping definition creation program
EP1840765A1 (en) Process for extracting data from a web site
JP2005011301A (en) Document processor and document processing program
JP4411994B2 (en) Information processing device
Loskyll et al. UbisEditor 3.0: Collaborative ontology development on the Web
JP2016004539A (en) Text display program
CN116627986A (en) Form realization method and system capable of dynamically configuring display and search
JP5113303B2 (en) Information processing apparatus, program, storage medium, and display control method