JPS63118931A - Data base managing system - Google Patents

Data base managing system

Info

Publication number
JPS63118931A
JPS63118931A JP26383286A JP26383286A JPS63118931A JP S63118931 A JPS63118931 A JP S63118931A JP 26383286 A JP26383286 A JP 26383286A JP 26383286 A JP26383286 A JP 26383286A JP S63118931 A JPS63118931 A JP S63118931A
Authority
JP
Japan
Prior art keywords
record
child
file
slave
parent
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP26383286A
Other languages
Japanese (ja)
Inventor
Toshimasa Matsubara
松原 俊昌
Takashi Owaki
大脇 隆志
Atsuhiko Hirota
敦彦 廣田
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.)
Hitachi Ltd
Hitachi Information and Control Systems Inc
Original Assignee
Hitachi Ltd
Hitachi Process Computer Engineering Inc
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Hitachi Ltd, Hitachi Process Computer Engineering Inc filed Critical Hitachi Ltd
Priority to JP26383286A priority Critical patent/JPS63118931A/en
Publication of JPS63118931A publication Critical patent/JPS63118931A/en
Pending legal-status Critical Current

Links

Landscapes

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

Abstract

PURPOSE:To improve the performance of the parallel processing of a task which accesses to a data base, by storing slave records in every master record unit separately in different files, and managing relation between the master record and the slave record based on file identification information. CONSTITUTION:When the slave record (a) relating to the master record A is added, a relative managing memory 8 is retrieved based on the key value of the master record A, and the file identification information of the slave record 5 on which the slave record (a) is to be added, is taken out, and the slave record (a) a added on a vacant record in the said file base on the above information. Also, when the slave record (a) relating to the master record A is deleted, after the slave record 5 in which the slave record exists, is decided, the slave record (a) to be deleted is retrieved and deleted. When the slave record (a) relating to the master record A is retrieved, the slave record 5 in which the slave record exists is decided, and the slave record (a) is deleted from the said file.

Description

【発明の詳細な説明】 〔産業上の利用分野〕 本発明はデータベース管理システムに係り、特に階層構
造を持つデータの処理に好適な、データベース管理方式
及び装置に関する。
DETAILED DESCRIPTION OF THE INVENTION [Field of Industrial Application] The present invention relates to a database management system, and particularly to a database management method and apparatus suitable for processing data having a hierarchical structure.

〔従来の技術〕[Conventional technology]

文献データベースシステムの原理(日本コンピュータ協
会)の「階層構造を有するデータベースの実現方式」の
項で述べられているように、従来レコードの親子関係を
、第2図に示すような方法で管理することが知られてい
る。すなわち第2−(1)図において親レコードAに関
連する子レコ−ドa、b、cをポインタ3で示される循
環鎖で連結し管理する方法や、第2− (2)図のよう
な多重ポインタ3′で管理する方法である。
As stated in the "Method for realizing a database with a hierarchical structure" section of Principles of Document Database Systems (Japan Computer Association), parent-child relationships of records have traditionally been managed using the method shown in Figure 2. It has been known. In other words, there is a method of connecting and managing child records a, b, and c related to parent record A in Figure 2-(1) in a circular chain indicated by pointer 3, or a method of managing child records a, b, and c related to parent record A as shown in Figure 2-(2). This is a method of managing using multiple pointers 3'.

〔発明が解決しようとする問題点〕[Problem that the invention seeks to solve]

上記従来技術には、以下の問題があった。 The above conventional technology has the following problems.

第3図は、従来技術により在庫管理を行うデータベース
を実現した例である。在庫管理データベースは倉庫ファ
イルと部品ファイルから成り、倉庫ファイルには倉庫名
が、部品ファイルには、部品#と在庫数がデータとして
セットされており。
FIG. 3 is an example of a database for managing inventory using the conventional technology. The inventory management database consists of a warehouse file and a parts file, where the warehouse name is set as data in the warehouse file, and the part number and inventory quantity are set in the parts file.

倉庫と該倉庫格納されている部品とをポインタで結ぶこ
とにより管理している。また上記データベースは、倉庫
への部品の搬入を行うタスク又と。
Management is performed by connecting the warehouse and the parts stored in the warehouse with pointers. The above database is also used for tasks such as transporting parts to the warehouse.

