JPH04178726A - Mass storage data classification processing system - Google Patents

Mass storage data classification processing system

Info

Publication number
JPH04178726A
JPH04178726A JP30688490A JP30688490A JPH04178726A JP H04178726 A JPH04178726 A JP H04178726A JP 30688490 A JP30688490 A JP 30688490A JP 30688490 A JP30688490 A JP 30688490A JP H04178726 A JPH04178726 A JP H04178726A
Authority
JP
Japan
Prior art keywords
string
strings
key
directory
phase
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
JP30688490A
Other languages
Japanese (ja)
Inventor
Kiyoshi Aoki
清 青木
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.)
NEC Office Systems Ltd
Original Assignee
NEC Office Systems Ltd
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 NEC Office Systems Ltd filed Critical NEC Office Systems Ltd
Priority to JP30688490A priority Critical patent/JPH04178726A/en
Publication of JPH04178726A publication Critical patent/JPH04178726A/en
Pending legal-status Critical Current

Links

Landscapes

  • Signal Processing For Digital Recording And Reproducing (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

PURPOSE:To minimize a time required for the positioning of a magnetic head by linking mass storage data within a paragraph in cylinder unit when the mass storage data are classified by using a magnetic disk device, etc., as an external memory device. CONSTITUTION:In a pre-sort phase 1, a data record is read in from an input file 6, and a string is generated, and it is outputted to the magnetic disk device 8 that is the external memory device, and simultaneously, a string directory 7 is generated, and it is unified in one cylinder unit, and it is paragraphed, and is stored in an internal memory device. The string directory 7 consists of a disk address at which the string is stored, a first key that is the key of the first record of the string, and a final key that is the key of the final record. In a link phase 2, the string directory 7 generated in the pre-sort phase 1 is linked. Thereby, it is possible to minimize a time required for the positioning of the magnetic head.

Description

【発明の詳細な説明】 〔産業上の利用分野〕 本発明は、電子計算機による事務データ処理等における
大容量データの分類処理方式に関し、特に、外部記憶装
置として磁気ディスク装置等を使用して大容量データを
分類する方式に関する。
[Detailed Description of the Invention] [Field of Industrial Application] The present invention relates to a classification processing method for large-capacity data in office data processing, etc. by a computer, and particularly relates to a classification processing method for large-capacity data in office data processing etc. by a computer, and in particular, a large-capacity data classification method using a magnetic disk device etc. as an external storage device. Concerning a method for classifying capacity data.

〔従来の技術〕[Conventional technology]

従来、外部記憶装置として磁気ディスク装置を使用して
大容量データを分類する方式にはリンク分類方式がある
(特許出願番号昭和82−258068)。これは、第
4図に示すように、以下の4つのフェーズからなる。
Conventionally, there is a link classification method as a method for classifying large-capacity data using a magnetic disk device as an external storage device (Patent Application No. 1982-258068). This consists of the following four phases, as shown in FIG.

(1)プリソートフェーズ(フェーズ1)(2)リンク
フェーズ(フェーズ2) (3)マージフェーズ(フェーズ4) (4)ラストパスフェーズ(フェーズ5)ブリソートフ
ェーズ1では、入力ファイル6からデータ・レコードが
読込まれ、順番に組分けされ、順序づけられた組、即ち
ストリングとして磁気ディスク装置8へ出力されると同
時に、これらのストリングのそれぞれが出力された磁気
ディスク装置8上の位置(アドレス)とそのストリング
の第1レコードのキー及び最終レコードのキードから成
るストリングデイレクトIJ 7を内部記憶装置へ出力
しておく。
(1) Presort phase (Phase 1) (2) Link phase (Phase 2) (3) Merge phase (Phase 4) (4) Last pass phase (Phase 5) In Presort phase 1, data records are extracted from input file 6. are read, grouped in order, and output to the magnetic disk drive 8 as ordered sets, that is, strings, and at the same time, the position (address) on the magnetic disk drive 8 where each of these strings was output and its A string direct IJ7 consisting of the key of the first record of the string and the key of the last record is output to the internal storage device.

リンクフェーズ2では、このストリングデイレクトリフ
を入力して第1レコードのキーの昇順に並び替え、並び
替えた後の先頭のストリングディレクトリの最終レコー
ドのキーと以降のストリングディレクトリの第1レコー
ドのキーとを比較し、後者の方が大きい場合に両方のス
トリングディレクトリをリンクするという処理を行う。
In link phase 2, this string directory is input and sorted in ascending order of the keys of the first record, and the keys of the last record of the first string directory and the keys of the first records of subsequent string directories after sorting are input. If the latter is larger, both string directories are linked.

こうすることによりストリングを論理的にマージするこ
とが出来る。
This allows the strings to be merged logically.

次のマージフェース4では、これらのストリングの数が
ラストパスのマージオーダ以下になるまで、リンクフェ
ースで処理されたストリングがさらにマージされる。
In the next merge phase 4, more strings processed in the link phase are merged until the number of these strings is less than or equal to the merge order of the last pass.

ラストパスフェース5では、マージフェーズ4でマージ
されてできあがったストリングを1本のストリングに作
成して出力ファイル9へ書込む。
In the last pass phase 5, the strings merged in the merge phase 4 are created into one string and written to the output file 9.

〔発明が解決しようとする課題〕[Problem to be solved by the invention]

上述した従来の大容量データ分類処理方式では、磁気デ
ィスク装置等の外部記憶装置の特性であるランダムアク
セスを生かすことを重要視するあまり0.物理的な特性
を無視して、論理的にストリングをリンクしてしまうこ
とになるため、論理的にリンクしたストリングを物理的
に入替えてマージするような場合、磁気ヘッドの位置ぎ
めに要する時間(シークタイム)が極端にかかってしま
うという欠点がある。
In the conventional large-capacity data classification processing method described above, emphasis is placed on making use of random access, which is a characteristic of external storage devices such as magnetic disk devices, so that 0. Since strings are linked logically, ignoring their physical characteristics, when physically exchanging and merging logically linked strings, the time required to position the magnetic head ( The disadvantage is that the seek time is extremely long.

つまり、リンクフェーズで、ストリングディレクトリを
入力して第1レコードのキーの昇順に並び替え、並び替
えた後の先頭のストリングディレクトリの最終レコード
のキーと以降のストリングディレクトリの第1レコード
のキーとを比較し、後者の方が大きい場合に両方のスト
リングディレクトリをリンクするという処理のため、物
理的に非常に離れたストリング同志がリンクされてしま
う可能性があり、シークタイムがかかってしまうことに
なる。
In other words, in the linking phase, input the string directory, sort it in ascending order of the keys of the first record, and after sorting, the key of the last record of the first string directory and the key of the first record of the subsequent string directories. Because of the process of comparing and linking both string directories if the latter is larger, there is a possibility that strings that are physically very far apart will be linked, which will increase seek time. .

〔課題を解決するための手段〕[Means to solve the problem]

本発明は、回転する記憶媒体に対し移動するヘッドでデ
ータを読み書きし記憶媒体の2以上のシリンダでのデー
タの読み書きではヘッドをシークさせる必要がある外部
記憶装置に入力ファイルから読込まれたレコードから作
成した複数のストリングを出力し、これらのストリング
を物理的に入替えてマージする大容量データ分類処理方
式において、 前記ストリングが作成されて前記外部記憶装置へ出力さ
れると同時に、前記ストリングのそれぞれが出力される
前記外部記憶装置上の位置とそのストリングの第1レコ
ードのキー及び最終レコードのキーとを有するストリン
グディレクトリを内部記憶装置へ出力するス) IJン
クディレク) IJ作成手段と、 シリンダ単位に前記シリンダディレクトリを所定の規則
に基ずいて第1レコードのキーの順に並び替え、並び替
えた後のそれぞれのディレクトリの最終レコードのキー
が以降の順番のストリングディレクトリの第1のレコー
ドのキーより前記規則に基ずいて後位のものである時に
両方のストリングをリンクする論理的マージ手段と、前
記論理的マージ手段によりリンクされたストリングをシ
リンダ単位に物理的にマージする物理的マージ手段とを
有している。
The present invention reads and writes data from a rotating storage medium using a moving head, and requires the head to seek when reading and writing data from two or more cylinders of the storage medium from records read from an input file to an external storage device. In a large-capacity data classification processing method that outputs a plurality of created strings, and physically replaces and merges these strings, each of the strings is created and output to the external storage device, and at the same time, each of the strings is (1) outputting a string directory having a position on the external storage device to be output and a key of the first record and a key of the last record of the string to the internal storage device; The cylinder directories are sorted in the order of the keys of the first records based on a predetermined rule, and the key of the last record of each directory after sorting is determined by the key of the first record of the string directory in the following order. and a physical merging means for physically merging the strings linked by the logical merging means in units of cylinders. ing.

