JP3772105B2 - Database management apparatus, method, program, and recording medium - Google Patents

Database management apparatus, method, program, and recording medium Download PDF

Info

Publication number
JP3772105B2
JP3772105B2 JP2001288555A JP2001288555A JP3772105B2 JP 3772105 B2 JP3772105 B2 JP 3772105B2 JP 2001288555 A JP2001288555 A JP 2001288555A JP 2001288555 A JP2001288555 A JP 2001288555A JP 3772105 B2 JP3772105 B2 JP 3772105B2
Authority
JP
Japan
Prior art keywords
segment
execution
record
registered
specific
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.)
Expired - Fee Related
Application number
JP2001288555A
Other languages
Japanese (ja)
Other versions
JP2003099300A (en
Inventor
秀孝 小松
真 谷岡
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
MUFG Bank Ltd
Original Assignee
Bank of Tokyo Mitsubishi UFJ Trust Co
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 Bank of Tokyo Mitsubishi UFJ Trust Co filed Critical Bank of Tokyo Mitsubishi UFJ Trust Co
Priority to JP2001288555A priority Critical patent/JP3772105B2/en
Publication of JP2003099300A publication Critical patent/JP2003099300A/en
Application granted granted Critical
Publication of JP3772105B2 publication Critical patent/JP3772105B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Images

Description

【0001】
【発明の属する技術分野】
本発明はデータベース管理装置、方法、プログラム及び記録媒体に係り、特に、階層構造のデータベースを階層順テーブルに規定された順序でスキャンしながら所定処理を行うデータベース管理装置、該データベース管理装置に適用可能なデータベース管理方法、コンピュータをデータベース管理装置として機能させるためのプログラム、及び該プログラムが記録された記録媒体に関する。
【0002】
【従来の技術】
従来より、データベースに登録すべき情報項目を複数のセグメントに分け、これらのセグメントを階層的に関連付けた階層構造(木構造ともいう)のデータベースが知られている。階層構造のデータベースは、例えばデータベースに登録すべき多数件のデータのうち、特定の情報項目のデータ量が各件毎に一定していない等の場合にも、前記特定の情報項目に対応するセグメントのオカレンス(occurrence)の数を各件毎に増減させる等のように、登録すべきデータに応じてデータ構造を柔軟に変更することができるので、登録データ量に比してデータベースの規模(データベースを記憶するために必要な記憶手段の容量)を抑制できるという特長を有している。
【0003】
ところで、データベースの規模が大きくなると、データベースを複数の記憶装置(例えば直接アクセス記憶装置(DASD:Direct Access Storage Device))に分散させて記憶させる必要が生じてくる。階層構造のデータベースを複数の記憶装置に分散させて記憶させる場合には、例えば一部のセグメントのデータを別の記憶装置に記憶させる等のように、セグメントを単位としてデータを記憶させる記憶装置を分けると共に、個々のセグメントの論理的な関連付け及び個々のセグメントの物理的な記憶位置を規定する階層順テーブルが作成される。これにより、データベースの特定のセグメントのアクセスに際しても、階層順テーブルを参照することでアクセス対象のセグメントの物理的な記憶位置を認識することができる。
【0004】
また、データベースに記憶されているデータのうち不要になったデータを削除することは、データベースの規模が必要以上に肥大化することを回避し、データベースの維持に必要なコストを削減する観点から重要な処理である。しかし、階層構造を採用した金融機関のデータベースでは、例えば特定のセグメントについては解約後1年経過したら該当するデータを削除する必要があり、他の特定のセグメントについては予め設定された日付が到来したら該当するデータを削除する必要があり、別のセグメントについては削除しない等のように、データの削除基準は、データベースにデータを登録して利用する業務の要件に依り、個々のセグメントを単位として大きく相違している。
【0005】
そして、上記の削除処理は、例えば特定セグメントの各オカレンスに順にアクセスすると共に、アクセスしたオカレンスに登録されているデータが特定セグメントに対応する削除基準に合致しているか否かを判定し、削除基準に合致していた場合にはデータ(又はオカレンス自体)を削除する等の処理を行うプログラムを、各々異なる削除基準を個々のセグメント毎に用意することによって実現できるが、このようなプログラムの開発には多大な時間及びコストがかかると共に、プログラムの汎用性に乏しい(特定のデータベースにのみ利用可能で他のデータベースでは利用できない)という問題がある。
【0006】
このため、階層構造のデータベースにおける不要データの削除には、従来、個々のセグメントについての削除基準を削除基準テーブルに登録しておき、階層順テーブルを参照しながら階層構造のデータベースの個々のセグメントの各オカレンスに順にアクセスして逐一全量のデータを読み込み、対応する削除基準が削除基準テーブルに登録されている場合には、読み込んだデータが登録されている削除基準を満たしているか否かを判断し、削除基準を満たしていればデータ(オカレンス)を削除する、というアルゴリズムを用いていた。
【0007】
このアルゴリズムは、階層順テーブルを参照して処理対象のデータベースの構造(セグメントの数や個々のセグメントの論理的な関連付け等)を把握しながら処理対象のデータベースをスキャンしていくので、処理対象のデータベースの構造(セグメントの数や個々のセグメントの論理的な関連付け等)に応じてアルゴリズム自体を変更する必要がなく、削除基準テーブルの内容を書替えるのみで、階層構造を有する他のデータベースにおける不要データの削除にも利用することができ、汎用性に優れている。
【0008】
【発明が解決しようとする課題】
しかし、上記のアルゴリズムでは、特に処理対象のデータベースが多数のオカレンスが設けられた構造である場合に記憶装置からのデータの読み出し回数が膨大なものになり、不要データを削除する処理を完了するまでに非常に長い時間がかかるという問題があった。また、データベースのアクセス処理時間を短縮するために、データベースを複数の記憶装置に分散して記憶する構成を採用する場合もあるが、このような構成は、上記のアルゴリズムを適用して不要データを削除する際には却って不利となり、処理に膨大な時間がかかる(処理対象のデータベースの規模にも依存するが例えば数時間〜十数時間程度)ことになる。
【0009】
また、上述した問題はデータベースに対して不要データの削除を行う場合に限られるものではなく、データベースをスキャンし、データベースに記憶されているデータのうち所定の基準に合致するデータについてのみ、データの更新又は抽出を行う等の場合にも共通する問題であった。
【0010】
本発明は上記事実を考慮して成されたもので、データベースをスキャンして実行基準に合致するレコードに対して削除又は更新又はデータの抽出を行うことを短時間で完了させることができるデータベース管理装置、データベース管理方法、プログラム、及び記録媒体を得ることが目的である。
【0011】
【課題を解決するための手段】
上記目的を達成するために請求項1記載の発明に係るデータベース管理装置は、記憶装置に記憶された、互いに異なるカテゴリの情報を登録するための複数のセグメントが階層的に関連付けられた構造を有すると共に、特定カテゴリの情報を登録するためのレコードを各セグメントに任意の数作成可能とされた特定データベースをスキャンする際の、前記特定データベースの個々のセグメントを単位とするアクセス順序を規定する階層順テーブルを記憶する階層順テーブル記憶手段と、前記特定データベースの特定のセグメントの各レコードに対する、レコードを削除する削除処理、レコードに登録されているデータを更新する更新処理、及び、レコードに登録されているデータを抽出する抽出処理の何れかの処理の実行基準を、個々のセグメントを単位として、特定データベースの各セグメントのうちの任意のセグメントについて登録した実行基準テーブルを記憶する判断テーブル記憶手段と、特定データベースに対する前記何れかの処理の実行が指示されると、前記階層順テーブルに規定されたアクセス順序に従って個々のセグメントの各レコードに順にアクセスすると共に、アクセスしたレコードに対応するセグメントについての前記実行基準が前記実行基準テーブルに登録されている場合には、前記アクセスしたレコードが前記実行基準に合致しているか否か判断し、前記実行基準に合致していると判断した前記レコードに対してのみ前記実行が指示された処理を実行する処理手段と、を備えたデータベース管理装置であって、前記処理手段が特定データベースに対して前記実行が指示された処理を行う前に、特定データベースの各セグメントのうち、実行基準テーブルに実行基準が登録されておらず、かつ関連付けられた下位階層のセグメントが存在しないか又は関連付けられた下位階層の各セグメントも実行基準テーブルに実行基準が登録されていないセグメントを検索し、検索によって抽出されたセグメントを前記階層順テーブルから削除したアクセス順序テーブルを前記階層順テーブルと別に作成するテーブル作成手段を備え、前記処理手段は、前記テーブル作成手段によって作成されたアクセス順序テーブルを用いて特定データベースに対し前記実行が指示された処理を行うことを特徴としている。
【0012】
請求項1記載の発明では、記憶装置に記憶された、互いに異なるカテゴリの情報を登録するための複数のセグメントが階層的に関連付けられた構造を有すると共に、特定カテゴリの情報を登録するためのレコードを各セグメントに任意の数作成可能とされた特定データベースをスキャンする際の、特定データベースの個々のセグメントを単位とするアクセス順序を規定する階層順テーブルが階層順テーブル記憶手段に記憶されていると共に、特定データベースの特定のセグメントの各レコードに対する、レコードを削除する削除処理、レコードに登録されているデータを更新する更新処理、及び、レコードに登録されているデータを抽出する抽出処理の何れかの処理の実行基準を、個々のセグメントを単位として、特定データベースの各セグメントのうちの任意のセグメントについて登録した実行基準テーブルが判断テーブル記憶手段に記憶されている。
【0013】
なお、本発明に係る特定データベースは、単一の記憶装置に記憶されていてもよいし、複数の記憶装置に分散されて記憶されていてもよい。特定データベースが複数の記憶装置に分散されて記憶されている場合であっても、例えば個々のセグメントの物理的な記憶位置を階層順テーブルに記憶させておき、個々のセグメントをアクセスする際に階層順テーブルを参照して物理的な記憶位置を判断することにより、複数の記憶装置に分散されて記憶されている特定データベースを、単一の記憶装置に記憶されているデータベースと同様に取り扱うことができる。
【0014】
また、請求項1記載の発明では、特定データベースに対する前記削除処理、前記更新処理及び前記抽出処理の何れかの処理の実行が指示されると、処理手段により、階層順テーブルに規定されたアクセス順序に従って個々のセグメントの各レコードが順にアクセスされることで、特定データベースがスキャンされると共に、アクセスしたレコードに対応するセグメントについての実行基準が実行基準テーブルに登録されている場合には、アクセスしたレコードが実行基準に合致しているか否かが判断され、実行基準に合致していると判断したレコードに対してのみ前記実行が指示された処理が実行される。
【0015】
なお、本発明におけるレコードはオカレンスであってもよいし、特定のオカレンスと関連付けられて別の記憶装置に記憶されている特定のデータであってもよい。
【0016】
ここで、上記のようにデータベースをスキャンして実行基準に合致するレコードに対して実行が指示された処理を行う場合、データベースの規模が大きくなる(例えばセグメントやオカレンスの数が多くなる)に従って処理時間が大幅に増大する。これに対して請求項1記載の発明では、各レコードに対する所定処理の実行基準が、データベースの全てのセグメントについて登録されることは極めて稀であり、実行が指示された処理を行う可能性のないセグメントについては、実行基準テーブルに実行基準が登録されないことに着目し、処理手段が特定データベースに対して実行が指示された処理を行う前に、テーブル作成手段により、特定データベースの各セグメントのうち、実行基準テーブルに実行基準が登録されておらず、かつ関連付けられた下位階層のセグメントが存在しないか又は関連付けられた下位階層の各セグメントも実行基準テーブルに実行基準が登録されていないセグメントを検索し、検索によって抽出されたセグメントを階層順テーブルから削除したアクセス順序テーブルを階層順テーブルと別に作成し、処理手段は、テーブル作成手段によって作成されたアクセス順序テーブルを用いて特定データベースに対し実行が指示された処理を行うようにしている。
【0017】
処理手段は、階層順テーブルに規定されたアクセス順序に従って個々のセグメントの各レコードに順にアクセスするので、この階層順テーブルに代えて、実行基準テーブルに実行基準が登録されておらず、かつ関連付けられた下位階層のセグメントが存在しないか又は関連付けられた下位階層の各セグメントも実行基準テーブルに実行基準が登録されていないセグメントを階層順テーブルから削除したアクセス順序テーブルを用いることにより、上記の条件に合致するセグメントの各レコードは処理手段によるアクセス対象から除外されることになる。
【0018】
請求項1記載の発明において、実行基準テーブルに実行基準が登録されているか否かを判断したり、上記の条件に合致するセグメントの実行基準を削除したアクセス順序テーブルを作成することは、特定データベースのデータを実際に読み出したりすることなく実現することができ、処理自体も短時間で完了するので、請求項1記載の発明によれば、特定データベースのデータの読み出し回数を減少させることができ、データベースをスキャンして実行基準に合致するレコードに対して削除又は更新又はデータの抽出を行うことを短時間で完了させることができる。
【0019】
また、請求項1記載の発明に係る処理手段及びテーブル作成手段は、例えばコンピュータが所定のプログラムを実行することで実現することができるが、「階層順テーブルに規定されたアクセス順序に従って個々のセグメントの各レコードに順にアクセスすると共に、アクセスしたレコードに対応するセグメントについての実行基準が実行基準テーブルに登録されている場合には、アクセスしたレコードが実行基準に合致しているか否か判断し、実行基準に合致していると判断したレコードに対してのみ実行が指示された処理を実行する処理手段」に相当するプログラムが既に存在している環境であれば、処理手段については、実行基準テーブルに代えてアクセス順序テーブルを用いるように上記プログラムを変更するのみで実現することができ、テーブル作成手段に相当するプログラムを新規に開発するのみで、請求項1記載の発明に係るデータベース管理装置を得ることができるので、請求項1記載の発明に係るデータベース管理装置を得るためのプログラム開発に要する時間及びコストも削減することができる。
【0020】
請求項記載の発明に係るデータベース管理方法は、記憶装置に記憶された、互いに異なるカテゴリの情報を登録するための複数のセグメントが階層的に関連付けられた構造を有すると共に、特定カテゴリの情報を登録するためのレコードを各セグメントに任意の数作成可能とされた特定データベースをスキャンする際の、前記特定データベースの個々のセグメントを単位とするアクセス順序を規定する階層順テーブルを記憶する階層順テーブル記憶手段と、前記特定データベースの特定のセグメントの各レコードに対する、レコードを削除する削除処理、レコードに登録されているデータを更新する更新処理、及び、レコードに登録されているデータを抽出する抽出処理の何れかの処理の実行基準を、個々のセグメントを単位として、特定データベースの各セグメントのうちの任意のセグメントについて登録した実行基準テーブルを記憶する判断テーブル記憶手段と、が設けられたコンピュータが特定の処理を行うことで実現されるデータベース管理方法であって、前記特定の処理は、特定データベースの各セグメントのうち、実行基準テーブルに実行基準が登録されておらず、かつ関連付けられた下位階層のセグメントが存在しないか又は関連付けられた下位階層の各セグメントも実行基準テーブルに実行基準が登録されていないセグメントを検索し、検索によって抽出されたセグメントを前記階層順テーブルから削除したアクセス順序テーブルを前記階層順テーブルと別に作成する第1のステップ、特定データベースに対する前記何れかの処理の実行が指示されると、前記第1のステップで作成したアクセス順序テーブルに規定されたアクセス順序に従って個々のセグメントの各レコードに順にアクセスすると共に、アクセスしたレコードに対応するセグメントについての前記実行基準が前記実行基準テーブルに登録されている場合には、前記アクセスしたレコードが前記実行基準に合致しているか否か判断し、前記実行基準に合致していると判断した前記レコードに対してのみ前記実行が指示された処理を実行する第2のステップを含むことを特徴としているので、請求項1記載の発明と同様に、データベースをスキャンして実行基準に合致するレコードに対して削除又は更新又はデータの抽出を行うことを短時間で完了させることができる。
【0021】
請求項記載の発明に係るプログラムは、記憶装置に記憶された、互いに異なるカテゴリの情報を登録するための複数のセグメントが階層的に関連付けられた構造を有すると共に、特定カテゴリの情報を登録するためのレコードを各セグメントに任意の数作成可能とされた特定データベースをスキャンする際の、前記特定データベースの個々のセグメントを単位とするアクセス順序を規定する階層順テーブルを記憶する階層順テーブル記憶手段と、前記特定データベースの特定のセグメントの各レコードに対する、レコードを削除する削除処理、レコードに登録されているデータを更新する更新処理、及び、レコードに登録されているデータを抽出する抽出処理の何れかの処理の実行基準を、個々のセグメントを単位として、特定データベースの各セグメントのうちの任意のセグメントについて登録した実行基準テーブルを記憶する判断テーブル記憶手段と、が設けられたコンピュータに特定の処理を実行させるためのプログラムであって、前記特定の処理は、特定データベースの各セグメントのうち、実行基準テーブルに実行基準が登録されておらず、かつ関連付けられた下位階層のセグメントが存在しないか又は関連付けられた下位階層の各セグメントも実行基準テーブルに実行基準が登録されていないセグメントを検索し、検索によって抽出されたセグメントを前記階層順テーブルから削除したアクセス順序テーブルを前記階層順テーブルと別に作成する第1のステップ、特定データベースに対する前記何れかの処理の実行が指示されると、前記第1のステップで作成したアクセス順序テーブルに規定されたアクセス順序に従って個々のセグメントの各レコードに順にアクセスすると共に、アクセスしたレコードに対応するセグメントについての前記実行基準が前記実行基準テーブルに登録されている場合には、前記アクセスしたレコードが前記実行基準に合致しているか否か判断し、前記実行基準に合致していると判断した前記レコードに対してのみ前記実行が指示された処理を実行する第2のステップを含むことを特徴としている。
【0022】
請求項記載の発明に係るプログラムは、上記第1及び第2のステップを含む特定の処理、すなわちコンピュータを、請求項1に記載のデータベース管理装置として機能させるためのプログラムであるので、コンピュータが前記プログラムを実行することにより、請求項1記載の発明と同様に、データベースをスキャンして実行基準に合致するレコードに対して削除又は更新又はデータの抽出を行うことを短時間で完了させることができる。
【0023】
請求項記載の発明に係る記録媒体は、記憶装置に記憶された、互いに異なるカテゴリの情報を登録するための複数のセグメントが階層的に関連付けられた構造を有すると共に、特定カテゴリの情報を登録するためのレコードを各セグメントに任意の数作成可能とされた特定データベースをスキャンする際の、前記特定データベースの個々のセグメントを単位とするアクセス順序を規定する階層順テーブルを記憶する階層順テーブル記憶手段と、前記特定データベースの特定のセグメントの各レコードに対する、レコードを削除する削除処理、レコードに登録されているデータを更新する更新処理、及び、レコードに登録されているデータを抽出する抽出処理の何れかの処理の実行基準を、個々のセグメントを単位として、特定データベースの各セグメントのうちの任意のセグメントについて登録した実行基準テーブルを記憶する判断テーブル記憶手段と、が設けられたコンピュータに特定の処理を実行させるためのプログラムが記録された記録媒体であって、前記特定の処理は、特定データベースの各セグメントのうち、実行基準テーブルに実行基準が登録されておらず、かつ関連付けられた下位階層のセグメントが存在しないか又は関連付けられた下位階層の各セグメントも実行基準テーブルに実行基準が登録されていないセグメントを検索し、検索によって抽出されたセグメントを前記階層順テーブルから削除したアクセス順序テーブルを前記階層順テーブルと別に作成する第1のステップ、特定データベースに対する前記何れかの処理の実行が指示されると、前記第1のステップで作成したアクセス順序テーブルに規定されたアクセス順序に従って個々のセグメントの各レコードに順にアクセスすると共に、アクセスしたレコードに対応するセグメントについての前記実行基準が前記実行基準テーブルに登録されている場合には、前記アクセスしたレコードが前記実行基準に合致しているか否か判断し、前記実行基準に合致していると判断した前記レコードに対してのみ前記実行が指示された処理を実行する第2のステップを含むことを特徴としている。
【0024】
請求項記載の発明に係る記録媒体には、上記第1及び第2のステップを含む処理、すなわちコンピュータを、請求項1に記載のデータベース管理装置として機能させるためのプログラムが記録されているので、コンピュータが前記記録媒体に記録されたプログラムを読み出して実行することにより、請求項1記載の発明と同様に、データベースをスキャンして実行基準に合致するレコードに対して削除又は更新又はデータの抽出を行うことを短時間で完了させることができる。
【0025】
【発明の実施の形態】
以下、図面を参照して本発明の実施形態の一例を詳細に説明する。図1には、金融機関の各種業務を支援するために金融機関に設置されたコンピュータ・システム10が示されている。コンピュータ・システム10は、本発明に係るデータベース管理装置としての機能を兼ね備えたホスト・コンピュータ12を含んで構成されている。
【0026】
金融機関の各部署にはクライアントPC14又は専用端末16が多数台設置されており、それぞれのクライアントPC14は通信制御用サーバ18及びイントラネット20を介してホスト・コンピュータ12に各々接続されている。また、それぞれの専用端末16は、ターミナル・アダプタ(TA)22、モデム24、公衆電話網等から成る公衆通信網26を介してホスト・コンピュータ12に各々接続されている。なお、図1ではホスト・コンピュータ12を単一のコンピュータとして示しているが、これに限定されるものではなく、複数台のコンピュータで構成しても良いことは言うまでもない。
【0027】
ホスト・コンピュータ12はワークステーション又は汎用の大型コンピュータから成り、CPU12A、ROM12B、RAM12C、入出力ポート12Dを備え、これらがアドレスバス、データバス、制御バス等のバス12Eを介して互いに接続されて構成されている。入出力ポート12Dには、モデム28を介して公衆通信網26に接続され公衆通信網26を介して専用端末16と通信を行うための通信制御装置30、ディスプレイ32、マウス34、キーボード36、イントラネット20を介してクライアントPC14と通信を行うための通信制御用サーバ38、本発明に係る記憶装置としてのHDD40、及びCD−ROMからの情報の読み出しを行うCD−ROMドライブ42が各々接続されている。
【0028】
ホスト・コンピュータ12のHDD40には、本発明に係る特定データベースに対応する預金明細照会データベース(預金明細照会DB)と、該預金明細照会DBの階層順テーブル及び削除基準テーブルが記憶されている(何れも詳細は後述)と共に、後述するデータベース(DB)スキャン処理を含むDB管理処理をCPU12Aによって実行するためのDB管理プログラム(DB管理システムを実現するためのプログラム)がHDD40にインストールされており、更にオペレーティング・システム(OS)のプログラムもインストールされている。
【0029】
なお、HDD40に記憶されている階層順テーブルは本発明の階層順テーブルに、削除基準テーブルは本発明の実行基準テーブルに対応しており、HDD40は請求項1等に記載の階層順テーブル記憶手段及び判断テーブル記憶手段にも対応している。
【0030】
DB管理プログラムをホスト・コンピュータ12にインストール(移入)するには幾つかの方法があるが、例えばDB管理プログラムをセットアッププログラムと共にCD−ROM50に記録しておき、CD−ROM50をホスト・コンピュータ12のCD−ROMドライブ42にセットし、CPU12Aに対して前記セットアッププログラムの実行を指示すれば、CD−ROM50からDB管理プログラムが順に読み出され、読み出されたDB管理プログラムがHDD40に順に書き込まれることで、DB管理プログラムのインストールが行われる。
【0031】
なお、DB管理プログラムは請求項に記載のプログラムに対応していると共に、請求項に記載の記録媒体に記録されているプログラムにも対応しており、上記態様におけるCD−ROM50は請求項に記載の記録媒体に対応している。
【0032】
また、上記のようにCD−ROM50を用いてDB管理プログラムをインストールすることに代えて、DB管理プログラムが、当初は公衆通信網26やイントラネット20、或いはその他のコンピュータ・ネットワーク(例えばLAN、インターネット、無線通信ネットワーク等)を介してホスト・コンピュータ12と接続される他の情報処理機器(例えばネットワークサーバ)の記憶装置に記憶されており、ホスト・コンピュータ12が前記情報処理機器と通信することで、前記情報処理機器からホスト・コンピュータ12へ伝送され、HDD40にインストールされてホスト・コンピュータ12で実行される構成を採用してもよい。
【0033】
次に本実施形態の作用を説明する。金融機関は顧客に対してエレクトロニック・バンキング(EB)と称するサービスを提供している。このEBは、家庭や企業に設置されたコンピュータ(又は専用端末)を顧客が操作することで、預金の残高照会、入出金照会、口座振り込み、振り替え等の各種サービスを顧客に対してオンラインで提供するものである。ホスト・コンピュータ12のHDD40に記憶されている預金明細照会DBは、上記のEB業務を支援するEBシステムに対し、預金為替システムが支援する預金為替業務によって発生した資金の移動の明細を表す情報(預金明細情報)を受け渡すことを目的として、預金明細情報を保有するデータベースである。
【0034】
本実施形態に係る預金明細照会DBは、例として図6に示すように、預金明細情報を構成する各種情報のうち予め定められた互いに異なるカテゴリの情報を登録するための複数のセグメントが、階層的に関連付けられた構造を有している。例えば図6に示すDBは、セグメントA〜セグメントHの8種類のセグメントから成り、最上位の第1階層にはセグメントA(ルートセグメント)、第2階層にはセグメントB,C,F、第3階層にはセグメントD,E,G,Hが各々設けられ、セグメントB,C,FはセグメントAと関連付けされ、セグメントD,EはセグメントCと関連付けされ、セグメントG,HはセグメントFと関連付けされた構造を有している。
【0035】
また、各セグメントは任意の数のオカレンスを作成可能とされており、預金明細照会DBに記憶する預金明細情報のうちの特定カテゴリの情報のデータ量が大きい等の場合には、預金明細情報の登録に際し、特定カテゴリの情報を登録するためのセグメントとして複数のオカレンスが作成され、作成されたオカレンスに特定カテゴリの情報が各々登録される。
【0036】
例えば図6では、セグメントBにはオカレンスB1,B2が、セグメントCにはオカレンスC1,C2が、セグメントDにはオカレンスD1〜D3が、セグメントEにはオカレンスE1〜E3が、セグメントFにはオカレンスF1,F2が、セグメントGにはオカレンスG1〜G3が、セグメントHにはオカレンスH1,H2が各々作成されており、オカレンスD1,E1,E2はオカレンスC1と関連付けされ、オカレンスD2,D3,E3はオカレンスと関連付けされ、オカレンスG1,H1,H2はオカレンスF1と関連付けされ、オカレンスG2,G3はオカレンスF2と関連付けされている。
【0037】
また、預金明細情報はデータ量が膨大であるため、HDD40は実際には複数のHDDから構成されており(例として図6に示すHDD40A,40Bを参照)、預金明細情報のうちの一部の情報(明細情報)は、預金明細照会DB本体が記憶されているHDD(図6の例ではHDD40A)と別のHDD(図6の例ではHDD40B)に記憶されている。例えば図6では、明細情報E1〜E3がHDD40Bに記憶されており、HDD40Aに記憶されている預金明細照会DB本体のうちセグメントEの各オカレンスE1〜E3には、明細情報E1〜E3を指し示すインデックス情報iDXが登録されている。
【0038】
一方、階層順テーブルは、例として図7(A)に示すように、預金明細照会DBを構成する全てのセグメントについて、階層レベルと物理アドレス(物理的な記憶位置)が各々登録されて構成されている。階層順テーブルへの各セグメントの登録順序は各セグメントの関連付けを考慮して定められており、階層順テーブルを参照することで各セグメントの関連付けを認識できるようになっている。すなわち、階層順テーブルに登録されている階層レベルが2以下(ルートセグメント以外)の各セグメントは、階層順テーブルにおける各セグメントの登録位置から上側に辿ったときに、最初に出現する、各セグメントよりも階層レベルが1階層上位のセグメント(例えばセグメントEであればセグメントC)に関連付けされていると判断することができる。
【0039】
また、削除基準テーブルは、預金明細照会DBを構成するセグメントのうち、対応するオカレンスを削除する可能性のあるセグメントについて、オカレンスを削除するか否かの基準を登録したテーブルである。例として図6では「●」「×」の記号を付して示すように、セグメントB,Gについて削除基準テーブルに削除基準が登録されている。
【0040】
ホスト・コンピュータ12の電源が投入されると、図2に示すように、OSのプログラムやDB管理プログラム、通信管理ソフト等のプログラムがメインメモリ(RAM12C)にロードされ、これらのプログラムが実行されることで、OSやDB管理システムが稼働する。また、DB管理プログラムのロード時に、メインメモリの記憶領域の一部が共通領域(図2参照)として確保され、階層順テーブル及び削除基準テーブルがHDD40から共通領域にコピーされる。共通領域にコピーされた階層順テーブル及び削除基準テーブルは、ホスト・コンピュータ12の電源が投入されている間、共通領域に常駐する。
【0041】
次に図3のフローチャートを参照し、本発明に係るデータベース管理方法が適用されたDBスキャン処理について説明する。このDBスキャン処理は、預金明細照会DBの不要データ削除等のように、預金明細照会DBをスキャンしながら行うべき複数種の処理の何れかの実行が指示された場合に実行される処理であり、実行すべき処理をオペレータが所定時刻に実行すべきジョブとして予め登録しておくことにより、所定時刻が到来すると実行される。
【0042】
DBスキャン処理はホスト・コンピュータ12のCPU12AがDB管理プログラムの一部であるDBスキャンプログラムを実行することによって実現され、まず図2に示すように、メインメモリの記憶領域の一部が、DBスキャンプログラムを稼働するための領域として確保された後に、この領域を使用して図3に示す一連の処理が順次実行される。なお、以下では図6に示すデータベース構造を用いて処理のアルゴリズムを説明する。
【0043】
ステップ100では、実行が指示された処理が不要データの削除か否か判定する。不要データの削除を行う場合には、ステップ100の判定が肯定されてステップ102へ移行し、以下で説明する階層順テーブル圧縮処理を行う。なお、実行が指示された処理が不要データの削除以外の処理であった場合には、ステップ100の判定が否定されることで、階層順テーブル圧縮処理を行うことなくステップ104へ移行する。また、階層順テーブル圧縮処理は請求項1に記載のテーブル作成手段に対応しており、請求項2〜請求項に記載の第1のステップに相当する処理である。
【0044】
図4に示すように、階層順テーブル圧縮処理では、ステップ170において、メインメモリの共通領域に記憶(常駐)している階層順テーブルの1番目及び2番目のエントリのセグメントを、メインメモリのDBスキャンプログラム稼働領域に設けられたワークエリア(図2に示す削除処理用階層順テーブル作成領域)の1番目及び2番目の領域に各々コピーする。なお、以下では便宜的に、階層順テーブルをテーブルAと称し、階層順テーブル圧縮処理によってワークエリアに作成される削除処理用階層順テーブルをテーブルBと称する。
【0045】
次のステップ172では、テーブルBの終わりを意味する所定の情報(ストッパと称する)をテーブルBの3番目の領域に書き込み、ステップ174では、変数i,j,kの初期値として、変数iに3を、変数jに1を、変数kに2を代入する。なお、変数iはテーブルAから読み出すセグメントの位置を、変数jはテーブルBに登録されているセグメントのうち削除(上書き)しないことが確定した最終セグメントの位置を、変数kはテーブルBの最終エントリの位置を表している。ステップ176ではテーブルA(階層順テーブル)のi番目のエントリのセグメントの情報(階層レベル等)を参照する。
【0046】
ステップ178では変数kの値を変数sに代入し、次のステップ180では、テーブルAのi番目のエントリのセグメントは、テーブルBのs番目のエントリのセグメントよりも階層レベルが下位であるか否か判定する。判定が肯定された場合にはステップ192へ移行するが、判定が否定された場合にはステップ182へ移行し、テーブルBのs番目のエントリのセグメントの削除基準が削除基準テーブルに登録されているか否かを検索する。またステップ184では、ステップ182の検索によって該当する削除基準が抽出されたか否か判定する。
【0047】
判定が肯定された場合にはステップ190へ移行し、変数sの値を変数jに打入した後にステップ192へ移行する。また、ステップ184の判定が否定された場合にはステップ186へ移行し、変数sの値を1だけデクリメントする。次のステップ188では、変数sの値が変数jの値に等しいか否か判定する。判定が否定された場合にはステップ180に戻り、ステップ180以降を繰り返すが、判定が肯定された場合にはステップ192へ移行する。従って、ステップ180、ステップ184、ステップ188の何れかの判定が肯定される迄の間は、ステップ180〜ステップ188が繰り返されることになる。
【0048】
ステップ192では、テーブルAのi番目のエントリのセグメントをテーブルBのs+1番目の領域にコピーし、次のステップ194ではテーブルBのs+2番目の領域にストッパを書き込む。ステップ196では変数sに1を加算した値を変数kに代入する。また、次のステップ198では、テーブルAのi番目のエントリのセグメントがテーブルAの最終エントリに相当するセグメントか否か判定する。判定が否定された場合にはステップ200において、変数iの値を1だけインクリメントした後にステップ176に戻る。従って、ステップ198の判定が肯定される迄の間はステップ176〜ステップ200が繰り返されることになる。
【0049】
上述したステップ176〜200のループを、図7(A)に示す階層順テーブルを例に更に説明すると、前記ループを最初に実行するときには、テーブルBにはセグメントA,Bがコピーされており、i=3,j=1,k=2(=s)であることから、テーブルA(階層順テーブル)のi番目のエントリはセグメントC、テーブルB(削除処理用階層順テーブル)のs番目のエントリはセグメントBとなる。
【0050】
セグメントB,Cは何れも階層レベルが「2」であるのでステップ180の判定は否定されるが、セグメントBは、図6において「●」の記号が付されている(オカレンスB1参照)ことからも明らかなように、削除基準テーブルに削除基準が登録されているのでステップ184の判定が肯定される。これにより、変数jの値が2になり(ステップ190)、セグメントBを削除(上書き)しないことが確定する。また、テーブルBの3番目の領域にセグメントCが、4番目の領域にストッパが書き込まれると共に、変数kの値が3になり(ステップ192〜ステップ196)、ステップ198,200を経てステップ176に戻る。
【0051】
次は、i=4,j=2,k=3(=s)であることから、テーブルAのi番目のエントリはセグメントD、テーブルBのs番目のエントリはセグメントCとなる。セグメントDの階層レベルは「3」であり、セグメントCよりも階層レベルが下位であるのでステップ180の判定が肯定され、テーブルBの4番目の領域にセグメントDが、5番目の領域にストッパが書き込まれると共に、変数kの値が4になり(ステップ192〜ステップ196)、ステップ198,200を経てステップ176に戻る。
【0052】
次は、i=4,j=2,k=4(=s)であるため、テーブルAのi番目のエントリはセグメントE、テーブルBのs番目のエントリはセグメントDとなる。セグメントD,Eは何れも階層レベルが「3」であるのでステップ180の判定は否定される。またセグメントDは、図6において「×」の記号が付されている(オカレンスD1参照)ことからも明らかなように、削除基準テーブルに削除基準が登録されていないので、ステップ184の判定が否定され、変数sが1だけデクリメントされて3になる(ステップ186)が、j≠s(j=2)であるのでステップ188の判定が否定され、ステップ180に戻る。
【0053】
s=3になったため、テーブルAのi番目のエントリはセグメントEのままであるのに対し、テーブルBのs番目のエントリはセグメントCとなるが、セグメントEはセグメントCよりも階層レベルが下位であるのでステップ180の判定が肯定され、テーブルBの4番目の領域(すなわちセグメントDが書き込まれていた領域)にセグメントEが、5番目の領域にストッパが書き込まれると共に、変数kの値が4になり(ステップ192〜ステップ196)、ステップ198,200を経てステップ176に戻る。
【0054】
次は、i=5,j=2,k=4(=s)であるため、テーブルAのi番目のエントリはセグメントF、テーブルBのs番目のエントリはセグメントEとなる。セグメントFは階層レベルが「2」であり、セグメントEよりも上位であるのでステップ180の判定は否定される。またセグメントEは、図6において「×」の記号が付されている(オカレンスE1参照)ことからも明らかなように、削除基準テーブルに削除基準が登録されていないので、ステップ184の判定が否定され、変数sが1だけデクリメントされて3になる(ステップ186)が、j≠s(j=2)であるのでステップ188の判定が否定され、ステップ180に戻る。
【0055】
s=3になったため、テーブルAのi番目のエントリはセグメントのままであるのに対し、テーブルBのs番目のエントリはセグメントCとなるが、セグメントEはセグメントCよりも階層レベルが下位であるのでステップ180の判定が肯定され、テーブルBの4番目の領域(すなわちセグメントDが書き込まれていた領域)にセグメントEが、5番目の領域にストッパが書き込まれると共に、変数kの値が4になり(ステップ192〜ステップ196)、ステップ198,200を経てステップ176に戻る。
【0056】
次は、i=6,j=2,k=3(=s)であることから、テーブルAのi番目のエントリはセグメントG、テーブルBのs番目のエントリはセグメントFとなる。セグメントGの階層レベルは「3」であり、セグメントFよりも階層レベルが下位であるのでステップ180の判定が肯定され、テーブルBの4番目の領域にセグメントGが、5番目の領域にストッパが書き込まれると共に、変数kの値が4になり(ステップ192〜ステップ196)、ステップ198,200を経てステップ176に戻る。
【0057】
次は、i=7,j=2,k=4(=s)であることから、テーブルAのi番目のエントリはセグメントH、テーブルBのs番目のエントリはセグメントGとなる。セグメントHはセグメントGと階層レベルが同位であるのでステップ180の判定が否定される。セグメントGは、図6において「●」の記号が付されている(オカレンスG1参照)ことからも明らかなように、削除基準テーブルに削除基準が登録されているのでステップ184の判定が肯定される。これにより、変数jの値が4になり(ステップ190)、セグメントF及びセグメントGを削除(上書き)しないことが確定する。
【0058】
なお、セグメントFは削除基準テーブルに削除基準が登録されていないが、関連付けられた下位階層のセグメントGの削除基準が削除基準テーブルに登録されているために、削除(上書き)の対象から除外される。そして、テーブルBの5番目の領域にセグメントHが、6番目の領域にストッパが書き込まれ、変数kの値が5になる(ステップ192〜ステップ196)。
【0059】
上記のループを変数iが階層順テーブルの最終エントリに相当する値になるまで繰り返すと、ステップ198の判定が否定されてステップ202へ移行し、変数kの値を変数sに代入する。次のステップ204では、テーブルBのs番目のエントリのセグメントの削除基準が削除基準テーブルに登録されているか否かを検索する。またステップ206では、ステップ204の検索によって該当する削除基準が抽出されたか否か判定する。
【0060】
判定が肯定された場合には階層順テーブル圧縮処理を終了するが、判定が否定された場合はステップ208へ移行し、テーブルBのs番目の領域にストッパを書き込むことで、当該セグメントをテーブルBから削除する。次のステップ210では変数sを1だけデクリメントし、ステップ212では変数sの値が変数jの値に一致したか否か判定する。判定が否定された場合にはステップ204に戻り、判定が肯定された場合には階層順テーブル圧縮処理を終了する。
【0061】
これにより、例えば図7(A)の階層順テーブルにおける最終エントリがセグメントHであるとすると、セグメントHは削除基準テーブルに削除基準が登録されていないので、先のステップ192でテーブルBに一旦書き込まれた後に、ストッパで上書きされることでテーブルBから削除され、例えば図7(A)に示す階層順テーブルから、セグメントC,D,E,Hが削除されて圧縮された階層順テーブル(図7(B)参照:本発明のアクセス順序テーブルに相当)が得られることになる。上記の階層順テーブル圧縮処理が終了すると、DBスキャン処理(図3)のステップ104へ移行する。
【0062】
上述した階層順テーブル圧縮処理は、例えば階層順テーブルをスキャンしながら削除対象のセグメントを記憶していき、最終エントリまでスキャンした後に、階層順テーブルを再度スキャンし、削除対象でないと判断したセグメントのみをワークエリアに順にコピーすることで削除処理用の階層順テーブルを作成するアルゴリズムによっても実現できるが、このアルゴリズムでは階層順テーブルを2回スキャンする必要があるので削除処理用の階層順テーブルの作成に時間がかかるという欠点がある。
【0063】
これに対し、図4に示したアルゴリズムでは、階層順テーブに登録されているセグメントを順にスキャンし、各セグメントをワークエリアに順にコピーする際に、既にワークエリアにコピーしたセグメントのうち削除可能なセグメントが有るか否かを判定し、削除可能と判断したセグメントをコピーするセグメントで上書きすることで削除処理用の階層順テーブルを作成するので、階層順テーブルのスキャンが1回で済み、削除処理用の階層順テーブルをより短時間で作成することができる。
【0064】
一方、DBスキャン処理では階層順テーブルを用いて処理が行われるが、ステップ100の判定が肯定されて階層順テーブル圧縮処理が行われた場合には、階層順テーブル圧縮処理で生成(圧縮)された階層順テーブル(すなわち本発明に係るアクセス順序テーブル)を用いて処理が行われる。また。DBスキャン処理のステップ104以降は、請求項1に記載の処理手段に対応しており、請求項2〜請求項に記載の第2のステップに相当する処理である。
【0065】
ステップ104では変数nに1(初期値)を代入する。ステップ106では、階層順テーブルの最上位エントリのセグメント(図7の例ではルートセグメントであるセグメントA)の各オカレンスの中に、後述するステップ112以降の処理を行っていないオカレンスが存在しているか否か検索し、次のステップ110では、上記の検索によって該当するオカンレンスが抽出されたか否か判定する。
【0066】
該当するオカレンス(例えば図6に示すオカレンスA1)が抽出された場合には、ステップ110の判定が肯定されてステップ112へ移行し、ステップ108の検索によって抽出されたオカレンスを親n(この場合は「親1」)として記憶する。また、ステップ114では変数Xn(この場合はX1)に1(初期値)を代入する。
【0067】
ステップ116では、階層順テーブル上で親nのセグメントからXn番目のエントリを参照する。ステップ118では該当エントリが存在しているか否か判定する。判定が肯定された場合にはステップ120へ移行し、セグメントα(任意のセグメントを指し示すポインタ)として該当エントリのセグメントを設定する。次のステップ122では、セグメントαは親nのセグメントより階層レベルが下位か否か判定する。判定が肯定された場合にはステップ124へ移行する。ステップ124では、親nと関連付けられたセグメントαの各オカレンスのうち未処理のオカレンスを検索し、次のステップ126では、ステップ124の検索によって該当するオカンレンスが抽出されたか否か判定する。
【0068】
ステップ126の判定が否定された場合にはステップ142へ移行し、変数Xnを1だけインクリメントしてステップ116に戻る。一方、ステップ126の判定が肯定された場合にはステップ127へ移行し、該当オカレンスのデータを預金明細照会DBから読み出した後に、ステップ128でDB操作処理を行う。なお、このDB操作処理については後述する。次のステップ130では変数nの値を1だけインクリメントし、ステップ132では、ステップ128のDB操作処理を行ったオカレンスを親nとして記憶し、ステップ134では変数Xnに1(初期値)を代入する。
【0069】
ステップ136では、該当オカンレンスはインデックス情報iDXが登録されたオカレンス(例えば図6に(iDX)と表記されたオカレンスE1〜オカレンスE3)か否か判定する。判定が否定された場合には、何ら処理を行うことなくステップ116に戻る。また、判定が肯定された場合にはステップ138へ移行し、該当オカレンスに登録されているインデックス情報iDXに基づいて、該当オカレンスと関連付けられた明細情報を預金明細照会DBから読み出す。そして次のステップ140では、読み出した明細情報に対して前述のDB操作処理を行った後に、ステップ116に戻る。
【0070】
また、ステップ118又はステップ122の判定が否定された場合にはステップ144へ移行し、変数nを1だけデクリメントする。次のステップ146では、ステップ144のデクリメントによってnよりも小さくなったか否か判定する。判定が否定された場合にはステップ116へ戻り、判定が肯定された場合にはステップ106に戻る。
【0071】
上述したステップ112〜146を、図6に示すDB構造に対して図7(A)に示す階層順テーブルを使用してスキャンを行う場合を例にとり、更に説明すると、まずステップ112でオカレンスA1が親1として設定されると共に、ステップ114で変数X1に1が代入された後に、ステップ116の検索により、親1(オカレンスA1)のセグメント(セグメントA)からX1(=1)番目のセグメントとしてセグメントBが抽出される。セグメントBは親1のセグメント(セグメントA)よりも下位であるためステップ122の判定が肯定され、ステップ126の検索により、親1(オカレンスA1)と関連付けられたセグメントBの未処理オカレンスとしてオカレンスB1が抽出される。
【0072】
オカレンスB1に対してDB操作処理(ステップ128)が行われた後に、オカレンスB1と関連付けられた下位のオカレンスを検索するために、オカレンスB1が親2とされ、変数X2が1に初期設定されて(ステップ130〜ステップ134)ステップ116に戻る。
【0073】
続いて、ステップ116の検索により、親2(オカレンスB1)のセグメント(セグメントB)からX2(=1)番目のセグメントとしてセグメントCが抽出されるが、セグメントCは親2のセグメント(セグメントB)と階層レベルが同位であり、オカレンスB1と関連付けられた下位のオカレンスは存在しないと判断できるので、ステップ122の判定が否定されて変数nが1に戻され、ステップ116に戻る。
【0074】
次に、ステップ116の検索により、オカレンスA1からX1(=1)番目のセグメントとして再度セグメントBが抽出され、ステップ124の検索によってオカレンスB2が抽出される。そして、前述のオカレンスB1と同様に、オカレンスB2に対してDB操作処理(ステップ128)が行われた後に、オカレンスB2と関連付けられた下位のオカレンスを検索するために、オカレンスB2が親2とされ、変数X2が1とされてステップ116に戻り、ステップ116の検索により、親2(オカレンスB2)のセグメント(セグメントB)からX2(=1)番目のセグメントとしてセグメントCが抽出されるが、セグメントCは親2のセグメント(セグメントB)と階層レベルが同位のため、ステップ122の判定が否定されて変数nが1に戻され、ステップ116に戻る。
【0075】
続いて、ステップ116の検索により、オカレンスA1からX1(=1)番目のセグメントとして再度セグメントBが抽出されるが、オカレンスA1と関連付けられたセグメントBの未処理のオカレンスは存在していないので、ステップ126の判定が否定され、変数X1が2とされてステップ116に戻る。
【0076】
次に、ステップ116の検索により、オカレンスA1からX1(=2)番目のセグメントとして再度セグメントCが抽出され、セグメントCは親1のセグメント(セグメントA)よりも階層レベルが下位であるためステップ122の判定が肯定され、ステップ124の検索によってオカレンスC1が抽出される。そして、オカレンスC1に対してDB操作処理(ステップ128)が行われた後に、オカレンスC1と関連付けられた下位のオカレンスを検索するために、オカレンスC1が親2とされ、変数X2が1とされてステップ116に戻る。
【0077】
続いて、ステップ116の検索により、親2(オカレンスC1)のセグメント(セグメントC)からX2(=1)番目のセグメントとしてセグメントDが抽出される。
【0078】
そして、以下同様にして、DB操作処理の対象のオカレンスが抽出され抽出されたオカレンスに対してDB操作処理(ステップ128)を行った後に、抽出されたオカレンスと関連付けられた下位のオカレンスが存在しているか否かが検索され、該当するオカレンスが存在していなければ抽出されたオカレンスと同一セグメントのオカレンスが存在しているか否かが検索され、該当するオカレンスが存在していなければ抽出されたオカレンスと同一の親に関連付けられた他のオカレンスが存在しているか否かが検索され、該当するオカレンスが存在していなければ、検索によって既に抽出されたより階層レベルの高い親と関連付けられたオカレンスが存在しているか否かが検索されることになる。
【0079】
ステップ106の検索によって抽出されたルートセグメントのオカレンスと直接又は間接的に関連付けられた全てのオカレンスをスキャンすると、ステップ146の判定が肯定されてステップ106に戻る。そして、ステップ106の検索によって該当するオカレンスが抽出された場合には、抽出されたオカレンスを起点としてステップ112以降の処理を繰り返し、ステップ106の検索によって該当するオカレンスが抽出されなかった場合には、ステップ110の判定が否定されてDBスキャン処理を終了する。
【0080】
次に、DB操作処理について図5のフローチャートを参照して説明する。ステップ220では、実行が指示された処理が不要データの削除か否か判定する。判定が否定された場合にはステップ222へ移行し、処理対象のオカレンス又は明細情報に対して指示された処理(例えば所定の条件に合致しているか否かを判断し、合致していればデータをHDD40の別領域に保存する等)を実行する。
【0081】
一方、実行が指示された処理が不要データの削除であれば、ステップ220の判定が肯定されてステップ224へ移行し、処理対象のオカレンス又は明細情報に対応するセグメントの削除基準が削除基準テーブルに登録されているか否かを判定する。判定が否定された場合には何ら処理を行うことなくDB操作処理を終了する。
【0082】
また、処理対象のオカレンス又は明細情報に対応するセグメントの削除基準が削除基準テーブルに登録されていた場合には、ステップ224の判定が肯定されてステップ226へ移行し、DBスキャン処理(図3)のステップ127又はステップ138で読み出したデータに対し、削除基準テーブルに登録されている削除基準(処理対象のオカレンス又は明細情報に対応するセグメントの削除基準)に従って所定の判定処理(例えば加減算や絶対値比較、日付比較、ビット比較等)を行うことにより、処理対象のオカレンス又は明細情報が削除基準に合致しているか否か判定する。
【0083】
判定が否定された場合は何ら処理を行うことなくDB操作処理を終了する。また、ステップ226の判定が肯定された場合にはステップ228へ移行し、処理対象のオカレンス又は明細情報と関連付けられた下位のオカレンス又は明細情報が存在しているか否かを検索する。そして、次のステップ230では、処理対象のオカレンス又は明細情報を(ステップ228の検索によってオカレンス又は明細情報が抽出された場合には、これらのオカレンス又は明細情報も)預金明細照会DBから削除する。
【0084】
前述のように、DBスキャン処理では、階層順テーブルに基づいてスキャン対象のDB(預金明細照会DB)の構造を認識してDBのスキャンを行っているので、図6に示すDBの階層順テーブルとして図7(A)に示すテーブルを用いた場合には、DBの各オカレンスが、『A1→B1→B2→C1→D1→E1(idx)→E1(明細)→E2(idx)→E2(明細)→C2→D2→D3→E3(idx)→E3(明細)→F1→G1→H1→H2→F2→G2→G3』の順序でアクセス(スキャン)されることになる。
【0085】
一方、図6に示すDBの階層順テーブルとして、前述した階層順テーブル圧縮処理を経た図7(B)に示すテーブルを用いた場合には、該テーブルに登録されていないセグメントC,D,E,Hの各オカレンス(図6にハッチングを付して示すオカレンス)は存在しないものと認識されるので、DBの各オカレンスのうち、セグメントC,D,E,H以外のセグメントの各オカレンスのみが『A1→B1→B2→F1→G1→F2→G2→G3』の順序でアクセス(スキャン)されることになる。
【0086】
本実施形態では、DBスキャン処理により預金明細照会DBに対して不要データの削除を行う場合に、階層順テーブル圧縮処理を経た階層順テーブルを用い、該テーブルに登録されているセグメント(削除基準テーブルに削除基準が登録されているか、又は削除基準が登録されていない下位のセグメントと関連付けられているセグメント)の各オカレンスのみをアクセスする(読み出す)ので、前出のスキャン順序を比較しても明らかなように、預金明細照会DBからのデータの読み出し回数を大幅に減少させることができ、読み出しに比較的長い時間がかかるデータ(DB本体と物理的に別のHDDに記憶されているデータ(本実施形態ではHDD40Bに記憶されている明細情報))の読み出し回数も少なくなることで、預金明細照会DBをスキャンして不要データを削除することを、従来に比して非常に短い時間で完了させることができる。
【0087】
なお、上記ではデータベースの各セグメントの物理アドレスを、階層レベル等の情報と共に階層順テーブルに登録しておく例を説明したが、本発明はこれに限定されるものではなく、各セグメントの物理アドレスを別テーブルに記憶すると共に、このテーブルを、例えば図2に示すデータベース管理システム等の管理下におき、特定のセグメントについて物理アドレスの問い合わせがあった場合に、特定のセグメントの物理アドレスを前記テーブルから読み出し、読み出した物理アドレスを問い合わせ元(例えば前述のDBスキャン処理を実行するためのアプリケーション・プログラム等)に返すように、データベース管理システム等を構成してもよい。
【0088】
また、上記では本発明に係る特定データベースの一例として預金明細照会DBを用いて説明したが、本発明は階層構造を有するデータベースであれば、登録されているデータの内容とは無関係に適用可能であり、例えば金融機関の他の業務(例として外国為替業務や融資業務、情報業務等)で用いられる階層構造の他のデータベースにも適用可能であることは言うまでもない。
【0089】
また、上記ではホスト・コンピュータ12がDB管理プログラムのうちのDBスキャンプログラムを実行することで、階層順テーブル圧縮処理やDB操作処理を含むDBスキャン処理が実現される場合を例に説明したが、これに限定されるものではなく、端末側(クライアントPC14又は専用端末16等)が所定のプログラムを実行することで実現されるようにしてもよいし、ホスト・コンピュータ12と端末側が協働して処理を行うことで実現されるようにしてもよい。
【0090】
更に、上記では本発明に係る所定処理として、削除基準テーブルに削除基準を登録したセグメントの各レコード(オカレンス・明細情報)のうち、対応する削除基準に合致するレコード(不要データ)を削除する処理を例に説明したが、本発明はこれに限定されるものではなく、例えばテーブルに更新基準を登録したセグメントの各レコードのうち、対応する更新基準に合致するレコードを更新する処理や、テーブルに抽出基準を登録したセグメントの各レコードのうち、対応する抽出基準に合致するデータを抽出する処理を適用してもよい。
【0091】
【発明の効果】
以上説明したように発明は、互いに異なるカテゴリの情報を登録するための複数のセグメントが階層的に関連付けられた構造を有すると共に、特定カテゴリの情報を登録するためのレコードを各セグメントに任意の数作成可能とされた特定データベースをスキャンして実行基準に合致するレコードに対して削除又は更新又はデータの抽出を行う前に、特定データベースの各セグメントのうち、実行基準テーブルに実行基準が登録されておらず、かつ関連付けられた下位階層のセグメントが存在しないか又は関連付けられた下位階層の各セグメントも実行基準テーブルに実行基準が登録されていないセグメントを検索し、検索によって抽出されたセグメントを階層順テーブルから削除したアクセス順序テーブルを階層順テーブルと別に作成し、アクセス順序テーブルを用いて特定データベースに対する所定処理を行うようにしたので、データベースをスキャンして実行基準に合致するレコードに対して削除又は更新又はデータの抽出を行うことを短時間で完了させることができる、という優れた効果を有する。
【図面の簡単な説明】
【図1】 本実施形態に係るコンピュータ・システムの概略構成を示すブロック図である。
【図2】 稼働中のホスト・コンピュータにおけるメインメモリの記憶領域の状態の一例を示す概略図である。
【図3】 DBスキャン処理の内容を示すフローチャートである。
【図4】 階層順テーブル圧縮処理の内容を示すフローチャートである。
【図5】 DB操作処理の内容を示すフローチャートである。
【図6】 本実施形態に係る預金明細照会DBの構成の一例を示す概略図である。
【図7】 (A)は元の階層順テーブル、(B)は階層順テーブル圧縮処理後の階層順テーブルの一例を示す概略図である。
【符号の説明】
10 コンピュータ・システム
12 ホスト・コンピュータ
14 クライアントPC
16 専用端末
40 HDD
50 CD−ROM
[0001]
BACKGROUND OF THE INVENTION
The present invention relates to a database management apparatus, method, program, and recording medium, and more particularly to a database management apparatus that performs predetermined processing while scanning a hierarchical database in the order specified in the hierarchical order table, and is applicable to the database management apparatus The present invention relates to a database management method, a program for causing a computer to function as a database management device, and a recording medium on which the program is recorded.
[0002]
[Prior art]
Conventionally, a database having a hierarchical structure (also called a tree structure) in which information items to be registered in a database are divided into a plurality of segments and these segments are hierarchically related is known. The hierarchical database is a segment corresponding to the specific information item even when the data amount of the specific information item is not constant for each case among a large number of data to be registered in the database. Since the data structure can be changed flexibly according to the data to be registered, such as increasing or decreasing the number of occurrences of each occurrence, the scale of the database (database (Capacity of storage means necessary for storing the data) can be suppressed.
[0003]
By the way, as the scale of the database increases, it becomes necessary to store the database in a plurality of storage devices (for example, a direct access storage device (DASD)) in a distributed manner. When a hierarchical database is distributed and stored in a plurality of storage devices, for example, a storage device that stores data in units of segments, such as storing data of some segments in another storage device, etc. In addition, a hierarchical order table is created that defines the logical association of the individual segments and the physical storage location of the individual segments. Thereby, when accessing a specific segment of the database, the physical storage position of the segment to be accessed can be recognized by referring to the hierarchical order table.
[0004]
In addition, deleting unnecessary data stored in the database is important from the viewpoint of avoiding an unnecessarily large database and reducing the cost of maintaining the database. Processing. However, in a financial institution database adopting a hierarchical structure, for example, for a specific segment, it is necessary to delete the corresponding data after one year has passed after cancellation, and for other specific segments, if a preset date arrives It is necessary to delete the corresponding data, and the deletion criteria of the data is large in units of individual segments depending on the business requirements for registering and using the data in the database, such as not deleting other segments. It is different.
[0005]
Then, the deletion process described above, for example, sequentially accesses each occurrence of the specific segment, determines whether the data registered in the accessed occurrence matches the deletion criterion corresponding to the specific segment, and deletes the deletion criterion. Can be realized by preparing different deletion criteria for each segment, such as deleting the data (or the occurrence itself) if it matches, Has a problem that it takes a lot of time and cost, and the general versatility of the program is low (can be used only for a specific database and cannot be used for other databases).
[0006]
Therefore, to delete unnecessary data in a hierarchical database, conventionally, deletion criteria for individual segments are registered in the deletion criteria table, and individual segments in the hierarchical database are referenced while referring to the hierarchical order table. Access each occurrence in turn and read all of the data one by one, and if the corresponding deletion criteria are registered in the deletion criteria table, determine whether the read data meets the registered deletion criteria. The algorithm used is to delete data (occurrence) if the deletion criteria are met.
[0007]
This algorithm scans the database to be processed while grasping the structure of the database to be processed (number of segments, logical association of individual segments, etc.) with reference to the hierarchical order table. There is no need to change the algorithm itself according to the structure of the database (number of segments, logical association of individual segments, etc.), and only the contents of the deletion criteria table are rewritten. It can also be used to delete data and is highly versatile.
[0008]
[Problems to be solved by the invention]
However, in the above algorithm, especially when the database to be processed has a structure in which a large number of occurrences are provided, the number of times of reading data from the storage device becomes enormous, and the process of deleting unnecessary data is completed. There was a problem that it took a very long time. In addition, in order to shorten the access processing time of the database, there is a case where a configuration in which the database is distributed and stored in a plurality of storage devices may be adopted. In such a configuration, unnecessary data is applied by applying the above algorithm. When it is deleted, it is disadvantageous, and the processing takes an enormous amount of time (depending on the size of the database to be processed, for example, several hours to several tens of hours).
[0009]
Further, the above-mentioned problem is not limited to deleting unnecessary data from the database. The database is scanned, and only the data stored in the database that matches a predetermined standard is stored in the database. This is a common problem when updating or extracting data.
[0010]
The present invention was made in consideration of the above facts, and scans a database. Delete or update records that meet execution criteria, or extract data It is an object to obtain a database management device, a database management method, a program, and a recording medium that can complete the process in a short time.
[0011]
[Means for Solving the Problems]
In order to achieve the above object, a database management apparatus according to claim 1 is stored in a storage device. In addition to having a structure in which a plurality of segments for registering information of different categories are hierarchically related, any number of records for registering information of a specific category can be created for each segment A hierarchical order table storage unit that stores a hierarchical order table that defines an access order in units of individual segments of the specific database when scanning the specific database; and for each record of the specific segment of the specific database Any one of a deletion process for deleting a record, an update process for updating data registered in the record, and an extraction process for extracting data registered in the record A determination table storage means for storing an execution reference table registered for any segment of each segment of the specific database, with each segment as a unit of processing, and Any When execution of the process is instructed, each record of each segment is sequentially accessed according to the access order defined in the hierarchical order table, and the execution standard for the segment corresponding to the accessed record is stored in the execution standard table. If registered, The accessed record is In the execution criteria Judgment is made whether or not it matches, and it is determined that the execution criteria are met. For the record Only said execution was directed A database management apparatus comprising: processing means for executing processing, wherein the processing means is configured to The execution was instructed Before processing, the execution criteria are not registered in the execution criteria table among the segments of the specific database, and the associated lower-level segment does not exist or the associated lower-level segments are also executed. Search for segments for which the execution criteria are not registered in the criteria table, and select the segments extracted by the search. Said Delete from the hierarchical table Ta Access order table Separate from the hierarchical order table A table creation unit for creating the database, and the processing unit is configured to access a specific database using the access order table created by the table creation unit. The execution was instructed It is characterized by performing processing.
[0012]
In the first aspect of the present invention, the information is stored in the storage device. In addition to having a structure in which a plurality of segments for registering information of different categories are hierarchically related, any number of records for registering information of a specific category can be created for each segment A hierarchical order table that defines the access order in units of individual segments of the specific database when scanning the specific database is stored in the hierarchical order table storage means, and for each record of the specific segment of the specific database Any one of a deletion process for deleting a record, an update process for updating data registered in the record, and an extraction process for extracting data registered in the record An execution criterion table in which the execution criterion of processing is registered for an arbitrary segment among the segments of the specific database in units of individual segments is stored in the determination table storage unit.
[0013]
The specific database according to the present invention may be stored in a single storage device, or may be distributed and stored in a plurality of storage devices. Even when the specific database is distributed and stored in a plurality of storage devices, for example, the physical storage position of each segment is stored in the hierarchical order table, and the hierarchy is used when accessing each segment. By determining the physical storage location with reference to the sequential table, a specific database distributed and stored in a plurality of storage devices can be handled in the same manner as a database stored in a single storage device. it can.
[0014]
In the invention according to claim 1, the specific database is One of the deletion process, the update process, and the extraction process When execution of processing is instructed, the processing means accesses each record of each segment in order according to the access order specified in the hierarchical order table, thereby scanning a specific database and responding to the accessed record. If the execution criteria for the segment to be registered is registered in the execution criteria table, The accessed record is To the execution criteria Judgment is made as to whether or not it matches, and it is judged that the execution criteria are met. For records Only said execution was directed Processing is executed.
[0015]
In addition ,Book The record in the invention may be an occurrence, or may be specific data stored in another storage device in association with a specific occurrence.
[0016]
Now scan the database as above Execution is instructed for records that meet the execution criteria When processing is performed, the processing time greatly increases as the size of the database increases (for example, the number of segments and occurrences increases). On the other hand, in the invention according to claim 1, it is extremely rare that the execution standard of the predetermined process for each record is registered for all the segments of the database. Instructed to execute processing I do For segments with no possibility, pay attention to the fact that execution criteria are not registered in the execution criteria table. Instructed to execute Before processing, the table creation means does not have any execution criteria registered in the execution criteria table among the segments of the specific database, and the associated lower hierarchy does not exist or is associated with the lower hierarchy. Search each segment of which execution criteria are not registered in the execution criteria table, and delete the segment extracted by the search from the hierarchical order table. Ta Access order table Separate from hierarchical order table The processing means creates and processes the specific database using the access order table created by the table creation means. Processing that is instructed to execute Like to do.
[0017]
The processing means sequentially accesses each record of each segment according to the access order defined in the hierarchical order table. Therefore, instead of this hierarchical order table, the execution standard is not registered in the execution standard table and is associated. If there is no segment in the lower hierarchy or the associated lower hierarchy segment also has no execution criteria registered in the execution criteria table, the segment is deleted from the hierarchy order table. Ta By using the access order table, each record of the segment meeting the above condition is excluded from the access target by the processing means.
[0018]
In the invention of claim 1, Judge whether the execution criteria are registered in the execution criteria table, or delete the execution criteria of the segments that meet the above conditions Ta The creation of the access order table can be realized without actually reading the data of the specific database, and the process itself is completed in a short time. You can reduce the number of data reads, scan the database Delete or update records that meet execution criteria, or extract data Can be completed in a short time.
[0019]
Further, the processing means and the table creating means according to the first aspect of the invention can be realized by, for example, a computer executing a predetermined program, but “each segment according to the access order defined in the hierarchical order table” When the execution criteria for the segment corresponding to the accessed record are registered in the execution criteria table, Judgment is made as to whether or not the accessed record meets the execution criteria, and execution is instructed only for the record that is judged to meet the execution criteria In an environment where a program corresponding to “processing means for executing processing” already exists, the processing means can be realized only by changing the above program so that an access order table is used instead of the execution reference table. In order to obtain the database management apparatus according to the first aspect of the present invention, the database management apparatus according to the first aspect of the invention can be obtained only by newly developing a program corresponding to the table creation means. The time and cost required for program development can be reduced.
[0020]
Claim 2 The database management method according to the described invention is: A plurality of segments for registering different categories of information stored in the storage device are hierarchically related, and any number of records for registering specific category information is created for each segment. A hierarchical order table storage means for storing a hierarchical order table that defines an access order in units of individual segments of the specific database when scanning the specific database made possible; and each of the specific segments of the specific database For each record, the execution criteria of any one of the deletion process for deleting the record, the update process for updating the data registered in the record, and the extraction process for extracting the data registered in the record are determined for each segment. An arbitrary segment of each segment of a specific database And a determination table storage means for storing an execution criterion table registered for the database management method realized by a computer performing a specific process, wherein the specific process is performed for each segment of the specific database. Of these, the execution criteria are not registered in the execution criteria table, and there are no associated lower-level segments, or each of the associated lower-level segments does not have an execution criteria registered in the execution criteria table. A first step of creating an access order table separately from the hierarchical order table by searching and deleting a segment extracted by the search from the hierarchical order table, when execution of any one of the processes for a specific database is instructed, Specified in the access order table created in the first step And sequentially accessing each record of each segment according to the access order, and if the execution criterion for the segment corresponding to the accessed record is registered in the execution criterion table, the accessed record is Including a second step of determining whether or not the condition is met and executing the process instructed to execute only the record that is determined to meet the execution standard In the same manner as in the first aspect of the invention, the database is scanned. Delete or update records that meet execution criteria, or extract data Can be completed in a short time.
[0021]
Claim 3 The program according to the described invention is stored in a storage device In addition to having a structure in which a plurality of segments for registering information of different categories are hierarchically related, any number of records for registering information of a specific category can be created for each segment A hierarchical order table storage unit that stores a hierarchical order table that defines an access order in units of individual segments of the specific database when scanning the specific database; and for each record of the specific segment of the specific database Any one of a deletion process for deleting a record, an update process for updating data registered in the record, and an extraction process for extracting data registered in the record Execution of specific processing on a computer provided with a determination table storage means for storing an execution criterion table registered for an arbitrary segment of each segment of a specific database in units of individual segments. The specific process is executed when the execution standard is not registered in the execution standard table and the associated lower-level segment does not exist or is associated with each of the segments of the specific database. Also search the segments whose execution criteria are not registered in the execution criteria table for each segment in the lower hierarchy, and select the segments extracted by the search. Said Delete from the hierarchical table Ta Access order table Separate from the hierarchical order table The first step to create, said specific database Any When execution of the process is instructed, each record of each segment is sequentially accessed according to the access order defined in the access order table created in the first step, and the execution of the segment corresponding to the accessed record is performed. If criteria are registered in the execution criteria table, The accessed record is In the execution criteria Judgment is made whether or not it matches, and it is determined that the execution criteria are met. For the record Only said execution was directed A second step of executing the process is included.
[0022]
Claim 3 Since the program according to the described invention is a program for causing the computer to function as the database management apparatus according to claim 1, that is, the specific process including the first and second steps, the computer executes the program. By executing, the database is scanned in the same manner as in the first aspect of the invention. Delete or update records that meet execution criteria, or extract data Can be completed in a short time.
[0023]
Claim 4 The recording medium according to the described invention is stored in a storage device In addition to having a structure in which a plurality of segments for registering information of different categories are hierarchically related, any number of records for registering information of a specific category can be created for each segment A hierarchical order table storage unit that stores a hierarchical order table that defines an access order in units of individual segments of the specific database when scanning the specific database; and for each record of the specific segment of the specific database Any one of a deletion process for deleting a record, an update process for updating data registered in the record, and an extraction process for extracting data registered in the record Execution of specific processing on a computer provided with a determination table storage means for storing an execution criterion table registered for an arbitrary segment of each segment of a specific database in units of individual segments. In the recording medium in which a program for recording is recorded, the specific processing is performed in such a manner that, among the segments of the specific database, the execution standard is not registered in the execution standard table, and the associated lower layer segment is Search for segments that do not exist or have associated execution criteria for each segment in the lower-level hierarchy, and that have been extracted by the search. Said Delete from the hierarchical table Ta Access order table Separate from the hierarchical order table The first step to create, said specific database Any When execution of the process is instructed, each record of each segment is sequentially accessed according to the access order defined in the access order table created in the first step, and the execution of the segment corresponding to the accessed record is performed. If criteria are registered in the execution criteria table, The accessed record is In the execution criteria Judgment is made whether or not it matches, and it is determined that the execution criteria are met. For the record Only said execution was directed A second step of executing the process is included.
[0024]
Claim 4 The recording medium according to the described invention records the processing including the first and second steps, that is, a program for causing the computer to function as the database management device according to claim 1. By reading and executing the program recorded on the recording medium, the database is scanned in the same manner as in the first aspect of the invention. Delete or update records that meet execution criteria, or extract data Can be completed in a short time.
[0025]
DETAILED DESCRIPTION OF THE INVENTION
Hereinafter, an example of an embodiment of the present invention will be described in detail with reference to the drawings. FIG. 1 shows a computer system 10 installed in a financial institution to support various operations of the financial institution. The computer system 10 includes a host computer 12 having a function as a database management apparatus according to the present invention.
[0026]
A large number of client PCs 14 or dedicated terminals 16 are installed in each department of the financial institution, and each client PC 14 is connected to the host computer 12 via a communication control server 18 and an intranet 20. Each dedicated terminal 16 is connected to the host computer 12 via a public communication network 26 including a terminal adapter (TA) 22, a modem 24, a public telephone network, and the like. In FIG. 1, the host computer 12 is shown as a single computer. However, the present invention is not limited to this, and it goes without saying that the computer may be composed of a plurality of computers.
[0027]
The host computer 12 is composed of a workstation or a general-purpose large computer and includes a CPU 12A, a ROM 12B, a RAM 12C, and an input / output port 12D, which are connected to each other via a bus 12E such as an address bus, a data bus, and a control bus. Has been. The input / output port 12D is connected to a public communication network 26 via a modem 28, and is connected to a communication control device 30 for communicating with the dedicated terminal 16 via the public communication network 26, a display 32, a mouse 34, a keyboard 36, an intranet. A communication control server 38 for communicating with the client PC 14 via the computer 20, an HDD 40 as a storage device according to the present invention, and a CD-ROM drive 42 for reading information from a CD-ROM are connected. .
[0028]
The HDD 40 of the host computer 12 stores a deposit details inquiry database (deposit details inquiry DB) corresponding to a specific database according to the present invention, and a hierarchy order table and a deletion criteria table of the deposit details inquiry DB (whichever In addition, a DB management program (a program for realizing a DB management system) for executing a DB management process including a database (DB) scan process, which will be described later, by the CPU 12A is installed in the HDD 40. An operating system (OS) program is also installed.
[0029]
The hierarchical order table stored in the HDD 40 corresponds to the hierarchical order table of the present invention, the deletion reference table corresponds to the execution reference table of the present invention, and the HDD 40 stores the hierarchical order table storage means according to claim 1 and the like. And a determination table storage means.
[0030]
There are several methods for installing (transferring) the DB management program to the host computer 12. For example, the DB management program is recorded on the CD-ROM 50 together with the setup program, and the CD-ROM 50 is stored in the host computer 12. If the CD-ROM drive 42 is set and the CPU 12A is instructed to execute the setup program, the DB management program is sequentially read from the CD-ROM 50, and the read DB management program is sequentially written to the HDD 40. Then, the DB management program is installed.
[0031]
The DB management program is claimed 3 And the program described in claim 1. 4 The CD-ROM 50 according to the above aspect is also compatible with the program recorded on the recording medium described in claim 1. 4 It corresponds to the recording medium described in.
[0032]
Further, instead of installing the DB management program using the CD-ROM 50 as described above, the DB management program is initially loaded with the public communication network 26, the intranet 20, or other computer networks (for example, LAN, Internet, Stored in a storage device of another information processing device (for example, a network server) connected to the host computer 12 via a wireless communication network or the like, and the host computer 12 communicates with the information processing device, A configuration may be adopted in which the information processing device transmits the information to the host computer 12 and is installed in the HDD 40 and executed by the host computer 12.
[0033]
Next, the operation of this embodiment will be described. Financial institutions provide customers with a service called Electronic Banking (EB). This EB provides customers with various services such as deposit balance inquiry, deposit / withdrawal inquiry, account transfer, and transfer online by the customer operating a computer (or a dedicated terminal) installed at home or business. To do. The deposit statement inquiry DB stored in the HDD 40 of the host computer 12 is information (showing details of the transfer of funds generated by the deposit exchange business supported by the deposit exchange system with respect to the EB system supporting the above EB business ( This is a database that holds deposit details information for the purpose of delivering the deposit details information.
[0034]
As shown in FIG. 6 as an example, the deposit details inquiry DB according to the present embodiment includes a plurality of segments for registering information of different categories determined in advance among various information constituting the deposit details information. Have an associated structure. For example, the DB shown in FIG. 6 is composed of eight types of segments, segment A to segment H, the segment A (root segment) in the highest first layer, the segments B, C, F, and third in the second layer. Segments D, E, G, and H are provided in the hierarchy, segments B, C, and F are associated with segment A, segments D and E are associated with segment C, and segments G and H are associated with segment F. Have a structure.
[0035]
Each segment can create an arbitrary number of occurrences, and when the amount of data of a specific category of the deposit details stored in the deposit details inquiry DB is large, At the time of registration, a plurality of occurrences are created as segments for registering specific category information, and the specific category information is registered in the created occurrences.
[0036]
For example, in FIG. 6, occurrences B1 and B2 for segment B, occurrences C1 and C2 for segment C, occurrences D1 to D3 for segment D, occurrences E1 to E3 for segment E, and occurrences for segment F F1, F2, Occurrences G1-G3 are created for segment G, Occurrences H1, H2 are created for segment H, occurrences D1, E1, E2 are associated with occurrence C1, and occurrences D2, D3, E3 are Associated with the occurrence, occurrences G1, H1, H2 are associated with the occurrence F1, and occurrences G2, G3 are associated with the occurrence F2.
[0037]
Further, since the deposit details information has an enormous amount of data, the HDD 40 is actually composed of a plurality of HDDs (see HDDs 40A and 40B shown in FIG. 6 as an example), and some of the deposit details information The information (detailed information) is stored in a HDD (HDD 40B in the example of FIG. 6) different from the HDD (HDD 40A in the example of FIG. 6) in which the deposit detail inquiry DB main body is stored. For example, in FIG. 6, detailed information E1 to E3 is stored in the HDD 40B, and each occurrence E1 to E3 of the segment E in the deposit detail inquiry DB main body stored in the HDD 40A is an index indicating the detailed information E1 to E3. Information iDX is registered.
[0038]
On the other hand, as shown in FIG. 7A as an example, the hierarchical order table is configured by registering the hierarchical level and the physical address (physical storage location) for all segments constituting the deposit statement inquiry DB. ing. The registration order of each segment in the hierarchical order table is determined in consideration of the association of each segment, and the association of each segment can be recognized by referring to the hierarchical order table. That is, each segment whose hierarchy level is 2 or less (other than the root segment) registered in the hierarchy order table is higher than each segment that appears first when tracing upward from the registration position of each segment in the hierarchy order table. It can also be determined that the hierarchical level is associated with a segment one hierarchy higher (for example, segment C if segment E).
[0039]
The deletion criteria table is a table in which criteria for determining whether or not to delete an occurrence of a segment that may delete the corresponding occurrence among the segments constituting the deposit statement inquiry DB are registered. As an example, as shown in FIG. 6 with the symbols “●” and “x”, deletion criteria are registered in the deletion criteria table for the segments B and G.
[0040]
When the power of the host computer 12 is turned on, as shown in FIG. 2, programs such as an OS program, a DB management program, and communication management software are loaded into the main memory (RAM 12C), and these programs are executed. As a result, the OS and DB management system operate. Further, when the DB management program is loaded, a part of the storage area of the main memory is secured as a common area (see FIG. 2), and the hierarchical order table and the deletion criterion table are copied from the HDD 40 to the common area. The hierarchical order table and the deletion criterion table copied to the common area are resident in the common area while the host computer 12 is powered on.
[0041]
Next, a DB scan process to which the database management method according to the present invention is applied will be described with reference to the flowchart of FIG. This DB scan process is a process that is executed when any one of a plurality of types of processes to be performed while scanning the deposit details inquiry DB is instructed, such as unnecessary data deletion in the deposit details inquiry DB. The processing to be executed is registered in advance as a job to be executed by the operator at a predetermined time, and is executed when the predetermined time comes.
[0042]
The DB scan process is realized by the CPU 12A of the host computer 12 executing a DB scan program that is a part of the DB management program. First, as shown in FIG. After being secured as an area for running the program, a series of processes shown in FIG. 3 are sequentially executed using this area. The processing algorithm will be described below using the database structure shown in FIG.
[0043]
In step 100, it is determined whether or not the process instructed to execute is deletion of unnecessary data. In the case of deleting unnecessary data, the determination in step 100 is affirmed and the process proceeds to step 102, and the hierarchical order table compression process described below is performed. If the process instructed to execute is a process other than the deletion of unnecessary data, the determination in step 100 is denied, and the process proceeds to step 104 without performing the hierarchical order table compression process. Further, the hierarchical order table compression processing corresponds to the table creation means according to claim 1, 2 to Claim 4 This is a process corresponding to the first step described in.
[0044]
As shown in FIG. 4, in the hierarchical order table compression process, in step 170, the segments of the first and second entries of the hierarchical order table stored (resident) in the common area of the main memory are stored in the DB of the main memory. Copies are made respectively to the first and second areas of the work area (deletion processing hierarchy order table creation area shown in FIG. 2) provided in the scan program operation area. In the following, for convenience, the hierarchical order table is referred to as table A, and the hierarchical order table for deletion processing created in the work area by the hierarchical order table compression process is referred to as table B.
[0045]
In the next step 172, predetermined information (referred to as a stopper) indicating the end of the table B is written in the third area of the table B. In a step 174, the initial value of the variables i, j, k is set in the variable i. 3 is assigned, 1 is assigned to the variable j, and 2 is assigned to the variable k. The variable i is the position of the segment to be read from the table A, the variable j is the position of the last segment determined not to be deleted (overwritten) among the segments registered in the table B, and the variable k is the last entry of the table B. Represents the position. In step 176, the segment information (hierarchy level etc.) of the i-th entry of table A (hierarchical order table) is referred to.
[0046]
In step 178, the value of the variable k is substituted into the variable s. In the next step 180, whether the segment of the i-th entry in the table A is lower than the segment of the s-th entry in the table B. To determine. If the determination is affirmative, the process proceeds to step 192. If the determination is negative, the process proceeds to step 182, and whether the deletion criterion for the segment of the s-th entry in table B is registered in the deletion criterion table. Search for no. In step 184, it is determined whether or not the corresponding deletion criterion is extracted by the search in step 182.
[0047]
If the determination is affirmative, the routine proceeds to step 190, and after the value of the variable s is entered into the variable j, the routine proceeds to step 192. If the determination in step 184 is negative, the process proceeds to step 186 and the value of the variable s is decremented by 1. In the next step 188, it is determined whether or not the value of the variable s is equal to the value of the variable j. If the determination is negative, the process returns to step 180, and steps 180 and after are repeated. If the determination is affirmative, the process proceeds to step 192. Accordingly, steps 180 to 188 are repeated until the determination of any of step 180, step 184, and step 188 is affirmed.
[0048]
In step 192, the segment of the i-th entry in table A is copied to the s + 1th area of table B, and in the next step 194, a stopper is written in the s + 2 area of table B. In step 196, a value obtained by adding 1 to the variable s is substituted for the variable k. In the next step 198, it is determined whether or not the segment of the i-th entry in the table A is a segment corresponding to the last entry in the table A. If the determination is negative, in step 200, the value of the variable i is incremented by 1, and then the process returns to step 176. Therefore, until the determination in step 198 is affirmed, step 1 is performed. 76 Step 200 will be repeated.
[0049]
The loop of steps 176 to 200 described above will be further described by taking the hierarchical order table shown in FIG. 7A as an example. When the loop is executed for the first time, segments A and B are copied to table B. Since i = 3, j = 1, and k = 2 (= s), the i-th entry in table A (hierarchical order table) is the s-th entry in segment C and table B (hierarchical order table for deletion processing). The entry is segment B.
[0050]
Since the segment B and C are both “2” in the hierarchy level, the determination in step 180 is negative, but the segment B is marked with “●” in FIG. 6 (see occurrence B1). As is clear, since the deletion criterion is registered in the deletion criterion table, the determination in step 184 is affirmed. As a result, the value of the variable j becomes 2 (step 190), and it is determined that the segment B is not deleted (overwritten). In addition, the segment C is written in the third area of the table B, and the stopper is written in the fourth area, and the value of the variable k becomes 3 (steps 192 to 196). Return.
[0051]
Next, since i = 4, j = 2, and k = 3 (= s), the i-th entry in table A is segment D, and the s-th entry in table B is segment C. Since the hierarchical level of the segment D is “3” and the hierarchical level is lower than the segment C, the determination in step 180 is affirmed, and the segment D is in the fourth area of the table B, and the stopper is in the fifth area. At the same time, the value of the variable k becomes 4 (steps 192 to 196), and returns to step 176 through steps 198 and 200.
[0052]
Next, since i = 4, j = 2, and k = 4 (= s), the i-th entry of table A is segment E, and the s-th entry of table B is segment D. Since both the segments D and E have the hierarchical level “3”, the determination in step 180 is negative. Further, as apparent from the fact that the segment D is marked with an “x” symbol in FIG. 6 (see occurrence D1), the deletion criterion is not registered in the deletion criterion table, so the determination in step 184 is negative. Then, the variable s is decremented by 1 to 3 (step 186), but since j ≠ s (j = 2), the determination in step 188 is denied and the process returns to step 180.
[0053]
Since s = 3, the i-th entry in table A remains as segment E, whereas the s-th entry in table B becomes segment C, but segment E has a lower hierarchical level than segment C. Therefore, the determination in step 180 is affirmed, the segment E is written in the fourth area of Table B (that is, the area where segment D has been written), and the stopper is written in the fifth area, and the value of variable k is 4 (steps 192 to 196), the process returns to step 176 through steps 198 and 200.
[0054]
Next, since i = 5, j = 2, and k = 4 (= s), the i-th entry in table A is segment F, and the s-th entry in table B is segment E. Since the segment F has a hierarchical level “2” and is higher than the segment E, the determination in step 180 is negative. Further, as is clear from the fact that the segment E is marked with an “x” symbol in FIG. 6 (see occurrence E1), the deletion criterion is not registered in the deletion criterion table, so the determination in step 184 is negative. Then, the variable s is decremented by 1 to 3 (step 186), but since j ≠ s (j = 2), the determination in step 188 is denied and the process returns to step 180.
[0055]
Since s = 3, the i-th entry in table A is the segment F On the other hand, the s-th entry in the table B is the segment C, but since the segment E is lower in the hierarchy level than the segment C, the determination in step 180 is affirmed, and the fourth entry in the table B The segment E is written in the area (that is, the area where the segment D has been written), the stopper is written in the fifth area, and the value of the variable k becomes 4 (steps 192 to 196). Return to step 176.
[0056]
Next, since i = 6, j = 2, and k = 3 (= s), the i-th entry of table A is segment G, and the s-th entry of table B is segment F. Since the hierarchical level of the segment G is “3” and the hierarchical level is lower than the segment F, the determination in step 180 is affirmed, and the segment G is in the fourth area of the table B, and the stopper is in the fifth area. At the same time, the value of the variable k becomes 4 (steps 192 to 196), and returns to step 176 through steps 198 and 200.
[0057]
Next, since i = 7, j = 2, and k = 4 (= s), the i-th entry of table A is segment H, and the s-th entry of table B is segment G. Since segment H has the same level as segment G, the determination in step 180 is negative. As apparent from the fact that the symbol “●” is attached to the segment G in FIG. 6 (see occurrence G1), the deletion criterion is registered in the deletion criterion table, so the determination in step 184 is affirmed. . As a result, the value of the variable j becomes 4 (step 190), and it is determined that the segment F and the segment G are not deleted (overwritten).
[0058]
Note that the deletion criterion is not registered in the deletion criterion table for the segment F, but the deletion criterion for the segment G of the associated lower hierarchy is registered in the deletion criterion table, so it is excluded from being deleted (overwritten). The Then, the segment H is written in the fifth area of the table B, the stopper is written in the sixth area, and the value of the variable k becomes 5 (steps 192 to 196).
[0059]
When the above loop is repeated until the variable i reaches a value corresponding to the last entry of the hierarchical order table, the determination at step 198 is denied and the routine proceeds to step 202, where the value of the variable k is substituted into the variable s. In the next step 204, it is searched whether or not the deletion criterion of the segment of the s-th entry in Table B is registered in the deletion criterion table. In step 206, it is determined whether or not the corresponding deletion criterion is extracted by the search in step 204.
[0060]
If the determination is affirmative, the hierarchical order table compression processing is terminated. If the determination is negative, the process proceeds to step 208, and a stopper is written in the s-th area of table B, so that the segment is stored in table B. Delete from. In the next step 210, the variable s is decremented by 1. In step 212, it is determined whether or not the value of the variable s matches the value of the variable j. If the determination is negative, the process returns to step 204. If the determination is positive, the hierarchical order table compression process is terminated.
[0061]
Thus, for example, if the last entry in the hierarchical order table of FIG. 7A is segment H, since deletion criterion is not registered in the deletion criterion table, segment H is temporarily written in table B in the previous step 192. And then deleted from the table B by being overwritten by the stopper, for example, the hierarchical order table (FIG. 7A) in which the segments C, D, E, H are deleted and compressed from the hierarchical order table shown in FIG. 7 (B): corresponding to the access order table of the present invention). When the above hierarchical order table compression process ends, the process proceeds to step 104 of the DB scan process (FIG. 3).
[0062]
The hierarchical order table compression processing described above stores, for example, segments to be deleted while scanning the hierarchical order table, scans the hierarchical order table again after scanning to the last entry, and only segments that are determined not to be deleted This can also be realized by an algorithm that creates a hierarchical order table for deletion processing by copying the files to the work area in sequence, but this algorithm requires scanning the hierarchical order table twice, so creating a hierarchical order table for deletion processing Has the disadvantage of taking time.
[0063]
On the other hand, in the algorithm shown in FIG. 4, when the segments registered in the hierarchical table are sequentially scanned and each segment is sequentially copied to the work area, the segments already copied to the work area can be deleted. A hierarchy order table for deletion processing is created by determining whether or not there is a segment and overwriting the segment that has been determined to be deleted with the segment to be copied, so the hierarchy order table only needs to be scanned once, and the deletion process Can be created in a shorter time.
[0064]
On the other hand, in the DB scan processing, processing is performed using the hierarchical order table. When the determination in step 100 is affirmed and the hierarchical order table compression processing is performed, the processing is generated (compressed) by the hierarchical order table compression processing. The processing is performed using the hierarchical order table (that is, the access order table according to the present invention). Also. The steps after the step 104 of the DB scan processing correspond to the processing means described in claim 1, and 2 to Claim 4 This is a process corresponding to the second step described in.
[0065]
In step 104, 1 (initial value) is substituted for variable n. In step 106, is there an occurrence that has not been processed in step 112 and later, in each occurrence of the segment of the highest entry in the hierarchical order table (segment A, which is the root segment in the example of FIG. 7)? In the next step 110, it is determined whether or not the corresponding occurrence has been extracted by the above search.
[0066]
When the corresponding occurrence (for example, occurrence A1 shown in FIG. 6) is extracted, the determination at step 110 is affirmed and the routine proceeds to step 112, where the occurrence extracted by the search at step 108 is the parent n (in this case). As “parent 1”). In step 114, 1 (initial value) is substituted for variable Xn (in this case, X1).
[0067]
In step 116, the Xn-th entry is referenced from the parent n segment on the hierarchical order table. In step 118, it is determined whether or not the corresponding entry exists. If the determination is affirmative, the process proceeds to step 120, where the segment of the corresponding entry is set as the segment α (pointer pointing to an arbitrary segment). In the next step 122, it is determined whether or not the segment α has a lower hierarchical level than the parent n segment. If the determination is affirmative, the routine proceeds to step 124. In step 124, an unprocessed occurrence is searched from among the occurrences of the segment α associated with the parent n, and in the next step 126, it is determined whether or not the corresponding occurrence is extracted by the search in step 124.
[0068]
If the determination in step 126 is negative, the process proceeds to step 142, the variable Xn is incremented by 1, and the process returns to step 116. On the other hand, if the determination in step 126 is affirmed, the process proceeds to step 127, and after reading the data of the corresponding occurrence from the deposit statement inquiry DB, DB operation processing is performed in step 128. This DB operation process will be described later. In the next step 130, the value of the variable n is incremented by 1. In step 132, the occurrence of the DB operation processing in step 128 is stored as the parent n. In step 134, 1 (initial value) is substituted for the variable Xn. .
[0069]
In step 136, it is determined whether or not the corresponding occurrence is an occurrence in which index information iDX is registered (for example, occurrence E1 to occurrence E3 written as (iDX) in FIG. 6). If the determination is negative, the process returns to step 116 without performing any processing. If the determination is affirmative, the process proceeds to step 138, and the detailed information associated with the occurrence is read from the deposit details inquiry DB based on the index information iDX registered in the occurrence. In the next step 140, the above-described DB operation processing is performed on the read detailed information, and then the process returns to step 116.
[0070]
If the determination in step 118 or step 122 is negative, the process proceeds to step 144 and the variable n is decremented by 1. In the next step 146, it is determined whether or not the decrement in step 144 has become smaller than n. If the determination is negative, the process returns to step 116, and if the determination is affirmative, the process returns to step 106.
[0071]
Steps 112 to 146 described above will be further described by taking as an example a case where the DB structure shown in FIG. 6 is scanned using the hierarchical order table shown in FIG. 7A. After being set as parent 1 and substituting 1 for variable X1 in step 114, the search in step 116 makes the segment as segment X1 (= 1) from the segment (segment A) of parent 1 (occurrence A1) B is extracted. Since segment B is lower than the segment of parent 1 (segment A), the determination in step 122 is affirmed, and the search in step 126 results in occurrence B1 as an unprocessed occurrence of segment B associated with parent 1 (occurrence A1). Is extracted.
[0072]
After the DB operation processing (step 128) is performed on the occurrence B1, the occurrence B1 is set as the parent 2 and the variable X2 is initialized to 1 in order to search for the lower-level occurrence associated with the occurrence B1. (Step 130 to Step 134) Return to Step 116.
[0073]
Subsequently, the segment C is extracted as the X2 (= 1) -th segment from the segment (segment B) of the parent 2 (occurrence B1) by the search in step 116, but the segment C is the segment of the parent 2 (segment B). Since the hierarchy level is the same and it can be determined that there is no lower-order occurrence associated with the occurrence B1, the determination in step 122 is denied and the variable n is returned to 1 and the process returns to step 116.
[0074]
Next, segment B is extracted again as the X1 (= 1) th segment from occurrence A1 by the search in step 116, and occurrence B2 is extracted by the search in step 124. Similarly to the above-described occurrence B1, after the DB operation process (step 128) is performed on the occurrence B2, the occurrence B2 is set as the parent 2 in order to search for a lower-order occurrence associated with the occurrence B2. , The variable X2 is set to 1, and the process returns to step 116, and the search in step 116 extracts the segment C as the X2 (= 1) th segment from the segment (segment B) of the parent 2 (occurrence B2). Since C has the same hierarchy level as the parent 2 segment (segment B), the determination in step 122 is negative, the variable n is returned to 1, and the flow returns to step 116.
[0075]
Subsequently, segment B is extracted again from the occurrence A1 as the X1 (= 1) th segment by the search in step 116, but there is no unprocessed occurrence of the segment B associated with the occurrence A1, The determination in step 126 is negative, the variable X1 is set to 2, and the process returns to step 116.
[0076]
Next, as a result of the search in step 116, the segment C is extracted again as the X1 (= 2) th segment from the occurrence A1, and the segment C has a lower hierarchical level than the parent 1 segment (segment A). And the occurrence C1 is extracted by the search in step 124. Then, after the DB operation processing (step 128) is performed on the occurrence C1, the occurrence C1 is set as the parent 2 and the variable X2 is set to 1 in order to search the lower-order occurrences associated with the occurrence C1. Return to Step 116.
[0077]
Subsequently, the segment D is extracted from the segment (segment C) of the parent 2 (occurrence C1) as the X2 (= 1) th segment by the search in step 116.
[0078]
In the same manner, after performing the DB operation process (step 128) on the occurrence in which the occurrence of the target of the DB operation process is extracted, there is a lower-order occurrence associated with the extracted occurrence. If the occurrence does not exist, the occurrence of the same segment as the extracted occurrence is searched. If the occurrence does not exist, the extracted occurrence is searched. If there is another occurrence associated with the same parent, and if there is no such occurrence, there is an occurrence associated with a higher-level parent already extracted by the search It will be searched whether or not.
[0079]
When all occurrences directly or indirectly associated with the root segment occurrence extracted by the search in step 106 are scanned, the determination in step 146 is affirmed and the process returns to step 106. If the corresponding occurrence is extracted by the search in step 106, the process from step 112 is repeated with the extracted occurrence as a starting point, and if the corresponding occurrence is not extracted by the search in step 106, The determination in step 110 is negative and the DB scan process is terminated.
[0080]
Next, DB operation processing will be described with reference to the flowchart of FIG. In step 220, it is determined whether or not the process instructed to execute is deletion of unnecessary data. If the determination is negative, the process proceeds to step 222, where it is determined whether or not the processing target occurrence or detailed information is instructed (for example, whether or not a predetermined condition is met, and if it matches, the data Is stored in another area of the HDD 40).
[0081]
On the other hand, if the process instructed to execute is deletion of unnecessary data, the determination in step 220 is affirmed and the process proceeds to step 224, and the deletion criterion of the segment corresponding to the occurrence or detailed information to be processed is stored in the deletion criterion table. It is determined whether it is registered. If the determination is negative, the DB operation process is terminated without performing any process.
[0082]
If the deletion criterion of the segment corresponding to the occurrence or detail information to be processed is registered in the deletion criterion table, the determination in step 224 is affirmed and the routine proceeds to step 226, where DB scan processing (FIG. 3) Predetermined read-out processing (for example, addition / subtraction or absolute value) according to the deletion criteria registered in the deletion criteria table (deletion criteria for the segment corresponding to the occurrence to be processed or detailed information) By comparison, date comparison, bit comparison, etc., it is determined whether or not the occurrence or detail information to be processed meets the deletion criteria.
[0083]
If the determination is negative, the DB operation process is terminated without performing any process. If the determination at step 226 is affirmative, the routine proceeds to step 228, where it is searched whether there is a lower-level occurrence or detail information associated with the occurrence or detail information to be processed. Then, in the next step 230, the occurrence or detail information to be processed (if the occurrence or detail information is extracted by the search in step 228, these occurrences or detail information are also deleted) from the deposit details inquiry DB.
[0084]
As described above, in the DB scan processing, since the DB is scanned by recognizing the structure of the DB to be scanned (deposit details inquiry DB) based on the hierarchy order table, the DB hierarchy order table shown in FIG. When the table shown in FIG. 7A is used, each occurrence of DB is “A1 → B1 → B2 → C1 → D1 → E1 (idx) → E1 (details) → E2 (idx) → E2 ( (Detail) → C2->D2->D3-> E3 (idx)-> E3 (detail)->F1->G1->H1->H2->F2->G2-> G3 ".
[0085]
On the other hand, when the table shown in FIG. 7B that has undergone the above-described hierarchical order table compression processing is used as the DB hierarchical order table shown in FIG. 6, the segments C, D, and E that are not registered in the table are used. , H occurrences (occurrence indicated by hatching in FIG. 6) are recognized as nonexistent, and therefore, only the occurrences of the segments other than the segments C, D, E, and H among the DB occurrences are detected. Access (scan) is performed in the order of “A 1 → B 1 → B 2 → F 1 → G 1 → F 2 → G 2 → G 3”.
[0086]
In this embodiment, when unnecessary data is deleted from the deposit statement inquiry DB by DB scan processing, a segment (deletion criterion table) registered in the table is used using a hierarchical order table that has undergone hierarchical order table compression processing. Since only the occurrences of the deletion criteria are registered in (or the segment associated with the lower segment for which the deletion criteria are not registered) are accessed (read), it is clear even if the above scan order is compared As described above, the number of times of reading data from the deposit statement inquiry DB can be greatly reduced, and data that takes a relatively long time to read (data stored in a HDD physically separate from the DB main body (this book In the embodiment, the details of the detailed information)) stored in the HDD 40B is reduced, so that the deposit details inquiry DB To delete unnecessary data by scanning, it can be completed in a very short time as compared with the conventional.
[0087]
In the above description, the example in which the physical address of each segment of the database is registered in the hierarchical order table together with information such as the hierarchical level has been described. However, the present invention is not limited to this and the physical address of each segment is not limited thereto. Is stored in a separate table, and when this table is managed by the database management system shown in FIG. 2, for example, when a physical address inquiry is made for a specific segment, the physical address of the specific segment is stored in the table. The database management system or the like may be configured so that the read physical address is returned to the inquiry source (for example, an application program for executing the above-described DB scan processing).
[0088]
In the above description, the deposit statement inquiry DB is used as an example of the specific database according to the present invention. However, the present invention is applicable to any database having a hierarchical structure regardless of the contents of registered data. Needless to say, the present invention can also be applied to other databases having a hierarchical structure used in other operations of financial institutions (for example, foreign exchange operations, loan operations, information operations, etc.).
[0089]
In the above description, the host computer 12 executes the DB scan program of the DB management program, so that DB scan processing including hierarchical order table compression processing and DB operation processing is realized as an example. The present invention is not limited to this, and the terminal side (client PC 14 or dedicated terminal 16 or the like) may be realized by executing a predetermined program, or the host computer 12 and the terminal side cooperate. You may make it implement | achieve by performing a process.
[0090]
Further, in the above description, as the predetermined processing according to the present invention, the processing (deletion data) that matches the corresponding deletion criterion among the records (occurrence / detail information) of the segment in which the deletion criterion is registered in the deletion criterion table. However, the present invention is not limited to this. For example, among the records of the segments whose update criteria are registered in the table, a process that updates a record that matches the corresponding update criteria, or a table. You may apply the process which extracts the data which match | combines corresponding extraction criteria among each record of the segment which registered the extraction criteria.
[0091]
【The invention's effect】
As explained above Book The invention A plurality of segments for registering different categories of information have a hierarchically related structure, and an arbitrary number of records for registering specific category information can be created for each segment Scan specific databases Delete or update records that meet execution criteria, or extract data Before executing, the execution criteria are not registered in the execution criteria table among the segments of the specific database, and there is no associated lower-level segment or the associated lower-level segments are also executed criteria. Search for segments for which execution criteria are not registered in the table, and delete the segments extracted by the search from the hierarchical order table. Ta Access order table Separate from hierarchical order table Created and performed a specific process for a specific database using the access order table, so scan the database Delete or update records that meet execution criteria, or extract data It is possible to complete the process in a short time.
[Brief description of the drawings]
FIG. 1 is a block diagram showing a schematic configuration of a computer system according to an embodiment.
FIG. 2 is a schematic diagram illustrating an example of a state of a storage area of a main memory in an operating host computer.
FIG. 3 is a flowchart showing the contents of DB scan processing.
FIG. 4 is a flowchart showing the contents of a hierarchical order table compression process.
FIG. 5 is a flowchart showing the contents of a DB operation process.
FIG. 6 is a schematic diagram showing an example of the configuration of a deposit statement inquiry DB according to the present embodiment.
7A is a schematic diagram illustrating an example of an original hierarchical order table, and FIG. 7B is a schematic diagram illustrating an example of a hierarchical order table after hierarchical order table compression processing;
[Explanation of symbols]
10 Computer system
12 Host computer
14 Client PC
16 Dedicated terminal
40 HDD
50 CD-ROM

Claims (4)

記憶装置に記憶された、互いに異なるカテゴリの情報を登録するための複数のセグメントが階層的に関連付けられた構造を有すると共に、特定カテゴリの情報を登録するためのレコードを各セグメントに任意の数作成可能とされた特定データベースをスキャンする際の、前記特定データベースの個々のセグメントを単位とするアクセス順序を規定する階層順テーブルを記憶する階層順テーブル記憶手段と、
前記特定データベースの特定のセグメントの各レコードに対する、レコードを削除する削除処理、レコードに登録されているデータを更新する更新処理、及び、レコードに登録されているデータを抽出する抽出処理の何れかの処理の実行基準を、個々のセグメントを単位として、特定データベースの各セグメントのうちの任意のセグメントについて登録した実行基準テーブルを記憶する判断テーブル記憶手段と、
特定データベースに対する前記何れかの処理の実行が指示されると、前記階層順テーブルに規定されたアクセス順序に従って個々のセグメントの各レコードに順にアクセスすると共に、アクセスしたレコードに対応するセグメントについての前記実行基準が前記実行基準テーブルに登録されている場合には、前記アクセスしたレコードが前記実行基準に合致しているか否か判断し、前記実行基準に合致していると判断した前記レコードに対してのみ前記実行が指示された処理を実行する処理手段と、
を備えたデータベース管理装置であって、
前記処理手段が特定データベースに対して前記実行が指示された処理を行う前に、特定データベースの各セグメントのうち、実行基準テーブルに実行基準が登録されておらず、かつ関連付けられた下位階層のセグメントが存在しないか又は関連付けられた下位階層の各セグメントも実行基準テーブルに実行基準が登録されていないセグメントを検索し、検索によって抽出されたセグメントを前記階層順テーブルから削除したアクセス順序テーブルを前記階層順テーブルと別に作成するテーブル作成手段を備え、
前記処理手段は、前記テーブル作成手段によって作成されたアクセス順序テーブルを用いて特定データベースに対し前記実行が指示された処理を行う
ことを特徴とするデータベース管理装置。
A plurality of segments for registering different categories of information stored in the storage device are hierarchically related, and any number of records for registering specific category information is created for each segment. A hierarchical order table storage unit that stores a hierarchical order table that defines an access order in units of individual segments of the specific database when scanning the enabled specific database;
Any one of a deletion process for deleting a record, an update process for updating data registered in the record, and an extraction process for extracting data registered in the record for each record of a specific segment of the specific database A determination table storage means for storing an execution reference table registered with respect to an arbitrary segment of each segment of a specific database in units of individual segments.
When execution of any one of the processes for a specific database is instructed, each record of each segment is sequentially accessed according to the access order defined in the hierarchical order table, and the execution for the segment corresponding to the accessed record is performed. When a criterion is registered in the execution criterion table, it is determined whether or not the accessed record matches the execution criterion, and only for the record that is determined to match the execution criterion Processing means for executing the process instructed to execute;
A database management device comprising:
Before the processing means performs the processing instructed to be executed on the specific database, among the segments of the specific database, the execution standard is not registered in the execution standard table, and the associated lower-level segment there execution standard execution reference table is also the segment of absent or associated lower hierarchy to find a segment that is not registered, the access sequence table segments extracted and removed from the hierarchical order table by a search A table creation means for creating separately from the hierarchical order table ;
The processing means, a database management system and performs the processing of pairs and the execution is instructed on the particular database using the access sequence table created by the table creation means.
記憶装置に記憶された、互いに異なるカテゴリの情報を登録するための複数のセグメントが階層的に関連付けられた構造を有すると共に、特定カテゴリの情報を登録するためのレコードを各セグメントに任意の数作成可能とされた特定データベースをスキャンする際の、前記特定データベースの個々のセグメントを単位とするアクセス順序を規定する階層順テーブルを記憶する階層順テーブル記憶手段と、
前記特定データベースの特定のセグメントの各レコードに対する、レコードを削除する削除処理、レコードに登録されているデータを更新する更新処理、及び、レコードに登録されているデータを抽出する抽出処理の何れかの処理の実行基準を、個々のセグメントを単位として、特定データベースの各セグメントのうちの任意のセグメントについて登録した実行基準テーブルを記憶する判断テーブル記憶手段と、
が設けられたコンピュータが特定の処理を行うことで実現されるデータベース管理方法であって、
前記特定の処理は、
特定データベースの各セグメントのうち、実行基準テーブルに実行基準が登録されておらず、かつ関連付けられた下位階層のセグメントが存在しないか又は関連付けられた下位階層の各セグメントも実行基準テーブルに実行基準が登録されていないセグメントを検索し、検索によって抽出されたセグメントを前記階層順テーブルから削除したアクセス順序テーブルを前記階層順テーブルと別に作成する第1のステップ、
特定データベースに対する前記何れかの処理の実行が指示されると、前記第1のステップで作成したアクセス順序テーブルに規定されたアクセス順序に従って個々のセグメントの各レコードに順にアクセスすると共に、アクセスしたレコードに対応するセグメントについての前記実行基準が前記実行基準テーブルに登録されている場合には、前記アクセスしたレコードが前記実行基準に合致しているか否か判断し、前記実行基準に合致している と判断した前記レコードに対してのみ前記実行が指示された処理を実行する第2のステップ
を含むことを特徴とするデータベース管理方法。
A plurality of segments for registering different categories of information stored in the storage device are hierarchically related, and any number of records for registering specific category information is created for each segment. A hierarchical order table storage unit that stores a hierarchical order table that defines an access order in units of individual segments of the specific database when scanning the enabled specific database;
Any one of a deletion process for deleting a record, an update process for updating data registered in the record, and an extraction process for extracting data registered in the record for each record of a specific segment of the specific database A determination table storage means for storing an execution reference table registered with respect to an arbitrary segment of each segment of a specific database in units of individual segments.
Is a database management method realized by a computer provided with a specific process,
The specific process is:
Among the segments of the specific database, the execution criteria are not registered in the execution criteria table, and there is no associated lower-level segment, or the associated lower-level segments are also included in the execution criteria table. A first step of searching for an unregistered segment and creating an access order table in which the segment extracted by the search is deleted from the hierarchical order table separately from the hierarchical order table;
When execution of any one of the processes for the specific database is instructed, each record of each segment is sequentially accessed according to the access order defined in the access order table created in the first step, and the accessed record is determined that if the execution reference for the corresponding segment is registered in the execution reference table, records the access is judged whether or not matches the execution standard is consistent with the execution reference A second step of executing the process instructed to execute only the recorded record
It features and to Lud database management method comprises a.
記憶装置に記憶された、互いに異なるカテゴリの情報を登録するための複数のセグメントが階層的に関連付けられた構造を有すると共に、特定カテゴリの情報を登録するためのレコードを各セグメントに任意の数作成可能とされた特定データベースをスキャンする際の、前記特定データベースの個々のセグメントを単位とするアクセス順序を規定する階層順テーブルを記憶する階層順テーブル記憶手段と、A plurality of segments for registering different categories of information stored in the storage device are hierarchically related, and any number of records for registering specific category information is created for each segment. A hierarchical order table storage unit that stores a hierarchical order table that defines an access order in units of individual segments of the specific database when scanning the enabled specific database;
前記特定データベースの特定のセグメントの各レコードに対する、レコードを削除する削除処理、レコードに登録されているデータを更新する更新処理、及び、レコードに登録されているデータを抽出する抽出処理の何れかの処理の実行基準を、個々のセグメントを単位として、特定データベースの各セグメントのうちの任意のセグメントについて登録した実行基準テーブルを記憶する判断テーブル記憶手段と、Any one of a deletion process for deleting a record, an update process for updating data registered in the record, and an extraction process for extracting data registered in the record for each record of a specific segment of the specific database A determination table storage means for storing an execution reference table registered for an arbitrary segment of each segment of a specific database, with each process as a unit of processing execution criteria;
が設けられたコンピュータに特定の処理を実行させるためのプログラムであって、Is a program for causing a computer provided with to execute a specific process,
前記特定の処理は、The specific process is:
特定データベースの各セグメントのうち、実行基準テーブルに実行基準が登録されておらず、かつ関連付けられた下位階層のセグメントが存在しないか又は関連付けられた下位階層の各セグメントも実行基準テーブルに実行基準が登録されていないセグメントを検索し、検索によって抽出されたセグメントを前記階層順テーブルから削除したアクセス順序テーブルを前記階層順テーブルと別に作成する第1のステップ、Among the segments of the specific database, the execution criteria are not registered in the execution criteria table, and there is no associated lower-level segment, or the associated lower-level segments are also included in the execution criteria table. A first step of searching for an unregistered segment and creating an access order table in which the segment extracted by the search is deleted from the hierarchical order table separately from the hierarchical order table;
特定データベースに対する前記何れかの処理の実行が指示されると、前記第1のステップで作成したアクセス順序テーブルに規定されたアクセス順序に従って個々のセグメントの各レコードに順にアクセスすると共に、アクセスしたレコードに対応するセグメントについての前記実行基準が前記実行基準テーブルに登録されている場合には、前記アクセスしたレコードが前記実行基準に合致しているか否か判断し、前記実行基準に合致していると判断した前記レコードに対してのみ前記実行が指示された処理を実行する第2のステップWhen execution of any one of the processes for the specific database is instructed, each record of each segment is sequentially accessed according to the access order defined in the access order table created in the first step, and the accessed record is If the execution criterion for the corresponding segment is registered in the execution criterion table, it is determined whether the accessed record matches the execution criterion, and is determined to match the execution criterion. A second step of executing the process instructed to execute only the recorded record
を含むことを特徴とするプログラム。The program characterized by including.
記憶装置に記憶された、互いに異なるカテゴリの情報を登録するための複数のセグメントが階層的に関連付けられた構造を有すると共に、特定カテゴリの情報を登録するためのレコードを各セグメントに任意の数作成可能とされた特定データベースをスキャンする際の、前記特定データベースの個々のセグメントを単位とするアクセス順序を規定する階層順テーブルを記憶する階層順テーブル記憶手段と、A plurality of segments for registering different categories of information stored in the storage device are hierarchically related, and any number of records for registering specific category information is created for each segment. A hierarchical order table storage unit that stores a hierarchical order table that defines an access order in units of individual segments of the specific database when scanning the enabled specific database;
前記特定データベースの特定のセグメントの各レコードに対する、レコードを削除する削除処理、レコードに登録されているデータを更新する更新処理、及び、レコードに登録されているデータを抽出する抽出処理の何れかの処理の実行基準を、個々のセグメントを単位として、特定データベースの各セグメントのうちの任意のセグメントについて登録した実行基準テーブルを記憶する判断テーブル記憶手段と、Any one of a deletion process for deleting a record, an update process for updating data registered in the record, and an extraction process for extracting data registered in the record for each record of a specific segment of the specific database A determination table storage means for storing an execution reference table registered for an arbitrary segment of each segment of a specific database, with each process as a unit of processing execution criteria;
が設けられたコンピュータに特定の処理を実行させるためのプログラムが記録された記録媒体であって、A recording medium on which is recorded a program for causing a computer provided with
前記特定の処理は、The specific process is:
特定データベースの各セグメントのうち、実行基準テーブルに実行基準が登録されておらず、かつ関連付けられた下位階層のセグメントが存在しないか又は関連付けられた下位階層の各セグメントも実行基準テーブルに実行基準が登録されていないセグメントを検索し、検索によって抽出されたセグメントを前記階層順テーブルから削除したアクセス順序テーブルを前記階層順テーブルと別に作成する第1のステップ、Among the segments of the specific database, the execution criteria are not registered in the execution criteria table, and there is no associated lower-level segment, or the associated lower-level segments are also included in the execution criteria table. A first step of searching for an unregistered segment and creating an access order table in which the segment extracted by the search is deleted from the hierarchical order table separately from the hierarchical order table;
特定データベースに対する前記何れかの処理の実行が指示されると、前記第1のステップで作成したアクセス順序テーブルに規定されたアクセス順序に従って個々のセグメントの各レコードに順にアクセスすると共に、アクセスしたレコードに対応するセグメントについての前記実行基準が前記実行基準テーブルに登録されている場合には、前記アクセスWhen execution of any one of the processes for the specific database is instructed, each record of each segment is sequentially accessed according to the access order defined in the access order table created in the first step, and the accessed record is If the execution criteria for the corresponding segment are registered in the execution criteria table, the access したレコードが前記実行基準に合致しているか否か判断し、前記実行基準に合致していると判断した前記レコードに対してのみ前記実行が指示された処理を実行する第2のステップA second step of determining whether or not the recorded record matches the execution criterion, and executing the process instructed to execute only the record that is determined to match the execution criterion
を含むことを特徴とする記録媒体。A recording medium comprising:
JP2001288555A 2001-09-21 2001-09-21 Database management apparatus, method, program, and recording medium Expired - Fee Related JP3772105B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2001288555A JP3772105B2 (en) 2001-09-21 2001-09-21 Database management apparatus, method, program, and recording medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2001288555A JP3772105B2 (en) 2001-09-21 2001-09-21 Database management apparatus, method, program, and recording medium

Publications (2)

Publication Number Publication Date
JP2003099300A JP2003099300A (en) 2003-04-04
JP3772105B2 true JP3772105B2 (en) 2006-05-10

Family

ID=19111182

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2001288555A Expired - Fee Related JP3772105B2 (en) 2001-09-21 2001-09-21 Database management apparatus, method, program, and recording medium

Country Status (1)

Country Link
JP (1) JP3772105B2 (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7333992B2 (en) * 2003-05-22 2008-02-19 Microsoft Corporation System and method for identifying and storing changes made to a table
CN104217165B (en) * 2014-09-16 2016-07-06 百度在线网络技术(北京)有限公司 The processing method of file and device
CN113157736B (en) * 2021-04-28 2024-01-05 联通沃音乐文化有限公司 Query plan optimization method and system in distributed database

Also Published As

Publication number Publication date
JP2003099300A (en) 2003-04-04

Similar Documents

Publication Publication Date Title
US10482134B2 (en) Document management techniques to account for user-specific patterns in document metadata
US6711566B2 (en) Database processing method and apparatus using handle
US6449607B1 (en) Disk storage with modifiable data management function
EP1039380A2 (en) Method and data format for exchanging data between a java system database entry and an ldap directory
JP2004348744A (en) Identification method for identifying change carried out for table, and its system
JP7223097B2 (en) Journal data creation device, journal data creation method and journal data creation program
US20080098013A1 (en) Data access and communication system
JP3772105B2 (en) Database management apparatus, method, program, and recording medium
US7856457B1 (en) Uniquely identifying an object before it is stored in a database
CN112181248A (en) Operation method and device of history list
JP2001147923A (en) Device and method for retrieving similar document and recording medium
JP7312157B2 (en) Credit information inquiry device, credit information inquiry method, and credit information inquiry program
JP2679602B2 (en) Evacuation medium creation system
JP7250652B2 (en) Withdrawal Result Update Device, Withdrawal Result Update Method, and Withdrawal Result Update Program
JP6947596B2 (en) Deposit processing device, deposit processing method, and deposit processing program
JPH11184889A (en) Image data management device
JPH07334406A (en) Multi-media data base system
KR20000014913A (en) Online personal directory providing service system and method thereof
JP4447808B2 (en) How to provide updated data
CN113177828A (en) Article recommendation method, device, equipment and storage medium
US20010021933A1 (en) Data processing system with file memory and data processing method
JP2000123038A (en) Database device, database access method and recording medium recorded with database access program
AU2004201570B2 (en) Data access and communication system
JPH05181715A (en) Master management system
JPH02253451A (en) Data base managing system

Legal Events

Date Code Title Description
A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20050920

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20051025

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: 20060207

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20060213

R150 Certificate of patent or registration of utility model

Free format text: JAPANESE INTERMEDIATE CODE: R150

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

Free format text: PAYMENT UNTIL: 20120217

Year of fee payment: 6

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

Free format text: PAYMENT UNTIL: 20120217

Year of fee payment: 6

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

Free format text: PAYMENT UNTIL: 20150217

Year of fee payment: 9

LAPS Cancellation because of no payment of annual fees