倉庫からの部品の搬出を行うタスクYにより管理されて
いる。今、部品#10の部品を倉庫Aに搬入するようオ
ペレータが端末1より指示すると、タスクXが起動され
、部品ファイルにデータが書き込まれる。タスクXが部
品ファイルにデータの追加及び更新を行っている最中に
端末2より部品#20の部品を倉庫Aから搬出する指示
がなされた場合、タスクYが起動され部品#20のデー
タ゛の更新、削除を行うが、XとYが同時に動作すると
、ポインタのつなぎかえや、データ操作に不整合が生じ
てしまう。この為、タスクXは部び#10のデータを追
加、更新する際、部品ファイルの施錠が必要となる。こ
れにより、タスクYは、タスクXによる部品#10のデ
ータの追加、更新が終了するまで待ちとなり、データの
不整合は発生しない、しかし、タスクAの動作中に倉庫
Bに対し、部品#30の部品の搬出の指示によりタスク
Yが起動され、部品#30の部品データの更新、削除を
行う場合、タスクYはタスクAに対して影響を与えない
にもかかわらず、タスクAにより部品ファイルが施錠さ
れている為に待ちが発生し、並行処理性が低下してしま
う。
It is managed by task Y, which carries out parts removal from the warehouse. Now, when the operator instructs from terminal 1 to carry part #10 into warehouse A, task X is activated and data is written to the parts file. When Task , deletion is performed, but if X and Y operate at the same time, inconsistencies will occur in pointer reconnection and data operations. Therefore, when task X adds or updates the data of part #10, it is necessary to lock the part file. As a result, task Y waits until task X finishes adding and updating the data of part #10, and no data inconsistency occurs. When task Y is activated by an instruction to export part #30 and updates or deletes the part data of part #30, task A may change the part file by task A, even though task Y has no effect on task A. Because it is locked, waiting occurs and parallel processing performance decreases.

また、倉庫Aに搬入する部品の種類が多くなるほど搬入
搬出の指示のあった部品を、ポインタをたどって捜し出
すのに時間がかかり、タスクX、Yの処理速度が低下し
てしまう。これに対し、ポインタをたどる時間を減らす
為、第2図−(2)の方式により実現すると、ポインタ
をたどる時間は小さくなるが、1つの倉庫に搬入できる
部品の種類の数に制限が必要となる。
Furthermore, as the number of types of parts to be delivered to warehouse A increases, it takes more time to follow the pointer and find the parts for which import/export instructions have been given, and the processing speed of tasks X and Y decreases. On the other hand, if the method shown in Figure 2-(2) is used to reduce the time required to follow the pointer, the time required to follow the pointer will be reduced, but the number of types of parts that can be delivered to one warehouse will need to be limited. Become.

また、タスクXが新しく部品#40の部品を倉庫Aに追
加する処理を行っている最中に、電源断等により計算機
の処理が停止した場合、ポインタが切れてしまい、以後
、部品ファイルの操作ができなくなる場合がある。そし
て、部品ファイルへの部品の搬入、搬出処理が頻繁に発
生する場合、ポインタのつなぎかえも頻繁に発生する為
、ポインタ切れが発生する確率も高くなるというような
問題があった。
Additionally, if the computer stops processing due to a power outage while Task It may become impossible to do so. Furthermore, when loading and unloading of components into a component file occurs frequently, pointers are also frequently reconnected, which increases the probability of pointer breakage.

以上、述べたように、従来の方式においては、(1)フ
ァイルの占有範囲を局所化できないためタスクの並行処
理性が低下すること (2)ポインタ検索時のオーバーヘッドの増加により処
理速度が低下すること (3)データベースの局所的な障害が、全てのレコード
に波及し、信頼性が帝低下することという開運があった
As mentioned above, in the conventional method, (1) task parallelism decreases because the occupied range of the file cannot be localized, and (2) processing speed decreases due to increased overhead when searching for pointers. (3) A local failure in the database spread to all records, resulting in a significant decline in reliability.

〔問題点を解決するための手段〕[Means for solving problems]

以上の問題点を解決する為、本発明においては、(1)
、親レコードに関連す子レコードを、親レコード単位に
別々のファイルに格納し、親レコードと子レコードの関
連を、子レコードを分割して格納したファイル識別情報
により管理する。
In order to solve the above problems, in the present invention, (1)
, child records related to a parent record are stored in separate files for each parent record, and the relationship between the parent record and the child record is managed using file identification information stored after dividing the child record.

(2)タスクの競合管理を、(1)の手段により分割し
て格納したファイル単位に行う。
(2) Task conflict management is performed in units of files that are divided and stored using the method of (1).

(3)障害が発生した場合、(1)の手段により分割し
て格納したファイル単位に、障害回復を行う。
(3) When a failure occurs, failure recovery is performed in units of files that have been divided and stored using the method of (1).

ことを特徴とする1次に本発明の原理を第1図により説
明する。
First, the principle of the present invention, which is characterized by the following, will be explained with reference to FIG.