〔実施例〕〔Example〕

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

第1図は本発明の一実施例の大容量データ分類処理方式
を用いて大容量データを分類する場合のデータの流れを
示す図、第2図はストリングデイレクトリフのフォーマ
ット例を示す図、第3図はリンクフェーズ2でのリンク
例を示す図である。
FIG. 1 is a diagram showing a data flow when classifying a large amount of data using a large amount of data classification processing method according to an embodiment of the present invention; FIG. 2 is a diagram showing an example of the format of a string directory; FIG. 3 is a diagram showing an example of links in link phase 2.

本実施例の大容量データ分類処理方式は、第1図に示す
ように以下の5つのフェーズからなる。
The large-capacity data classification processing method of this embodiment consists of the following five phases as shown in FIG.

(1)プリソートフェーズ(フェーズ1)(2)リンク
フェーズ(フェーズ2) (3)ワンシリンダマージフェーズ(フェーズ3)(4
)マルチシリンダマージフェーズ(フェーズ4)(5)
ラストパスフェーズ(フェーズ5)プリソートフェーズ
1では、第4図に示した従来の大容量データ分類処理方
式と同様に、入力ファイル6からデータφレコードが読
込まれ、ストリングが作成されて外部記憶装置の磁気デ
ィスク装置8へ出力されるが、このとき同時に、ストリ
ングデイレクトリフが作成されて1シリンダ単位にまと
め区切りを付けて内部記憶装置に格納される。このスト
リングデイレクトリフは第2図で示すように、ストリン
グが格納されているディスクアドレス(シリンダアドレ
スを含む)と、ストリングの第1レコードのキーである
第1キード、最終レコードのキーである最終キーとから
なる。
(1) Presort phase (Phase 1) (2) Link phase (Phase 2) (3) One cylinder merge phase (Phase 3) (4
) Multi-cylinder merge phase (phase 4) (5)
Last Pass Phase (Phase 5) In the presort phase 1, data φ records are read from the input file 6, a string is created, and the string is stored in the external storage device, similar to the conventional large-capacity data classification processing method shown in FIG. The data is output to the magnetic disk device 8, but at the same time, a string directory is created and stored in the internal storage device in units of cylinders with delimiters attached. As shown in Figure 2, this string directory contains the disk address (including cylinder address) where the string is stored, the first key which is the key of the first record of the string, and the final key which is the key of the last record. It consists of.

