JPH04101244A - Multi-sectioned data controlling system in small computer - Google Patents
Multi-sectioned data controlling system in small computerInfo
- Publication number
- JPH04101244A JPH04101244A JP2218685A JP21868590A JPH04101244A JP H04101244 A JPH04101244 A JP H04101244A JP 2218685 A JP2218685 A JP 2218685A JP 21868590 A JP21868590 A JP 21868590A JP H04101244 A JPH04101244 A JP H04101244A
- Authority
- JP
- Japan
- Prior art keywords
- data
- file
- storage area
- record
- index
- 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
Links
- 238000013500 data storage Methods 0.000 claims description 82
- 238000013523 data management Methods 0.000 claims description 28
- 238000000034 method Methods 0.000 claims description 17
- 238000005192 partition Methods 0.000 claims description 6
- 238000012217 deletion Methods 0.000 abstract description 12
- 230000037430 deletion Effects 0.000 abstract description 9
- 238000010586 diagram Methods 0.000 description 10
- 239000000047 product Substances 0.000 description 9
- 230000000694 effects Effects 0.000 description 5
- 239000006227 byproduct Substances 0.000 description 2
- 238000007796 conventional method Methods 0.000 description 1
- 239000002699 waste material Substances 0.000 description 1
Landscapes
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
Abstract
Description
【発明の詳細な説明】
〔産業上の利用分野〕
本発明は、メインメモリのメモリサイズに限りのある小
型計算機においてディスクファイル装置内の多区分デー
タ(日毎の商品売上データのようにデータ区分数が複数
あるデータ)の格納、検索および削除等を行う小型計算
iにおける多区分データ管理方式に関する。[Detailed Description of the Invention] [Industrial Application Field] The present invention is a compact computer with a limited main memory size, and is capable of storing multi-section data (such as daily product sales data) in a disk file device. This invention relates to a multi-section data management method in a small computer i that stores, searches, deletes, etc.
従来、この種の小型計算機における多区分データ管理方
式では、データファイルとデータ区分毎に割り当てられ
たインデックスを有するインデックスファイルとが用い
られ、データファイルに格納されるデータが規定のデー
タ区分に基づいて分類されてからデータファイルに格納
され、そのデータ区分に該当するインデックスにそのデ
ータのデータ格納位置に関する情報が格納されていた。Conventionally, in the multi-section data management method for this type of small computer, a data file and an index file having an index assigned to each data section are used, and the data stored in the data file is classified based on the specified data section. After the data is classified, it is stored in a data file, and information regarding the data storage position of the data is stored in the index corresponding to the data classification.
第3図(a)および(b)は、データ区分がABおよび
Cの3つである場合の従来の小型計算機における多区分
データ管理方式の一例の動作を示す図である(あ(まで
も、格納状態をモデル的に表現した図である)。FIGS. 3(a) and 3(b) are diagrams showing the operation of an example of a multi-section data management method in a conventional small-sized computer when there are three data sections AB and C. (This is a model representation of the storage state.)
データの発生順序がAl、B1.B2.ClA2.C2
,B3.A3.A4およびC3である場合には、データ
ファイル内のデータの格納状態およびインデックスファ
イル内の各インテ・ノクス(データ区分Aに対するイン
デックスID、A。The data generation order is Al, B1. B2. ClA2. C2
,B3. A3. In the case of A4 and C3, the storage state of data in the data file and each inte node in the index file (index ID for data division A, A.
データ区分Bに対するインデックスID、Bおよびデー
タ区分Cに対するインテ・ノクスID、C)中のデータ
格納位置を示す情報(データファイルの相対レコード位
置番号)の格納状態は第3図(a)に示すようになる。The storage status of the index ID for data section B, the inte node ID for B and data section C, and the information indicating the data storage position (relative record position number of the data file) in C) is as shown in Figure 3 (a). become.
第3図(a)に示す状態である場合に、新たなデータが
A5.B4.B5.A6およびC4の順に発生した場合
には、データファイル内のデータの格納状態およびイン
デックスファイル内のデータ格納位置を示す情報の格納
状態は第3図(b)に示すようになる。In the case of the state shown in FIG. 3(a), new data is A5. B4. B5. When A6 and C4 occur in this order, the storage state of data in the data file and the storage state of information indicating the data storage position in the index file are as shown in FIG. 3(b).
第3図(b)に示す状態のデータファイルからデータ区
分Aに分類されているデータが検索される場合には、同
図中のインデックスファイル内のデータ区分φに対する
インデックスID、A中のデータ格納位置が参照されて
データ区分Aに分類されたデータのデータファイルにお
けるデータ格納位置が認識され、目的のデータA1〜A
6が取り出される。When data classified into data category A is retrieved from a data file in the state shown in FIG. 3(b), the index ID for data category φ in the index file in the same figure, the data storage in A, The location is referenced and the data storage location in the data file of the data classified into data category A is recognized, and the target data A1 to A
6 is taken out.
上述した従来の小型計算機における多区分データ管理方
式では、データ格納位置に関する情報がインデックスフ
ァイルにだけ格納されているので、データ区分毎のデー
タ数に比例して各インデックスに格納されるデータ格納
位置に関する情報の数が変動する。ここで、データ検索
の効率をよくするために、インデックスファイル内の各
インデックスを同一の大きさでかつ連続した領域に確保
したい。したがって、インデックスの大きさはデータ区
分の中でデータ量が最大となるものの大きさに統一して
おく必要がある。In the above-mentioned conventional multi-section data management method for small computers, information regarding the data storage location is stored only in the index file, so information regarding the data storage location stored in each index is proportional to the number of data for each data section. The number of information changes. In order to improve data search efficiency, we want to ensure that each index in the index file has the same size and is located in a continuous area. Therefore, it is necessary to unify the size of the index to the size of the data division that has the largest amount of data.
以上のことから、従来の小型計算機における多区分デー
タ管理方式には以下に示すような欠点がある。From the above, the conventional multi-section data management method for small computers has the following drawbacks.
まず、データ区分の設定によっては、インテ。First of all, depending on the data classification settings, the int.
クスファイルに未使用部分が多く発生する。There are many unused parts in the file.
また、インデックスファイルの情報をメインメモリに展
開する場合に、データ量が最大のデータ区分に対するイ
ンデックスを展開できる領域をメインメモリ内に専有し
なければならず、メインメモリの利用効率が低下する。Furthermore, when the information in the index file is expanded into the main memory, an area in which the index for the data section with the largest amount of data can be expanded must be exclusively occupied in the main memory, which reduces the efficiency of use of the main memory.
さらに、インデックスに格納可能なデータ格納位置に関
する情報の最大数を越えるデータ量が特定のデータ区分
で発生すると、たとえデータファイルに余裕があっても
そのデータを格納することができなくなる(この欠点が
従来の小型計算機における多区分データ管理方式におけ
る最大の欠点といえる)0例えば、第3図(a)および
(b)に示す例では、1つのデータ区分において10個
のデータまでしか格納できない。Furthermore, if the amount of data in a particular data category exceeds the maximum number of data storage location information that can be stored in the index, the data cannot be stored even if there is room in the data file. For example, in the example shown in FIGS. 3(a) and 3(b), only up to 10 pieces of data can be stored in one data section.
本発明の目的は、上述の点に鑑み、データ格納位置に関
する情報をインデックスファイルとともにデータファ・
イルにも持たせることにより、インデックスファイルの
大きさをデータ量の多少5二依存しない固定の大きさと
することができ、ディスクファイル装置(データファイ
ルおよびインデックスファイルを有する装置)およびメ
インメモリの使用効率を向上することができる小型計算
機における多区分データ管理方式を提供することにある
。In view of the above-mentioned points, it is an object of the present invention to store information regarding data storage locations in a data file along with an index file.
By including the index file in the file as well, the size of the index file can be made a fixed size that does not depend on the amount of data, which improves the usage efficiency of the disk file device (device that has data files and index files) and main memory. The object of the present invention is to provide a multi-section data management method in a small computer that can improve the performance.
本発明の小型計算機における多区分データ管理方式は、
メインメモリのメモリサイズに限りのある小型計算機に
おいてディスクファイル装置内の多区分データの管理を
行う小型計算機における多区分データ管理方式において
、各レコード中にデータ格納域およびチェインを構成す
るためのデータ格納位置に関する情報の格納域を有する
データファイルと、このデータファイルに対応して存在
しデータ区分毎に先頭データ格納位置格納域および最後
尾データ格納位置格納域を有するインデックスファイル
と、このインデックスファイルに基づいて前記データフ
ァイル内のデータの管理を行うデータ管理手段とを有す
る。The multi-section data management method in the small computer of the present invention is as follows:
In a multi-section data management method for small computers that manages multi-section data in a disk file device in small computers with limited main memory memory size, data storage is used to configure data storage areas and chains in each record. A data file that has a storage area for information related to position, an index file that exists corresponding to this data file and has a first data storage position storage area and a last data storage position storage area for each data division, and an index file that is based on this index file. and data management means for managing data in the data file.
本発明の小型計算機における多区分データ管理方式では
、データファイルが各レコード中にデータ格納域および
チェインを構成するためのデータ格納位置に関する情報
の格納域を有し、データファイルに対応して存在するイ
ンデックスファイルがデータ区分毎に先頭データ格納位
置格納域および最後尾データ格納位置格納域を有し、デ
ータ管理手段がインデックスファイルに基づいてデータ
ファイル内のデータの管理を行う。In the multi-partition data management method in a small computer of the present invention, a data file has a data storage area in each record and a storage area for information on data storage positions for configuring a chain, and exists corresponding to the data file. The index file has a first data storage position storage area and a last data storage position storage area for each data division, and the data management means manages the data in the data file based on the index file.
次に、本発明について図面を参照して詳細に説明する。 Next, the present invention will be explained in detail with reference to the drawings.
第1図は、本発明の小型計算機における多区分データ管
理方式の一実施例の構成を示すブロック図である。本実
施例の小型計算機における多区分データ管理方式は、イ
ンデックスファイル10と、データファイル20と、デ
ータ管理手段30とを含んで構成されている。FIG. 1 is a block diagram showing the configuration of an embodiment of a multi-section data management system in a small computer according to the present invention. The multi-section data management system in the small-sized computer of this embodiment includes an index file 10, a data file 20, and a data management means 30.
インデックスファイルlOは、対応するデータファイル
20の識別情報であるデータファイル名を格納するデー
タファイル名格納域11と、各データ区分の先頭データ
格納位置を格納する先頭データ格納位置格納域12と、
各データ区分の最後尾データ格納位置を格納する最後尾
データ格納位置格納域13とを有している。なお、削除
後の空き領域(−旦データが格納されてからそのデータ
が削除された領域)となっているデータファイル20内
のレコードの集合も1つのデータ区分として取り扱われ
る。The index file IO includes a data file name storage area 11 that stores a data file name that is identification information of the corresponding data file 20, a first data storage position storage area 12 that stores the first data storage position of each data division,
It has a last data storage position storage area 13 for storing the last data storage position of each data section. Note that a set of records in the data file 20 that is a free area after deletion (an area where data was stored and then deleted) is also treated as one data division.
データファイル20は、レコード毎に(各レコードには
相対レコード位置番号が付されている)、前データ格納
位置格納域21と、次データ格納位置格納域22と、デ
ータ格納域23とを含んで構成されている。なお、前デ
ータ格納位置格納域21および次データ格納位置格納域
22については、いずれか一方だけしか存在しなくても
本発明を実現することができる。このような前データ格
納位置格納域21および次データ格納位置格納域22(
いずれか一方のみしか存在しない場合にはその一方)を
チェインを構成するためのデータ格納位置に関する情報
の格納域という。The data file 20 includes a previous data storage position storage area 21, a next data storage position storage area 22, and a data storage area 23 for each record (each record is assigned a relative record position number). It is configured. Note that the present invention can be implemented even if only one of the previous data storage position storage area 21 and the next data storage position storage area 22 exists. Such a previous data storage position storage area 21 and a next data storage position storage area 22 (
If only one of them exists, the other is called the storage area for information regarding the data storage position for configuring the chain.
データ管理手段30は、インデックスファイル10に基
づいてデータファイル20内のデータの格納、検索およ
び削除等の管理を行う手段であり、従来より存在するデ
ータ管理に関する基本ソフトウェア等によって実現され
る。なお、以下に述べる各動作はこのデータ管理手段3
0の管理下で行われる(以下の説明においては、データ
管理手段30には言及しない)。The data management unit 30 is a unit that manages storage, search, deletion, etc. of data in the data file 20 based on the index file 10, and is realized by conventional basic software related to data management. In addition, each operation described below is performed by this data management means 3.
0 (in the following description, the data management means 30 will not be mentioned).
次に、このように構成された本実施例の小型計算機にお
ける多区分データ管理方式の動作について説明する。な
お、ここでは第2図(a)〜(e)に示すようにデータ
区分がA、BおよびCの3つである場合の動作について
説明する(第2図(a)〜(e)はデータやデータ格納
位置に関する情報の格納状態をモデル的に表現したもの
である)。Next, the operation of the multi-section data management system in the small-sized computer of this embodiment configured as described above will be explained. Here, we will explain the operation when there are three data divisions, A, B, and C, as shown in Figure 2 (a) to (e) (Figure 2 (a) to (e) are data divisions). (This is a model representation of the storage status of information related to information and data storage locations).
第2図(a)は、インデックスファイル10およびデー
タファイル20の初期状態を示す図である。FIG. 2(a) is a diagram showing the initial state of the index file 10 and data file 20.
データファイル20のデータファイル名をデータファイ
ル名格納域11に持つインデックスファイル10内のデ
ータ区分A、BおよびCに対するインデックスID、A
、ID、BおよびID、C中の先頭データ格納位置格納
域12および最後尾データ格納位置格納域13には、デ
ータが存在しないことを意味する情報(ここでは「−1
」とする)が格納されている(削除後の空き領域に対す
る削除後空き領域インデックスlD、X中の先頭データ
格納位置格納域12および最後尾データ格納位置格納域
13にもr−IJが格納されている)。なお、データフ
ァイル20の内容は不定である。Index ID, A, for data divisions A, B, and C in the index file 10 that has the data file name of the data file 20 in the data file name storage area 11;
, ID, B and ID, C, the first data storage location storage area 12 and the last data storage location storage area 13 contain information indicating that no data exists (here, "-1").
'') is stored (post-deletion free space index LD for the post-deletion free space, r-IJ is also stored in the first data storage position storage area 12 and the last data storage position storage area 13 in X). ing). Note that the contents of the data file 20 are undefined.
データの発生順序がA1.Bl、B2.CI。The data generation order is A1. Bl, B2. C.I.
A2.C2,B3.A3.A4およびC3である場合に
は、インデックスファイル10およびデータファイル2
0における格納状態は第2図(b)に示すようになる。A2. C2, B3. A3. In the case of A4 and C3, index file 10 and data file 2
The stored state at 0 is as shown in FIG. 2(b).
例えば、データ区分Bに関しては、データファイル20
内の相対レコード位置番号がrlJのレコードにデータ
B1が格納され、相対レコード位置番号が「2」のレコ
ードにデータB2が格納され、相対レコード位置番号が
「6」のレコードにデータB3が格納される。したがっ
て、データファイル20内の相対レコード位置番号が「
1」のレコード中の前データ格納位置格納域21にはそ
のレコードに格納されるデータBlがデータ区分Bの先
頭のデータであることを示す情報(ここでは「−1」と
する)が格納され、同レコード中の次データ格納位置格
納域22にはデータB1の次のデータB2が格納されて
いるレコードの相対レコード位置番号の「2」が格納さ
れる。また、データファイル20内の相対レコード位置
番号が「2」のレコード中の前データ格納位置格納域2
1にはデータB2の前のデータB1が格納されているレ
コードの相対レコード位置番号の「1」が格納され、同
レコード中の次データ格納位置格納域22にはデータB
2の次のデータB3が格納されているレコードの相対レ
コード位置番号の「6」が格納される。さらに、データ
ファイル20内の相対レコード位置番号が「6」のレコ
ード中の前データ格納位置格納域21にはデータB3の
前のデータB2が格納されているレコードの相対レコー
ド位置番号の「2」が格納され、同レコード中の次デー
タ格納位置格納域22にはそのレコードに格納されるデ
ータB3がデータ区分Bの最後のデータであることを示
す情報(ここでは「−1」とする)が格納される。For example, for data division B, data file 20
Data B1 is stored in the record with the relative record position number rlJ, data B2 is stored in the record with the relative record position number "2", and data B3 is stored in the record with the relative record position number "6". Ru. Therefore, the relative record position number in the data file 20 is “
In the previous data storage location storage area 21 of the record "1", information indicating that the data Bl stored in that record is the first data of data division B (here, "-1") is stored. , the relative record position number "2" of the record in which data B2 following data B1 is stored is stored in the next data storage position storage area 22 in the same record. In addition, the previous data storage position storage area 2 in the record whose relative record position number is "2" in the data file 20
1 stores the relative record position number "1" of the record in which data B1 before data B2 is stored, and data B is stored in the next data storage position storage area 22 in the same record.
The relative record position number "6" of the record in which data B3 subsequent to "2" is stored is stored. Furthermore, in the previous data storage position storage area 21 of the record with the relative record position number "6" in the data file 20, the relative record position number "2" of the record in which data B2 before data B3 is stored is stored. is stored, and the next data storage location storage area 22 in the same record contains information (here, "-1") indicating that data B3 stored in that record is the last data of data division B. Stored.
一方、インデックスファイル10内のインデックスID
、A中の先頭データ格納位置格納域12および最後尾デ
ータ格納位置格納域13には「0」および「8」が格納
され、インデックスID。On the other hand, the index ID in the index file 10
, A, "0" and "8" are stored in the first data storage position storage area 12 and the last data storage position storage area 13 in index ID.
B中の先頭データ格納位置格納域12および最後尾デー
タ格納位置格納域13には「1」および「6」が格納さ
れ、インデックスID、C中の先頭データ格納位置格納
[12および最後尾データ格納位置格納域13には「3
」および「9」が格納される。なお、削除後空き領域イ
ンデックスID、X中の先頭データ格納位置格納域12
および最後尾データ格納位置格納域13には「−1」が
格納されたままである。"1" and "6" are stored in the first data storage position storage area 12 and the last data storage position storage area 13 in B, and the index ID, the first data storage position in C [12 and the last data storage area] are stored. In the location storage area 13, “3
” and “9” are stored. In addition, the free space index ID after deletion, the first data storage position in X, storage area 12
And "-1" remains stored in the last data storage location storage area 13.
第2図(b)に示す状態である場合に、新たなデータが
A5.B4.B5.A6およびC4の順に発生したとき
には、インデックスファイル10およびデータファイル
20における格納状態は第2図(C)に示すようになる
。In the case of the state shown in FIG. 2(b), new data is A5. B4. B5. When A6 and C4 occur in this order, the storage state in the index file 10 and data file 20 becomes as shown in FIG. 2(C).
例えば、データ区分Cに関しては、データファイル20
内の相対レコード位置番号が「14」のレコードにデー
タC4が追加して格納・される。したがって、データフ
ァイル20内の相対レコード位置番号が「14」のレコ
ード中の前データ格納位置格納域21にはそのレコード
に格納されるデータC4の前のデータC3が格納されて
いるレコードの相対レコード位置番号の「9」が格納さ
れ、同レコード中の次データ格納位置格納域22にはそ
のレコードに格納されているデータC4がデータ区分C
の最後のデータであることを示す情報(r−IJ)が格
納される。また、データC3が格納されている相対レコ
ード位置番号が「9」のレコード中の次データ格納位置
格納域22には、「l」に変えて「14」が格納される
。For example, for data division C, data file 20
Data C4 is added to and stored in the record whose relative record position number is "14". Therefore, in the previous data storage position storage area 21 of the record whose relative record position number is "14" in the data file 20, the relative record of the record in which the data C3 before the data C4 stored in that record is stored. The position number "9" is stored, and the next data storage position storage area 22 in the same record has data C4 stored in that record in data classification C.
Information (r-IJ) indicating that the data is the last data is stored. Further, in the next data storage position storage area 22 of the record whose relative record position number is "9" in which data C3 is stored, "14" is stored instead of "l".
一方、インデックスファイルlO内のインデックスID
、A中の最後尾データ格納位置格納域13は「13」に
更新され、インデックスID、B中の最後尾データ格納
位置格納域13は「12」に更新され、インデックスI
D、C中の最後尾データ格納位置格納域13は「14」
に更新される。On the other hand, the index ID in the index file IO
, the last data storage position storage area 13 in index ID, A is updated to "13", the last data storage position storage area 13 in index ID, B is updated to "12", and the last data storage position storage area 13 in index ID, B is updated to "12".
The last data storage location storage area 13 in D and C is “14”
will be updated.
第2図(b)に示す状態である場合に、データ区分Cの
データの取出しく検索)が行われるときには、次のよう
な手順で処理が行われる(第2図(d)参照)。In the state shown in FIG. 2(b), when retrieving or retrieving data in data section C is performed, the following procedure is performed (see FIG. 2(d)).
まず、インデックスファイルlO内のインデックスID
、C中の先頭データ格納位置格納域12の「3」が取得
され、データファイル20内の相対レコード位置番号が
「3」のレコード中のデータ格納域23に格納されてい
るデータC1が読み出される。First, the index ID in the index file IO
, "3" in the first data storage location storage area 12 in C is acquired, and data C1 stored in the data storage area 23 in the record with the relative record position number "3" in the data file 20 is read out. .
次に、このレコード(相対レコード位置番号がr3Jの
レコード)中の次データ格納位置格納域22に格納され
ている「5」が取得され、相対レコード位置番号が「5
」のレコード中のデータ格納域23に格納されているデ
ータC2が読み出される。Next, "5" stored in the next data storage position storage area 22 of this record (the record with the relative record position number r3J) is acquired, and the relative record position number is "5".
Data C2 stored in the data storage area 23 in the record `` is read out.
同様にして、相対レコード位置番号が「9」のレコード
中のデータC3および相対レコード位置番号が「14」
のレコード中のデータC4が読み出される。この相対レ
コード位置番号が「14」のレコード中の次データ格納
位置格納域22には「−1」が格納されているので、デ
ータC4がデータ区分Cの最後のデータであると判断さ
れる。Similarly, data C3 in the record with the relative record position number "9" and data C3 in the record with the relative record position number "14"
Data C4 in the record is read out. Since "-1" is stored in the next data storage position storage area 22 of the record with the relative record position number "14", it is determined that data C4 is the last data of data division C.
以上の手順により、データファイル20に格納されてい
るデータ区分Cの4件のデータ01〜C4中の1つまた
は複数の取出しが可能となる。Through the above procedure, one or more of the four pieces of data 01 to C4 of data category C stored in the data file 20 can be extracted.
第2図(c)に示す状態である場合に、データA3およ
びA4が削除されるときには、インデックスファイル1
0およびデータファイル20における格納状態は第2図
(e)に示すようになる。In the state shown in FIG. 2(c), when data A3 and A4 are deleted, index file 1
0 and the storage state in the data file 20 is as shown in FIG. 2(e).
相対レコード位置番号がrIJおよびr8Jのレコード
中のデータA3およびA4が削除されるので、相対レコ
ード位置番号が17」のレコード中の前データ格納位置
格納域21にはそのレコードが削除後の空き領域(空き
レコード)の先頭であることを示す情報(ここでは「−
1」とする)が格納され、同レコード中の次データ格納
位置格納域22には同レコードの次の削除後の空きレコ
ードの相対レコード位置番号のr8Jが格納される。ま
た、相対レコード位置番号が18」のレコード中の前デ
ータ格納位置格納域21には同レコードの前の削除後の
空きレコードの相対レコード位置番号の「7」が格納さ
れ、同レコード中の次データ格納位置格納域22にはそ
のレコードが削除後の空きレコードの最後尾であること
を示す情報(ここでは「−1」とする)が格納される。Since data A3 and A4 in the records with relative record position numbers rIJ and r8J are deleted, the previous data storage location storage area 21 in the record with relative record position number 17 will have free space after that record is deleted. Information indicating that it is the beginning of a (empty record) (here, "-"
1) is stored, and r8J, which is the relative record position number of the next empty record after the deletion of the same record, is stored in the next data storage position storage area 22 in the same record. In addition, in the previous data storage location storage area 21 of the record whose relative record position number is 18, the relative record position number 7 of the empty record after deletion before the same record is stored, and the next The data storage location storage area 22 stores information (here, "-1") indicating that the record is the last empty record after deletion.
さらに、データA3およびA4の削除を反映してデータ
A2とデータA5とをチェインさせるために、相対レコ
ード位置番号が「4」のレコード中の次データ格納位置
格納域22が「lO」に更新され、相対レコード位置番
号が「10」のレコード中の前データ格納位置格納域2
1が「4」に更新される。Furthermore, in order to chain data A2 and data A5 to reflect the deletion of data A3 and A4, the next data storage location storage area 22 in the record with the relative record position number "4" is updated to "IO". , previous data storage position storage area 2 in the record with relative record position number "10"
1 is updated to "4".
一方、インデックスファイルIO内の削除後空き領域イ
ンデックスlD、X中の先頭データ格納位置格納域12
および最後尾データ格納位置格納域13には、「7」お
よび「8」が格納される。On the other hand, the free space index LD after deletion in the index file IO, the first data storage position storage area 12 in X
"7" and "8" are stored in the last data storage location storage area 13.
次に、本実施例の小型計算機における多区分データ管理
方式の具体的な動作について、第4副(a)〜(C)を
参照して説明する。Next, the specific operation of the multi-section data management method in the small-sized computer of this embodiment will be explained with reference to the fourth subsections (a) to (C).
第4図(a)〜(C)は、パーソナルコンピュータにお
いて日毎の商品売上データを記録するために、本実施例
の小型計算機における多区分データ管理方式が使用され
た例を示す図である。FIGS. 4(a) to 4(C) are diagrams showing an example in which the multi-section data management method in the small-sized computer of this embodiment is used to record daily product sales data in a personal computer.
この例におけるデータは、商品別に10のデータ区分に
分類され、データファイル名rURIAGEJのデータ
ファイル20 (以下、データファイ/l、rURIA
GEJという)に格納されている。The data in this example is classified into 10 data categories by product, and data file 20 with the data file name rURIAGEJ (hereinafter referred to as data file/l, rURIA
GEJ).
インデックスファイル名がrlD、UJのインデックス
ファイル10(以下、インデックスファイルrlD、U
Jという)は、商品別のデータ区分に対するインデック
スID、L!01〜ID、Uloおよび削除後空き領域
インデックスlD、Xからなり、各インデックスには先
頭データ格納位置および最後尾データ格納位置の情報と
してデータファイルrURIAGEJ内の相対レコード
位置番号が格納される。Index file 10 with index file names rlD and UJ (hereinafter referred to as index files rld and U
J) is the index ID for data classification by product, and L! It consists of 01 to ID, Ulo, and post-deletion free space indexes ID and X, and each index stores a relative record position number in the data file rURIAGEJ as information on the first data storage position and the last data storage position.
第4図(a)は、第1日に商品UO1,UO3[JO4
,UO7およびUO9(Dデータファイ−IUO3−1
,LIO4−1,UO7−1およびUO9−1が順にデ
ータファイルrURI AGEJに格納され、第2日に
商品UO2,UO4,UO8UO9およびUI O(D
テ−タU02−2. LIO42,00112,UO
9−2およびUl O−2が順にデータファイルrUR
IAGEJに格納された場合の両ファイルの格納状態を
示す図である。Figure 4(a) shows products UO1, UO3 [JO4] on the first day.
, UO7 and UO9 (D data file - IUO3-1
, LIO4-1, UO7-1 and UO9-1 are stored in the data file rURI AGEJ in order, and on the second day, the products UO2, UO4, UO8UO9 and UI O(D
Theta U02-2. LIO42,00112,UO
9-2 and Ul O-2 are in turn data file rUR
It is a diagram showing the storage state of both files when stored in IAGEJ.
第4図(b)は、第4図(a)の状態に対して、第3日
に商品LI03.UO4,UO8および’U 100)
データUO3−3,UO4−3,UO3−3およびUl
o−3が順にデータファイルrUREAC;Elに追加
格納された場合の両ファイルの格納状態を示す図である
。FIG. 4(b) shows that the product LI03. UO4, UO8 and 'U 100)
Data UO3-3, UO4-3, UO3-3 and Ul
It is a figure which shows the storage state of both files when o-3 is additionally stored in data file rUREAC;El in order.
第4図(c)は、第4図(b)の状態において、3つの
データが格納されている商品UO4のデータが取り出さ
れる場合の手順を矢線で示す図である。インデックスフ
ァイルrlD、UJ内のインデックスID、UO4の先
頭データ格納位置格納域12中の「2」が取得され、デ
ータファイル「URIAGEJ内の相対レコード位置番
号「2」。FIG. 4(c) is a diagram showing, by arrows, the procedure when the data of product UO4 in which three pieces of data are stored is retrieved in the state of FIG. 4(b). The index ID in the index files rlD and UJ, "2" in the first data storage position storage area 12 of UO4 is obtained, and the relative record position number "2" in the data file "URIAGEJ" is obtained.
「6」および「11」のレコードが順に辿られ、データ
UO4−1,UO4−2およびUO4−3が取り出され
る。Records "6" and "11" are traced in order, and data UO4-1, UO4-2, and UO4-3 are extracted.
以上説明したように本発明は、データ格納位置に関する
情報をインデックスファイルとともにデータファイルに
も持たせることにより、インテ・ツクスフアイルの大き
さをデータ量の多少に依存しない固定の大きさとするこ
とができ、データ量の変化による影響をインデックスフ
ァイルの大きさに与えなくてすみ、インデックスファイ
ルの大きさをデータ区分数にのみ関係したものとするこ
とができ、インデックスファイルの未使用部分がなくな
って無駄がなくなるという効果がある。As explained above, the present invention allows the size of the data file to be a fixed size that does not depend on the amount of data by providing information regarding the data storage location in the data file as well as the index file. , there is no need to affect the size of the index file due to changes in the amount of data, the size of the index file can be related only to the number of data partitions, and unused portions of the index file are eliminated, reducing waste. It has the effect of disappearing.
また、従来方式の最大の欠点であったインデックスに格
納可能なデータ格納位置に関する情報の最大数によるデ
ータ区分毎のデータ量の格納制限が発生しないので、デ
ータファイルに余裕のある限り全てのデータ区分につい
てデータを格納することが可能となり、ディスクファイ
ル装置およびメインメモリの使用効率を向上することが
できるという効果がある。このことは、データ量が予測
値を越えた場合でもデータファイルの大きさを拡大する
ことのみで対処できることを意味し、データファイルお
よびインデックスファイルの見積りに関する許容誤差を
大きくすることができるという効果も生む。In addition, since there is no storage limit on the amount of data for each data division due to the maximum number of data storage location information that can be stored in an index, which was the biggest drawback of the conventional method, all data divisions can be stored as long as there is room in the data file. This has the effect of improving the usage efficiency of the disk file device and main memory. This means that even if the amount of data exceeds the predicted value, it can be handled simply by enlarging the size of the data file, which also has the effect of increasing the tolerance for estimation of data files and index files. give birth to
第1図は本発明の一実施例の構成を示すブロック図、
第2図(a)〜(e)は第1図に示す小型計算機におけ
る多区分データ管理方式の動作を説明するだめの図、
第3図(a)および(b)は従来の小型計算機における
多区分データ管理方式の動作を説明するための図、
第4図(a)〜(C)は第1図に示す小型計算機におけ
る多区分データ管理方式が日毎の商品売上データの管理
に使用される場合の動作を説明するための回である。
図において、
10・・・インデックスファイル、
11・・・データファイル名格納域、
12・・・先頭データ格納位置格納域、13・・・最後
尾データ格納位置格納域、20・・・データファイル、
21・・・前データ格納位置格納域、
22・・・次データ格納位置格納域、
23・・・データ格納域、
30・・・データ管理手段である。
特許出願人 日本電気ソフトウェア株式会社代 理
人 弁理士 河 原 純
第2図(b)
インデックスファイル
データファイル
第21W (C)
2]
l
j
第2因(e)
J
第2図(d)
第3図(Q)
第3区(b)
イノデックスフ1イル
第4図(α)
イノデックスフフィル
第1日
商品
uo+、UO3
uo4.UO7、UO9
第4図(b)
第3日
商品
LI03.UO4,UO8、UIOFIG. 1 is a block diagram showing the configuration of an embodiment of the present invention; FIGS. 2(a) to (e) are diagrams illustrating the operation of the multi-section data management method in the small computer shown in FIG. 1; Figures 3(a) and (b) are diagrams for explaining the operation of the multi-partition data management system in the conventional small computer, and Figures 4(a) to (C) are diagrams for explaining the operation of the multi-partition data management system in the conventional small computer. This episode is for explaining the operation when the segmented data management method is used to manage daily product sales data. In the figure, 10... Index file, 11... Data file name storage area, 12... First data storage position storage area, 13... Last data storage position storage area, 20... Data file, 21... Previous data storage location storage area, 22... Next data storage location storage area, 23... Data storage area, 30... Data management means. Patent applicant: NEC Software Co., Ltd. Representative
Person Patent Attorney Jun Kawahara Figure 2 (b) Index File Data File No. 21W (C) 2] l j Second Cause (e) J Figure 2 (d) Figure 3 (Q) Section 3 (b) Inodex file Figure 4 (α) Inodex file 1st day products uo+, UO3 uo4. UO7, UO9 Figure 4 (b) 3rd day product LI03. UO4, UO8, UIO
Claims (1)
おいてディスクファイル装置内の多区分データの管理を
行う小型計算機における多区分データ管理方式において
、 各レコード中にデータ格納域およびチェインを構成する
ためのデータ格納位置に関する情報の格納域を有するデ
ータファイルと、 このデータファイルに対応して存在しデータ区分毎に先
頭データ格納位置格納域および最後尾データ格納位置格
納域を有するインデックスファイルと、 このインデックスファイルに基づいて前記データファイ
ル内のデータの管理を行うデータ管理手段と を有することを特徴とする小型計算機における多区分デ
ータ管理方式。[Claims] In a multi-partition data management method for a small-sized computer that manages multi-partition data in a disk file device in a small-sized computer with a limited main memory memory size, a data storage area and a chain are defined in each record. A data file that has a storage area for information regarding data storage positions for configuration; and an index file that exists corresponding to this data file and has a first data storage position storage area and a last data storage position storage area for each data division. , a data management means for managing data in the data file based on the index file.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2218685A JPH04101244A (en) | 1990-08-20 | 1990-08-20 | Multi-sectioned data controlling system in small computer |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2218685A JPH04101244A (en) | 1990-08-20 | 1990-08-20 | Multi-sectioned data controlling system in small computer |
Publications (1)
Publication Number | Publication Date |
---|---|
JPH04101244A true JPH04101244A (en) | 1992-04-02 |
Family
ID=16723814
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2218685A Pending JPH04101244A (en) | 1990-08-20 | 1990-08-20 | Multi-sectioned data controlling system in small computer |
Country Status (1)
Country | Link |
---|---|
JP (1) | JPH04101244A (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US7106749B1 (en) | 1999-11-10 | 2006-09-12 | Nds Limited | System for data stream processing |
US7756201B2 (en) | 2001-07-23 | 2010-07-13 | Nds Limited | System for random access to content |
-
1990
- 1990-08-20 JP JP2218685A patent/JPH04101244A/en active Pending
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US7106749B1 (en) | 1999-11-10 | 2006-09-12 | Nds Limited | System for data stream processing |
US7580416B2 (en) | 1999-11-10 | 2009-08-25 | Nds Limited | System for data stream processing |
US7756201B2 (en) | 2001-07-23 | 2010-07-13 | Nds Limited | System for random access to content |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US7689574B2 (en) | Index and method for extending and querying index | |
JP2007073039A (en) | System, program product, method and computer software for providing content based anticipative storage management | |
US7778961B2 (en) | Delayed deletion of extended attributes | |
EP0326162B1 (en) | Data base system including memorandum information and method for managing memorandum information | |
JPH04101244A (en) | Multi-sectioned data controlling system in small computer | |
JP2021022357A (en) | Hybrid file construction method and system therefor based on fuse technology | |
JPH1063436A (en) | Data storage method and device | |
KR100295392B1 (en) | How to Configure a Dynamic File System | |
JP4306281B2 (en) | Hierarchical data mapping program, apparatus and method in relational database | |
Raghuveer et al. | Towards efficient search on unstructured data: an intelligent-storage approach | |
JP3061385B2 (en) | Data management device and data management method | |
JP2679761B2 (en) | Data management system | |
JPH03161864A (en) | Document control processing system | |
JPH03174654A (en) | Filing method and its device | |
JPH07271946A (en) | Image information processor | |
JPS59180763A (en) | Access method of data base system | |
JPH04182749A (en) | Relational database data storage method | |
JPH05274196A (en) | Secondary storage managing method by multiple file | |
JPH0444171A (en) | Information file system | |
JPH04314144A (en) | Dara block accesssing system for sequential file | |
JPH04127337A (en) | File managing system | |
JPH03296835A (en) | Database input/output buffer management method | |
JPH0535563A (en) | Method for managing image information | |
JPH04116737A (en) | Electronic filing device | |
JPH0778175A (en) | Data search method |