第1図は、ファイル識別情報により親レコードと子レコ
ードの関係を管理する場合の説明図である。親レコード
Aに関連する子レコードaを追加する場合、親レコード
Aのキー値をもとに、関連管理メモリ8を検索し、子レ
コードaを追加する子ファイル5のファイル識別情報取
り出す。これをもとに該ファイルの空きレコードに子レ
コードaを追加する。関連管理メモリ8は、第4図で示
されるように親レコードのキー値、子ファイル識別情報
から構成され、親レコードが追加された時点で、対応す
る子ファイルを生成しファイル識別情報を付加した後、
これらの情報を関連管理メモリ8に設定する。また、親
レコードが削除された時点で、これらの情報も削除され
る。さらに、親レコードに対し、キー値を1=1に対応
する自然数(例えば親レコード格納レコード番号)を用
いる場合には、関連管理情報上の親レコードキー値の代
わりに管理情報ケースNoを用いることも可能である。
FIG. 1 is an explanatory diagram when the relationship between parent records and child records is managed using file identification information. When adding a child record a related to a parent record A, the association management memory 8 is searched based on the key value of the parent record A, and the file identification information of the child file 5 to which the child record a is to be added is retrieved. Based on this, a child record a is added to the empty record of the file. As shown in FIG. 4, the related management memory 8 is composed of key values of parent records and child file identification information, and when a parent record is added, a corresponding child file is generated and file identification information is added. rear,
These pieces of information are set in the related management memory 8. Additionally, when the parent record is deleted, this information is also deleted. Furthermore, when using a natural number corresponding to 1=1 as the key value (for example, parent record storage record number) for the parent record, use the management information case number instead of the parent record key value on the related management information. is also possible.

親レコードAに関連する子レコードaを削除する場合に
は、追加の場合と同様にして子レコードが存在する子フ
ァイル5を決定した後、削除する子レコードaを該ファ
イルより検索し削除する。親レコードAに関連する子レ
コードaを検索する場合、追加の場合と同様にして子レ
コードが存在する子ファイル5を決定し、該ファイルよ
り子レコードaを検索することができる。
When deleting a child record a related to a parent record A, the child file 5 in which the child record exists is determined in the same way as in the case of addition, and then the child record a to be deleted is searched from the file and deleted. When searching for child record a related to parent record A, it is possible to determine the child file 5 in which the child record exists in the same way as in the case of addition, and search for child record a from this file.

〔作用〕[Effect]

本発明では、 (1)子レコードを分割したファイル単位に占有、解除
することが可能であり、異なる親レコードからアクセス
するタスクを同時に動作させることができるようになる
In the present invention, (1) Child records can be occupied and released in divided file units, and tasks accessing from different parent records can be performed simultaneously.

(2)ポインタを持たない為、1つの親レコードに関連
する子レコード数が大きくなっても、子レコードを検索
する際のオーバーヘッドに与える影響が少なくなる6 (3)子レコードが存在するファイルは、同一の親レコ
ードを有する子レコードのみで構成されるようにするの
で子レコードが物理的に隣接している記憶上に配置され
検索時のディスク170回数が減少する。
(2) Since there is no pointer, even if the number of child records related to one parent record becomes large, the impact on the overhead when searching for child records is reduced.6 (3) The file in which child records exist is Since the child records are composed only of child records having the same parent record, the child records are arranged in physically adjacent storages, and the number of times the disk 170 is searched is reduced.

(4)ポインタのような動的に変化する関連情報を持た
ないようにしているため障害が発生しにくい。
(4) Failures are less likely to occur because dynamically changing related information such as pointers is not included.

(5)障害が発生した場合にも、分割したファイル単位
に障害回復を行えばよいようになる。
(5) Even if a failure occurs, failure recovery can be performed in units of divided files.

〔実施例〕〔Example〕

以下、本発明の一実施例を図に従い説明する。 An embodiment of the present invention will be described below with reference to the drawings.

在庫管理データベースの例において、第1図の親ファイ
ル1を倉庫ファイル、子ファイル5,6゜7を部品ファ
イルとして本発明により実施した例が第5図である。今
、倉JiAに部品#10の部品を搬入する指示により、
タスクXが部品ファイル11に部品#10のデータの追
加、更新を行っている間、搬出タスクYが同時に部品フ
ァイル11をアクセスし、データの整合性が失われるこ
とを防ぐため1部品ファイル11は施錠される。
FIG. 5 shows an example of an inventory management database implemented according to the present invention, with the parent file 1 in FIG. 1 as a warehouse file and the child files 5, 6 and 7 as parts files. Now, according to the instructions to bring part #10 to warehouse JiA,
While task It will be locked.