リンクフェーズ2では、プリソートフェーズ1で作成さ
れたストリングデイレクトリフをリンクすることにより
、ストリングを論理的にマージする。このリンクは、ま
ず、プリソートフェーズ2で作成した複数個のストリン
グディレクトリを1シリンダ単位に第1キーが大きいも
のから昇順に並びかえる。次に、1シリンダ内で1番目
のストリングディレクトリの最終キーと2番目のストリ
ングディレクトリの第1キーを比較し、後者の方が大き
いときにこれら2つのストリングディレクトリをリンク
することにより、ストリングを論理的にマージする。3
番目以降のストリングディレクトリについても同様の比
較を行ってリンクしていく。
In the linking phase 2, the strings are logically merged by linking the string directory riffs created in the presorting phase 1. This link first sorts the plurality of string directories created in presort phase 2 in ascending order of the first key in units of cylinders. The strings are then logically merged by comparing the final key of the first string directory and the first key of the second string directory within one cylinder, and linking these two string directories when the latter is larger. merge. 3
Similar comparisons are made for the string directories after the string directory, and links are made.

この作業をシリンダ単位に全てのストリングディレクト
リについて行うことにより、ストリングを物理的にマー
ジすることなく論理的にマージさせてストリングの数を
減らす。
By performing this work for all string directories on a cylinder-by-cylinder basis, strings are logically merged without physically merging, thereby reducing the number of strings.

例えば第3図に示すように、50シリンダ上のディスク
アドレス“A”〜“D”を持つ4つのストリングディレ
クトリをリンクする場合に、これらのストリングディレ
クトリを第1キーが大きいものから昇順に並び替えると
 uB”  u [) 11゜“C”、′A” (ディ
スクアドレスによる表示)となる。次に uB”の最終
キーと“A”の第1キーを比較して後者の方が大きいの
で、両者をリンクする。これにより“B−A”” up
”。
For example, as shown in Figure 3, when linking four string directories with disk addresses "A" to "D" on 50 cylinders, these string directories are sorted in ascending order from the one with the largest first key. and uB" u [) 11° "C",'A" (displayed by disk address). Next, compare the final key of "uB" and the first key of "A", and since the latter is larger, link the two. This will update "B-A""
”.