しかし、本発明では、部品ファイルが親レコード単位に
分割管理されている為、施錠を部品ファイル11だけに
局所化でき、搬出タスクYは搬入タスクXがアクセス中
の倉庫A以外の親レコードに関連する部品ファイル12
.13に対しては、搬入タスクXと同時アクセスが可能
となる。
However, in the present invention, since parts files are divided and managed in parent record units, locking can be localized only to parts file 11, and export task Y is related to parent records other than warehouse A that import task X is accessing. Parts file 12
.. 13 can be accessed simultaneously with import task X.

また、部品ファイルへのアクセス中に電源断等により計
算機の処理が停止し、部品ファイルに障害が発生した場
合、従来は第3図の部品ファイル全体がアクセス不能と
なり、障害発生前に退避した該ファイルデータに戻すか
、該ファイルをイニシャルした後、再度データを登録し
直すことにより部品ファイル全体を修復する必要があっ
た。これに対し1本発明の場合、第6図において、部品
ファイル6に障害が発生した場合障害が発生した部品フ
ァイル6だけに対し、バックアップファイル10より旧
データのロードを行うか、又はファイル6だけをイニシ
ャル後、再度データを登録する方法を取ることにより障
害を局所化できまた障害発生以外の部品ファイル5,7
はアクセス可能である為システムへの影響を最小限に押
えることができる。また回復データ量も少ないため、障
害回復に要する時間を短縮することができる。
Additionally, if computer processing is stopped due to a power cut, etc. while accessing a part file, and a failure occurs in the part file, the entire part file shown in Figure 3 becomes inaccessible, and the part file that was evacuated before the failure occurs. It was necessary to restore the entire part file by restoring it to file data or initializing the file and then registering the data again. On the other hand, in the case of the present invention, as shown in FIG. 6, when a failure occurs in the component file 6, old data is loaded from the backup file 10 only for the component file 6 where the failure has occurred, or only for the file 6. By registering the data again after initializing , the fault can be localized and the parts files 5 and 7 other than those in which the fault has occurred can be localized.
is accessible, so the impact on the system can be kept to a minimum. Furthermore, since the amount of data to be recovered is small, the time required for failure recovery can be shortened.

〔発明の効果〕〔Effect of the invention〕

本発明によれば、階層構造を有するデータベースにおい
て、 (1)ファイルの競合管理を細かく行えるので、該デー
タベースにアクセスするタスクの並行処理性を向上させ
ることができる。
According to the present invention, in a database having a hierarchical structure, (1) file conflict management can be performed in detail, so that the parallel processing performance of tasks accessing the database can be improved.

(2)障害が発生した場合、子レコードを分割したファ
イル単位に障害回復が行えるので、保守性の向上が図れ
る。
(2) When a failure occurs, failure recovery can be performed in units of files into which child records are divided, so maintainability can be improved.

(3)ポインタを持たないため、信頼性の高いデータベ
ース管理が行える。
(3) Since there are no pointers, highly reliable database management is possible.

(4)ポインタを持たない為、子レコードの増大による
オーバーヘッドへの影響が少なく、またI10回数が削
限できるため、処理速度の向上が図れるといった結果を
得ることができる。
(4) Since there is no pointer, there is less impact on overhead due to an increase in child records, and the number of I10s can be reduced, resulting in improved processing speed.

【図面の簡単な説明】[Brief explanation of the drawing]

第1図は本発明の一実施例の構成説明図、第2図は階層
構造を有するデータベースを従来技術により実現した場
合の説明図、第3図は従来技術を示す説明図、第4図は
関連管理メモリの説明図。 第5図は本発明による実施例の説明図、第6図は障害回
復についての説明図である。 1・・・親ファイル、2・・・子ファイル、A、B、C
・・・躬1図 6−−一 闇遵営工!メtソ 延3図 も(+、図 高5図
Fig. 1 is an explanatory diagram of the configuration of an embodiment of the present invention, Fig. 2 is an explanatory diagram of a case where a database with a hierarchical structure is realized by the conventional technology, Fig. 3 is an explanatory diagram showing the conventional technology, and Fig. 4 is an explanatory diagram of the conventional technology. An explanatory diagram of related management memory. FIG. 5 is an explanatory diagram of an embodiment according to the present invention, and FIG. 6 is an explanatory diagram of failure recovery. 1...Parent file, 2...Child file, A, B, C
... 1 Figure 6--1 Darkness! Metso extension figure 3 (+, figure height 5 figure

Claims (1)

【特許請求の範囲】[Claims] 1、親レコードと子レコードとの関連を管理し、親レコ
ードを一意に特定することにより、該親レコードに関連
する子レコード群を自動的に検索することを可能とする
データベース管理システムにおいて、子レコード群を複
数のファイルに分割して格納し、親レコードと子レコー
ドとの関連を、分割された子レコードの格納ファイル識
別情報により記憶し、親レコードに対して子レコードの
追加を行う場合には、親レコードに関連する分割された
子レコードの格納ファイル識別情報より、子レコードを
格納する、ファイルを一意に決定し、該ファイルへ子レ
コードを追加し、親レコードに対して子レコードの削除
を行う場合には、親レコードに関連する分割された子レ
コードの格納ファイル識別情報より、子レコードが格納
されているファイルを一意に決定した後、該ファイル内
を検索し、該当する子レコードを削除し、親レコードに
対して子レコードの検索を行う場合には、親レコードに
関連する分割された子レコードの格納ファイル識別情報
より、子レコードが格納されているファイルを一意に決
定した後、該ファイル内を検索し、該当する子レコード
を求めることを特徴とするデータベース管理方式。
1. In a database management system that manages the relationship between parent records and child records and uniquely identifies a parent record, it is possible to automatically search for a group of child records related to the parent record. When storing a record group by dividing it into multiple files, storing the relationship between parent records and child records using the storage file identification information of the divided child records, and adding child records to the parent record. uniquely determines the file that stores the child record from the storage file identification information of the divided child record related to the parent record, adds the child record to the file, and deletes the child record from the parent record. When doing this, after uniquely determining the file in which the child record is stored based on the storage file identification information of the divided child record related to the parent record, the file is searched and the corresponding child record is searched. When deleting a parent record and searching for a child record, the file in which the child record is stored is uniquely determined from the storage file identification information of the divided child record related to the parent record, and then A database management method characterized by searching within the file to find a corresponding child record.
JP26383286A 1986-11-07 1986-11-07 Data base managing system Pending JPS63118931A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP26383286A JPS63118931A (en) 1986-11-07 1986-11-07 Data base managing system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP26383286A JPS63118931A (en) 1986-11-07 1986-11-07 Data base managing system

Publications (1)

Publication Number Publication Date
JPS63118931A true JPS63118931A (en) 1988-05-23

Family

ID=17394843

Family Applications (1)

Application Number Title Priority Date Filing Date
JP26383286A Pending JPS63118931A (en) 1986-11-07 1986-11-07 Data base managing system

Country Status (1)

Country Link
JP (1) JPS63118931A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO1994004623A1 (en) * 1992-08-24 1994-03-03 Battelle Memorial Institute Process for glueing two non-metallic substrates by means of an adhesive

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO1994004623A1 (en) * 1992-08-24 1994-03-03 Battelle Memorial Institute Process for glueing two non-metallic substrates by means of an adhesive

Similar Documents

Publication Publication Date Title
US10657008B2 (en) Managing a redundant computerized database using a replicated database cache
EP0336546B1 (en) System and method for data recovery in a database on a computer system after an error in the system
US6519613B1 (en) Non-blocking drain method and apparatus for use in processing requests on a resource
US5832508A (en) Method for deallocating a log in database systems
US5261088A (en) Managing locality in space reuse in a shadow written B-tree via interior node free space list
EP1918836B1 (en) Apparatus and method for a hardware-based file system
US7840539B2 (en) Method and system for building a database from backup data images
US6092087A (en) Log file optimization in a client/server computing system
US7257690B1 (en) Log-structured temporal shadow store
US6085200A (en) System and method for arranging database restoration data for efficient data recovery in transaction processing systems
EP0336035B1 (en) Tree structure database system
US7222133B1 (en) Method for reducing database recovery time
US8214377B2 (en) Method, system, and program for managing groups of objects when there are different group types
US6772177B2 (en) System and method for parallelizing file archival and retrieval
EP0501160A2 (en) Intelligent page store for concurrent and consistent access to a database by a transaction processor and a query processor
US5740434A (en) System for maintenance of database integrity
JPH0552972B2 (en)
US6230243B1 (en) Method, system and program products for managing changed data of castout classes
US8452730B2 (en) Archiving method and system
JP3378594B2 (en) Processing unit that performs database relocation
US20060004846A1 (en) Low-overhead relational database backup and restore operations
JPS63118931A (en) Data base managing system
Troisi NonStop SQL/MP availability and database configuration operations
Chong et al. Rapid Recovery of Very Large Memory Resident Data Objects
JPH03288944A (en) Method and device for reconstituting data base under use