“C”の3つのストリングにマージされたこととなる。This results in merging into three strings of “C”.

次に IJD″の最終キーと“C”の第1キーを比較し
て後者の方が大きいので、両者をリンクする。これによ
り“B−A”、”D−C”の2つのストリングが作成さ
れることになる。同様に、51シリンダについても同様
の操作によって“H−F”、”E−G”の2つのストリ
ングが作成されることになる。
Next, compare the final key of "IJD" and the first key of "C", and since the latter is larger, link the two. This creates two strings, "B-A" and "D-C". Similarly, two strings, "H-F" and "E-G", will be created for cylinder 51 by the same operation.

ワンシリンダマージフェーズ3では、リンクフェーズ2
で論理的にリンクされたストリングの数が各シリンダに
ついて1ストリングになるまでストリングを物理的にマ
ージする。
In one cylinder merge phase 3, link phase 2
physically merge the strings until the number of logically linked strings is one string for each cylinder.

この間、磁気ディスク8の磁気ヘッドは同一シリンダ上
のデータをアクセスするため移動する必要がなく、ヘッ
ド位置ぎめに要する時間(シークタイム)は最小で零に
出来る。
During this time, the magnetic head of the magnetic disk 8 does not need to move to access data on the same cylinder, and the time required for head positioning (seek time) can be reduced to zero at the minimum.

マルチシリンダフェーズ4では、ワンシリンダマージフ
ェーズ3で1シリンダ1ストリングになっている2つの
シリンダをマージして1ストリングにする。これをスト
リング数が2以下になるまでくりかえす。この方式は読
取りと書き込みを極力同一シリンダ上で行なうように工
夫したスライディングバッファ手法を特徴する特許出願
番号昭和63−291388)。こうすることにより、
マージフェーズにおけるシークタイムを極力最小にする
ことができる。また、ラストバスフェーズ5では、マー
ジフェーズ4でマージして作成されたストリングを1本
のストリングに作成して出力ファイルへ書き込むことに
よって処理が終了する。
In the multi-cylinder phase 4, the two cylinders that were made into one cylinder and one string in the one-cylinder merge phase 3 are merged into one string. Repeat this until the number of strings is 2 or less. This method is characterized by a sliding buffer method designed to perform reading and writing on the same cylinder as much as possible (Patent Application No. 1983-291388). By doing this,
The seek time in the merge phase can be minimized as much as possible. Furthermore, in the last bus phase 5, the strings created by merging in the merge phase 4 are created into one string and written to the output file, thereby completing the process.

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

以上説明したように本発明は、外部記憶装置として、磁
気ディスク装置等を使用して大容量データを分類する場
合に、従来はリンクフェーズで無条件にストリングディ
レクトリ上の全データを第1キーと最終キーの大小によ
ってリンクしていたのを、シリンダ単位に区切って、そ
の範囲内で同様の操作によってリンクすることにより、
論理的にストリングをマージする効果を生じながら、物
理的な面からシークタイムを極力最小にすることができ
る効果がある。
As explained above, when classifying large-capacity data using a magnetic disk device or the like as an external storage device, conventionally the present invention unconditionally stores all data on a string directory as the first key in the link phase. Instead of linking based on the size of the final key, by dividing it into cylinders and linking by the same operation within that range,
This has the effect of physically merging the strings while minimizing the seek time as much as possible.

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

第1図は本発明の一実施例の大容量データ分類処理方式
を用いて大容量データを分類する場合のデータの流れを
示す図、第2図は第1図のストリングデイレクトリフの
フォーマット例を示す図、第3図は第1図のリンクフェ
ーズ2におけるリンク例を示す図、第4図は従来の大容
量データ分類処理方式のデータの流れを示す図である。 1・・・プリソートフェーズ、2・・・リンクフェーズ
、3・・・ワンシリンダマージフェーズ、4・・・マル
チシリンダマージフェーズ、5・・・ラストパスフェー
ズ、6・・・入力ファイル、7・・・ストリングディレ
クトリ、8・・・磁気ディスク装置、9・・・出力ファ
イル。
FIG. 1 is a diagram showing the data flow when classifying large volumes of data using the large volume data classification processing method according to an embodiment of the present invention, and FIG. FIG. 3 is a diagram showing a link example in link phase 2 of FIG. 1, and FIG. 4 is a diagram showing a data flow in a conventional large-capacity data classification processing method. 1... Presort phase, 2... Link phase, 3... One cylinder merge phase, 4... Multi cylinder merge phase, 5... Last pass phase, 6... Input file, 7... - String directory, 8... Magnetic disk device, 9... Output file.

Claims (1)

【特許請求の範囲】  回転する記憶媒体に対し移動するヘッドでデータを読
み書きし記憶媒体の2以上のシリンダでのデータの読み
書きではヘッドをシークさせる必要がある外部記憶装置
に入力ファイルから読込まれたレコードから作成した複
数のストリングを出力し、これらのストリングを物理的
に入替えてマージする大容量データ分類処理方式におい
て、前記ストリングが作成されて前記外部記憶装置へ出
力されると同時に、前記ストリングのそれぞれが出力さ
れる前記外部記憶装置上の位置とそのストリングの第1
レコードのキー及び最終レコードのキーとを有するスト
リングディレクトリを内部記憶装置へ出力するストリン
グディレクトリ作成手段と、 シリンダ単位に前記シリンダディレクトリを所定の規則
に基ずいて第1レコードのキーの順に並び替え、並び替
えた後のそれぞれのディレクトリの最終レコードのキー
が以降の順番のストリングディレクトリの第1のレコー
ドのキーより前記規則に基ずいて後位のものである時に
両方のストリングをリンクする論理的マージ手段と、 前記論理的マージ手段によりリンクされたストリングを
シリンダ単位に物理的にマージする物理的マージ手段と
を含むことを特徴とする大容量データ分類処理方式。
[Claims] Data is read from an input file to an external storage device that reads and writes data with a moving head on a rotating storage medium, and requires the head to seek when reading and writing data on two or more cylinders of the storage medium. In a large-capacity data classification processing method that outputs a plurality of strings created from records, and physically replaces and merges these strings, the strings are created and output to the external storage device, and at the same time, the strings are The location on the external storage device where each is output and the first string of that string.
a string directory creation means for outputting a string directory having a record key and a final record key to an internal storage device; sorting the cylinder directory in the order of the first record key based on a predetermined rule on a cylinder-by-cylinder basis; A logical merge that links both strings when the key of the last record in each directory after sorting is later than the key of the first record in the subsequent string directory based on the above rules. and physical merging means for physically merging strings linked by the logical merging means in units of cylinders.
JP30688490A 1990-11-13 1990-11-13 Mass storage data classification processing system Pending JPH04178726A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP30688490A JPH04178726A (en) 1990-11-13 1990-11-13 Mass storage data classification processing system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP30688490A JPH04178726A (en) 1990-11-13 1990-11-13 Mass storage data classification processing system

Publications (1)

Publication Number Publication Date
JPH04178726A true JPH04178726A (en) 1992-06-25

Family

ID=17962413

Family Applications (1)

Application Number Title Priority Date Filing Date
JP30688490A Pending JPH04178726A (en) 1990-11-13 1990-11-13 Mass storage data classification processing system

Country Status (1)

Country Link
JP (1) JPH04178726A (en)

Similar Documents

Publication Publication Date Title
US4514826A (en) Relational algebra engine
US8001134B2 (en) Method for performing an external (disk-based) sort of a large data file which takes advantage of “presorted” data already present in the input
JPH02178730A (en) Internal sorting system using dividing method
US6424970B1 (en) Sorting system and method executed by plural computers for sorting and distributing data to selected output nodes
Menon A study of sort algorithms for multiprocessor database machines
JPH04178726A (en) Mass storage data classification processing system
JPH06103128A (en) Storage device
US20220138338A1 (en) Data replacement apparatus, data replacement method, and program
JPS63196959A (en) Saving and restoring system for file
JP3145727B2 (en) Data retrieval device
JP5354606B2 (en) Data storage device and method and program, and data search device and method and program
JPH0199125A (en) Link classifying system
JP3293551B2 (en) Sorting method
JP2507399B2 (en) Database equipment
JPH0291725A (en) Merging processing system
JPH02252061A (en) Image filing device
Islam et al. Computational complexities of the external sorting algorithm with no additional disk space
JPH0764835A (en) Data storage system for relational data base
JPH02302869A (en) File edition system
JPS61133450A (en) Data base revision log processing system
JPH01136252A (en) File structure
JPH04172541A (en) Record storage unit
JPH0398137A (en) File back-up system
JPH0388069A (en) Device for connecting storage medium
US20100217749A1 (en) Method and system for optimizing the storage of different digital data on the basis of data history