JPH03219340A - Sequential organization file accessing system utilizing control file - Google Patents
Sequential organization file accessing system utilizing control fileInfo
- Publication number
- JPH03219340A JPH03219340A JP2015692A JP1569290A JPH03219340A JP H03219340 A JPH03219340 A JP H03219340A JP 2015692 A JP2015692 A JP 2015692A JP 1569290 A JP1569290 A JP 1569290A JP H03219340 A JPH03219340 A JP H03219340A
- Authority
- JP
- Japan
- Prior art keywords
- file
- control
- control file
- record
- information
- 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
- 230000008520 organization Effects 0.000 title abstract description 7
- 238000000034 method Methods 0.000 claims description 28
- 239000000284 extract Substances 0.000 abstract description 3
- 230000015572 biosynthetic process Effects 0.000 abstract description 2
- 238000010586 diagram Methods 0.000 description 5
Landscapes
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
Abstract
Description
【発明の詳細な説明】
〔産業上の利用分野〕
本発明は順編成ファイルアクセス方式に関し、特にコン
トロールファイルを利用した順編成ファイルアクセス方
式に関する。DETAILED DESCRIPTION OF THE INVENTION [Field of Industrial Application] The present invention relates to a sequential file access method, and particularly to a sequential file access method using a control file.
従来、1個の順編成ファイルの一部分のレコードのみを
1フアイルとして利用する場合や順編成ファイルの一部
分のレコードを除いたものを1フアイルとして利用する
場合などには、IIIII&!成ファイルから必要なレ
コードのみを抜き出して別のファイルにコピーしたり、
順編成ファイルを作り直したすする等のファイルの更新
を行って利用者プログラムに対応させるか、あるいは利
用者プログラム側でレコードの内容をチエツクして対応
していた。Conventionally, when using only a portion of records in one sequential file as one file, or when using a sequential file excluding a portion of records as one file, III&! Extract only the records you need from a configuration file and copy them to another file,
This was done by either re-creating the sequential file and updating the file to make it compatible with the user program, or by checking the contents of the record on the user program side.
上述した従来の技術では、順編成ファイル内のデータを
レコードの集合体と考え、それをある条件によって分類
するときに2個以上の条件に属するレコードがあった場
合には同一レコードを複数のファイルに格納しなければ
ならないので、レコード全体をまとめた1個のファイル
サイズよりも分割した複数個のファイルの合計サイズの
方が大きくなる場合があるという欠点がある。In the conventional technology described above, data in a sequential file is considered to be a collection of records, and when classifying the data according to certain conditions, if there are records that belong to two or more conditions, the same record is divided into multiple files. Therefore, there is a drawback that the total size of the multiple divided files may be larger than the size of one file containing the entire record.
本発明の目的は、上述の点に鑑み、全レコードを格納す
る実ファイルが1個と、レコード制御情報からなるコン
トロールファイルが分類した数だけあれば、順編成ファ
イルを複数個に分割した場合と同様の処理が節約したフ
ァイルスペースで可能となるようにしたコントロールフ
ァイルを利用した順編成ファイルアクセス方式を提供す
ることにある。In view of the above-mentioned points, an object of the present invention is to solve the problem when a sequential file is divided into a plurality of files as long as there is one real file storing all records and the number of classified control files consisting of record control information. An object of the present invention is to provide a sequential file access method using a control file that enables similar processing in a saved file space.
本発明のコントロールファイルを利用した順編成ファイ
ルアクセス方式は、大容量記憶媒体上に構成される順編
成ファイルからレコードを順次読み込み利用者プログラ
ムからの指示を基に有効レコードか否かを判定し各レコ
ードに対するレコード制御情報をコントロールファイル
に登録していくコントロールファイル作成手段と、この
コントロールファイル作成手段によって作成されたコン
トロールファイル内のレコード制御情報を基に前記順編
成ファイル内の有効レコードのみを順次取り出すことを
可能とするコントロールファイル参照手段と、利用者プ
ログラムからの要求がコントロールファイルの作成か参
照かを判定し作成要求であれば前記コントロールファイ
ル作成手段に制御を渡し参照要求であれば前記コントロ
ールファイル参照手段に制御を渡すコントロールファイ
ル初期化準備手段と、作成済みのコントロールファイル
のレコード制御情報を消去したり更新したり別ファイル
に複写したりする処理を可能とするコントロールファイ
ルサービス手段とを有する。The sequential file access method using the control file of the present invention sequentially reads records from a sequential file configured on a large-capacity storage medium and determines whether or not each record is valid based on instructions from the user program. A control file creation means that registers record control information for records in a control file, and sequentially extracts only valid records in the sequential file based on the record control information in the control file created by the control file creation means. A control file reference means that enables the user program to determine whether a request from a user program is to create or reference a control file, and if it is a creation request, control is passed to the control file creation means and if it is a reference request, control is passed to the control file creation means. It has a control file initialization preparation means for passing control to a reference means, and a control file service means that enables processing such as erasing, updating, or copying record control information of a created control file to another file.
本発明のコントロールファイルを利用した順編成ファイ
ルアクセス方式では、コントロールファイル作成手段が
大容量記憶媒体上に構成される順編成ファイルからレコ
ードを順次読み込み利用者プログラムからの指示を基に
有効レコードか否かを判定し各レコードに対するレコー
ド制御情報をコントロールファイルに登録していき、コ
ントロールファイル参照手段がコントロールファイル作
成手段によって作成されたコントロールファイル内のレ
コード制御情報を基に順編成ファイル内の有効レコード
のみを順次取り出すことを可能とし、コントロールファ
イル初期化準備手段が利用者プログラムからの要求がコ
ントロールファイルの作成か参照かを判定し作成要求で
あればコントロールファイル作成手段に制御を渡し参照
要求であればコントロールファイル参照手段に制御を渡
し、コントロールファイルサービス手段が作成済みのコ
ントロールファイルのレコード制御情報を消去したり更
新したり別ファイルに複写したりする処理を可能とする
。In the sequential file access method using the control file of the present invention, the control file creation means sequentially reads records from a sequential file configured on a mass storage medium and determines whether the records are valid or not based on instructions from the user program. The record control information for each record is registered in the control file, and the control file reference means selects only valid records in the sequential file based on the record control information in the control file created by the control file creation means. The control file initialization preparation means determines whether the request from the user program is to create or reference a control file, and if it is a creation request, it passes control to the control file creation means and if it is a reference request. Control is passed to the control file reference means to enable the control file service means to perform processing such as erasing, updating, or copying the record control information of the created control file to another file.
次に、本発明について図面を参照して詳細に説明する。 Next, the present invention will be explained in detail with reference to the drawings.
第1図は、本発明の一実施例に係るコントロールファイ
ルを利用した順編成ファイルアクセス方式の構成を示す
ブロック図である。本実施例のコントロールファイルを
利用した順編成ファイルアクセス方式は、利用者プログ
ラム101と、サービスプログラム102と、コントロ
ールファイル初期化準備手段202.コントロールファ
イル作成手段203. コントロールファイル参照手段
204およびコントロールファイルサービス手段205
を含むデータ処理袋N201と、順編成ファイル301
と、コントロールファイル302とから構成されている
。なお、第1図中、符号11は利用者プログラム101
からのlfl[成ファイルアクセス要求信号、12はサ
ービスプログラム102からのコントロールファイル更
新要求信号、13,14および15は順編成ファイル入
出力処理におけるコントロールファイル初期化準備手段
202、コントロールファイル作成手段203およびコ
ントロールファイル参照手段204に対する処理要求信
号、16はデータ処理装置201から順編成ファイル3
01およびコントロールファイル302への物理入出力
要求信号をそれぞれ示す。FIG. 1 is a block diagram showing the configuration of a sequential file access method using a control file according to an embodiment of the present invention. The sequential file access method using a control file of this embodiment includes a user program 101, a service program 102, a control file initialization preparation means 202. Control file creation means 203. Control file reference means 204 and control file service means 205
data processing bag N201 containing
and a control file 302. In addition, in FIG. 1, the reference numeral 11 indicates the user program 101.
12 is a control file update request signal from the service program 102, 13, 14 and 15 are control file initialization preparation means 202, control file creation means 203 and control file creation means 203 in sequential file input/output processing. A processing request signal 16 is sent to the control file reference means 204 from the sequential file 3 from the data processing device 201.
01 and a physical input/output request signal to the control file 302, respectively.
第2図は、コントロールファイル302の内容を示した
ものであり、ファイルラベル領域と、復数のレコード制
御情報領域とから構成されている。FIG. 2 shows the contents of the control file 302, which is composed of a file label area and multiple record control information areas.
ファイルラベル領域には、コントロールファイル302
であることを示す情報、対応する順編成ファイル301
との整合性をとる情報等が格納される。レコード制御情
報は、レコード番号と、コントロール情報と、対応する
tit成ファイル301の各レコードのレコードサイズ
とから構成され、111[1成ファイル301本体のレ
コード数と同数存在する。コントロール情報には、主に
スキップ(SKIP)情報と終了(IEND)情報とが
あり、コントロールファイル作成手段2o3およびコン
トロールファイルサービス手段205によって順編成フ
ァイル301に存在するレコードを論理的に削除したり
、論理的なファイルエンド(EOF)を設定したりする
制御を行う。The file label area contains the control file 302.
Information indicating that the corresponding sequential file 301
Information etc. to ensure consistency with the data is stored. The record control information is composed of a record number, control information, and the record size of each record of the corresponding tit file 301, and there are 111 records equal to the number of records in the body of the tit file 301. The control information mainly includes skip (SKIP) information and end (IEND) information, and records existing in the sequential file 301 can be logically deleted by the control file creation means 2o3 and the control file service means 205, Performs control such as setting the logical end of file (EOF).
第3図を参照すると、利用者プログラム101における
コントロールファイル302の作成時の処理は、順編成
ファイルオーブン(OPEN)コマンド実行ステップ2
1と、順編成ファイルリード(READ)コマンド実行
ステップ22と、順編成ファイルEOF判定ステップ2
3と、有効レコード判定ステップ24と、5KIPコマ
ンド実行ステップ25と、終了判定ステップ26と、E
NDコマンド実行ステップ27と、ll[wA成ラフア
イルクローズCL OS E)コマンド実行ステップ2
8とからなる。Referring to FIG. 3, the process when creating the control file 302 in the user program 101 is performed in step 2 of executing the sequential file oven (OPEN) command.
1, sequential file read (READ) command execution step 22, and sequential file EOF determination step 2
3, a valid record determination step 24, a 5KIP command execution step 25, an end determination step 26, and an E
ND command execution step 27, ll[wA formation rough aisle close CL OS E) command execution step 2
It consists of 8.
第4図を参照すると、コントロールファイル初期化!1
!備手段202における処理は、順編成ファイルオーフ
ン処理ステップ31と、コントロールファイル有無判定
ステップ32と、コントロールファイル初期化判定ステ
ップ33と、コントロールファイル初期化処理ステップ
34と、コントロールファイル参照準備処理ステップ3
5とからなる。Referring to Figure 4, control file initialization! 1
! The processing in the preparation means 202 includes a sequential file orphan processing step 31, a control file presence/absence determination step 32, a control file initialization determination step 33, a control file initialization processing step 34, and a control file reference preparation processing step 3.
It consists of 5.
第5図を参照すると、利用者プログラム101における
READENDコマンド実行ップ22)時のコントロー
ルファイル作成手段203の処理は、順編成ファイルル
コード読出しステップ41と、コントロールファイルレ
コード制御B情報書込みステップ42とからなる。Referring to FIG. 5, the processing of the control file creation means 203 during the READEND command execution step 22) in the user program 101 includes a sequential file code reading step 41 and a control file record control B information writing step 42. Consisting of
第6図を参照すると、利用者プログラム101における
5KIPコマンド実行(ステップ25)時のコントロー
ルファイル作成手段203の処理は、レコード制御情報
への5KIP情報書込みステップ51からなる。Referring to FIG. 6, the processing of the control file creation means 203 when executing the 5KIP command (step 25) in the user program 101 consists of a step 51 of writing 5KIP information into record control information.
第7図を参照すると、利用者プログラム101における
ENDコマンド(ステップ27)実行時のコントロール
ファイル作成手段203の処理は、レコード制御情報E
ND情報書込みステップ61と、残余レコード数レコー
ド制御情報書込みステップ62とからなる。Referring to FIG. 7, the process of the control file creation means 203 when executing the END command (step 27) in the user program 101 is as follows:
It consists of an ND information writing step 61 and a remaining record number record control information writing step 62.
第8図を参照すると、コントロールファイル参照手段2
04における処理は、順編成ファイルEOF判定ステッ
プ71と、レコード制御情報5KIP情報判定ステップ
72と、ポインタ更新ステップ73と、順編成ファイル
ルコード読出しステップ74と、レコード制御情報EN
D情報判定ステップ75と、次READコマンド実行順
編成ファイルEOF設定ステップ76とからなる。Referring to FIG. 8, control file reference means 2
04 includes a sequential file EOF determination step 71, a record control information 5KIP information determination step 72, a pointer update step 73, a sequential file code reading step 74, and a record control information EN
It consists of a D information determination step 75 and a next READ command execution order file EOF setting step 76.
次に、このように構成された本実施例のコントロールフ
ァイルを利用したM[成ファイルアクセス方式の動作に
ついて説明する。Next, the operation of the M file access method using the control file of this embodiment configured as described above will be explained.
本実施例のコントロールファイルを利用した順編成ファ
イルアクセス方式の基本的な処理の流れとしては、利用
者プログラム101がデータ処理装置201を介して順
編成ファイル301に対して順次アクセスを行うが、コ
ントロールファイル302がそのプロセスに存在する場
合は、処理内容に応じてコントロールファイル参照手段
2o4゜コントロールファイル作成手段203またはコ
ントロールファイルサービス手段205がそれぞれ起動
され、コントロールファイル302を制御しながら順編
成ファイル301をアクセスする。また、サービスプロ
グラム102によってコントロールファイルサービス手
段205を直接起動し、コントロールファイル302の
更新や複写などを行う。The basic processing flow of the sequential file access method using the control file of this embodiment is that the user program 101 sequentially accesses the sequential file 301 via the data processing device 201. If the file 302 exists in the process, the control file reference means 2o4, the control file creation means 203, or the control file service means 205 are activated depending on the processing content, and the sequential file 301 is controlled while controlling the control file 302. to access. Further, the control file service means 205 is directly activated by the service program 102 to update or copy the control file 302.
ill まず、コントロールファイル302を作成す
る処理について詳しく説明する。ill First, the process of creating the control file 302 will be explained in detail.
利用者プログラム101で順編成ファイル301の0P
ENコマンドが実行されると(ステップ21)、コント
ロールファイル初期化準備手段202は、従来と同様の
順編成ファイル301のオープン処理を行った後(ステ
ップ31)、コントロールファイル302の有無を判定
しくステップ32)、コントロールファイル302がな
ければそのまま処理を終了する。コントロールファイル
302があれば、コントロールファイル初期化準備手段
202は、利用者プログラム101からのコントロール
ファイル初期化指示がアウトプットモードか(初期化す
るか)インプットモードか(初期化しないか)を判断し
くステップ33)、コントロールファイル302の作成
時には初期化する必要があるのでコントロールファイル
302のオーブン処理等を含む初期化処理を行う(ステ
ップ34)。0P of the sequential file 301 in the user program 101
When the EN command is executed (step 21), the control file initialization preparation means 202 performs the same opening process as before for the sequential file 301 (step 31), and then determines whether the control file 302 exists or not. 32) If the control file 302 does not exist, the process ends. If there is a control file 302, the control file initialization preparation means 202 must determine whether the control file initialization instruction from the user program 101 is output mode (to be initialized) or input mode (to be initialized). Step 33), since it is necessary to initialize the control file 302 when creating it, initialization processing including oven processing of the control file 302 is performed (step 34).
次に、利用者プログラム101が順編成ファイル301
のREADENDコマンドすると(ステップ22)、コ
ントロールファイル作成−[203は、順編成ファイル
301からルコードを読み出しくステップ41)、読み
出したレコードのレコード番号およびレコードサイズか
らレコード制御情報を作成してコントロールファイル3
02に書き込む(ステップ42)。Next, the user program 101 starts the sequential organization file 301
When the READEND command is executed (step 22), the control file is created - [203 reads the code from the sequential file 301 (step 41), record control information is created from the record number and record size of the read record, and the control file 3 is created.
02 (step 42).
続いて、利用者プログラム101は、順編成ファイル3
01がEOFであるかどうかを判定しくステップ23)
、EOFであればステップ28に制御を移し、EOF
でなければ読み出したレコードの内容等に基づいて有効
レコードであるかどうかを判定する(ステップ24)。Next, the user program 101 writes the sequential file 3
Step 23) Determine whether 01 is EOF or not.
, EOF, control is transferred to step 28, EOF
If not, it is determined based on the contents of the read record whether it is a valid record or not (step 24).
読み出したレコードが有効レコードでなければ、利用者
プログラム101は、5KIPコマンドを実行しくステ
ップ25)、読み出したレコードが有効レコードであれ
ば5KIPコマンドを実行しない。If the read record is not a valid record, the user program 101 executes the 5KIP command (step 25); if the read record is a valid record, the user program 101 does not execute the 5KIP command.
利用者プログラム101が5KIPコマンドを実行する
と、コントロールファイル作成手段203は、ステップ
42でコントロールファイル302に書き込んだレコー
ド制御情報のコントロール情報に5KIP情報を書き込
み、順編成ファイル301の対応するレコードを仮想的
に削除する(ステップ51)。When the user program 101 executes the 5KIP command, the control file creation means 203 writes 5KIP information into the control information of the record control information written to the control file 302 in step 42, and virtually creates the corresponding record of the sequential file 301. (Step 51).
次に、利用者プログラム101は、処理を終了するかど
うかを判定しくステップ26)、終了しないのであれば
ステ・ノブ22に制御を戻し、終了するのであればEN
Dコマンドを実行する(ステップ27)。Next, the user program 101 determines whether or not to terminate the process (step 26). If not, return control to the steering knob 22, and if to terminate, press EN.
Execute the D command (step 27).
利用者プログラム101が順編成ファイル301の全レ
コードを読み込まないうちにENDコマンドを実行した
場合は、コントロールファイル作成手段203は、ステ
ップ22でコントロールファイル302に書き込んだレ
コード制御情報のコントロール情報にEND情報を書き
込んで順編成ファイル301の仮想的なEOFを設定し
た後(ステップ61)、順編成ファイル301の残りの
レコードを内部的に順次読み込んでその数分のレコード
制御情報をコントロールファイル302内に書き込む(
ステップ62)。If the user program 101 executes the END command before reading all records of the sequential file 301, the control file creation means 203 adds END information to the control information of the record control information written to the control file 302 in step 22. After setting the virtual EOF of the sequential file 301 by writing (step 61), the remaining records of the sequential file 301 are internally read sequentially and record control information for that number is written in the control file 302. (
Step 62).
最後に、利用者プログラム101は、順編成ファイル3
01のCLO3Eコマンドを実行する(ステップ28)
。Finally, the user program 101 executes the sequential organization file 3
Execute the CLO3E command of 01 (step 28)
.
利用者プログラム101でCLO3Eコマンドが実行さ
れると、利用者プログラム作成手段203は、順編成フ
ァイル301のクローズ処理を行うとともに、コントロ
ールファイル302のクローズ処理も行う。When the CLO3E command is executed by the user program 101, the user program creation means 203 performs the closing process of the sequential file 301 and also closes the control file 302.
このようにしてコントロールファイル302が作成され
るが、作成済のコントロールファイル302をサービス
プログラム102からコントロールファイルサービス手
段205を使用することによって、5KIP9i報やE
ND!報をキャンセルしたり、新たに追加したり、コン
トロールファイル302をコピーして別のコントロール
ファイル302を作成したりすることができる。The control file 302 is created in this way, but by using the control file service means 205 from the service program 102, the control file 302 that has already been created can be used for 5KIP9i information and E-mail.
ND! You can cancel the information, add a new one, or copy the control file 302 to create another control file 302.
+2) &に、コントロールファイル302を11し
て順編成ファイル301を仮想的なファイルとしてアク
セスする処理について説明する。+2) &, the process of setting the control file 302 to 11 and accessing the sequential file 301 as a virtual file will be described.
利用者プログラム101で順編成ファイル301の0P
ENコマンドが実行されると、コントロールファイル初
期化準備手段202は、従来と同様の順編成ファイル3
01のオーブン処理を行った後(ステップ31)、コン
トロールファイル302の有無を判定しくステップ32
)、コントロールファイル302がなければそのまま終
了し、コントロールファイル302があれば、利用者プ
ログラム101からのコントロールファイル初期化指示
がアウトブ、7 )モードか(初期化するか)インプッ
トモードか(初期化しないか)を判断しくステップ33
ン、コントロールファイルの参照時には初期化しないの
で指示されたコントロールファイル302が順編成ファ
イル301に対応するものであることを確認した後にコ
ントロールファイル302のオーブン処理等を含む参照
準備処理を行う(ステップ35)。0P of the sequential file 301 in the user program 101
When the EN command is executed, the control file initialization preparation means 202 creates a sequential file 3 similar to the conventional one.
After performing the oven processing of 01 (step 31), the presence or absence of the control file 302 is determined in step 32.
), if there is no control file 302, the process ends as is; if there is a control file 302, the control file initialization instruction from the user program 101 is disabled. Step 33
The control file 302 is not initialized when referenced, so after confirming that the specified control file 302 corresponds to the sequential file 301, reference preparation processing including oven processing of the control file 302 is performed (step 35). ).
次に、利用者プログラム101がvi編成ファイル30
1のREADコマンドを実行すると、コントロールファ
イル参照手段204は、順編成ファイル301がEOF
でないかどうかを判定しくステップ7 1) 、EOF
であればそのまま処理を終了し、IEOFでなければ要
求があったレコードに対応スるコントロールファイル3
02内のレコード制御情報を参照してコントロール情報
がSKIP情報でないかどうかを調査する(ステップ7
2)。Next, the user program 101 uses the vi organization file 30
When the READ command 1 is executed, the control file reference means 204 determines that the sequential file 301 is EOF.
Step 7 1) , EOF
If it is IEO, the process ends, and if it is not IEO, the control file 3 corresponding to the requested record is created.
Check whether the control information is not SKIP information by referring to the record control information in 02 (step 7
2).
コントロール情報にSKIP情報がセットされていた場
合には、コントロールファイル参照手段204は、レコ
ードは読み込まずにレコードを仮想的に削除するために
そのカレンンとコントロールファイル302のポインタ
とをルコード分ずつ進めて(ステップ73)、次のレコ
ードのレコード制御情報がSKIP情報であるかどうか
を調査する(ステップ72)。レコード制御情報のコン
トロール情報がSKIP情報でない場合は、コントロー
ルファイル参照手段204は、順編成ファイル301か
らレコードを読み出してそのレコードを利用者プログラ
ム101に転送しくステ・ノブ74)、コントロール情
報がEND情報でないかどうかを調査する(ステップ7
5)、コントロール情報がEND!報でない場合はその
まま処理を終了し、END情報であった場合には、利用
者プログラム101からの次のREADコマンド実行時
に順編成ファイル301がEOF状態になるような仮想
的なEOFを設定して(ステップ76)、処理を終了す
る。If SKIP information is set in the control information, the control file reference means 204 advances the current calendar and the pointer of the control file 302 by the number of codes in order to virtually delete the record without reading the record. (Step 73), and checks whether the record control information of the next record is SKIP information (Step 72). If the control information in the record control information is not SKIP information, the control file reference means 204 reads the record from the sequential file 301 and transfers the record to the user program 101 (step knob 74), and the control information is END information. (Step 7)
5), Control information is END! If it is not information, the process is terminated, and if it is END information, a virtual EOF is set so that the sequential file 301 will be in the EOF state when the next READ command from the user program 101 is executed. (Step 76), the process ends.
上記のような処理を行うことによって、第9図(a)の
ような順編成ファイル301を第9図(b)のようなコ
ントロールファイル302を411して人力した場合、
データレコード2および5がスキップされ、データレコ
ード6を読み込んだ後にEOFとなるため、第9図(C
)のような順番でレコードが読み込まれることになる。By performing the above processing, if the sequential organization file 301 as shown in FIG. 9(a) is manually created by converting the control file 302 as shown in FIG. 9(b) into 411,
Data records 2 and 5 are skipped, and EOF occurs after data record 6 is read.
) records will be read in the following order.
このように、本実施例では、順編成ファイル301本体
を加工せずに外部のコントロールファイル302のレコ
ード制御種情報に基づいて仮想的に別のファイルとして
順編成ファイル301を利用することができ、コントロ
ールファイル302を複数種類用意すればその数分のフ
ァイルとして利用することが可能となるため、記憶媒体
上のファイルスペースを節約することができる。In this way, in this embodiment, the sequential file 301 can be used as a virtual separate file based on the record control type information of the external control file 302 without modifying the main body of the sequential file 301. If a plurality of types of control files 302 are prepared, it becomes possible to use the same number of files, thereby saving file space on the storage medium.
以上説明したように本発明は、コントロールファイル初
期化準備手段.コントロールファイル作成手段,コント
ロールファイル参照手段およびコントロールファイルサ
ービス手段を設けたことにより、大容量記憶媒体上の順
編成ファイルを外部のコントロールファイルのレコード
制御情報によってファイルの一部分を1フアイルとして
参照したり幾つかのレコードを除いたものを1フアイル
として参照したり仮想的に別のファイルのように使用し
たりすることができ、コンI・ロールファイルを複数用
意することで1個の順編成ファイルを何遍りにも使うこ
とが可能となって、記憶媒体上のファイルスペースを有
効に利用できるという効果がある。As explained above, the present invention provides control file initialization preparation means. By providing a control file creation means, a control file reference means, and a control file service means, a part of a sequential file on a mass storage medium can be referred to as one file by record control information of an external control file. You can refer to the file excluding that record as one file or use it virtually as a separate file, and by preparing multiple control/roll files, you can store one sequential file This has the effect of making it possible to use it evenly and making effective use of the file space on the storage medium.
第1図は本発明の一実施例に係るコントロールファイル
を利用した順編成ファイルアクセス方式の構成を示すブ
ロック図、
第2図は第1図中のコントロールファイルの内容を示す
図、
第3図は第1図中の利用者プログラムにおけるコントロ
ールファイル作成時の処理を示す流れ図、第4図は第1
図中のコントロールファイル初期化準備手段の処理を示
す流れ図、
第5図は第3図中の利用者プログラムにおけるREAD
コマンド実行時のコントロールファイル作成手段の処理
を示す流れ図、
第6図は第3図中の利用者プログラムにおける5KIP
コマンド実行時のコントロールファイル作成手段の処理
を示す流れ図、
第7図は第3図中の利用者プログラムにおけるE N
D ’:177 )−実行時のコントロールファイル作
成手段の処理を示す図、
第8図は第1図中のコントロールファイル参照手段の処
理を示す流れ図、
第9図(a)〜(c)は本実施例の方式によりコントロ
ールファイルを利用して順編成ファイルを読み込んだ場
合の一例を示す図である。
図において、
11・・順編成ファイルアクセス要求信号、12・・コ
ントロールファイル更新要求信号、13.14.15・
処理要求信号、
16・・物理入出力要求信号、
101・利用者プログラム、
102・サービスプログラム、
20トデータ処理装置、
202・コントロールファイル初期化準備手段、203
・コントロールファイル作成手段、204・コントロー
ルファイル作成手段、205・コントロールファイルサ
ービス手段、301・順編成ファイル、
302・コントロールファイルである。FIG. 1 is a block diagram showing the configuration of a sequential file access method using a control file according to an embodiment of the present invention, FIG. 2 is a diagram showing the contents of the control file in FIG. 1, and FIG. A flowchart showing the process when creating a control file in the user program in Figure 1, and Figure 4 is a flowchart showing the process when creating a control file in the user program.
A flowchart showing the processing of the control file initialization preparation means in the figure.
A flowchart showing the processing of the control file creation means when executing a command, Figure 6 shows the 5KIP in the user program in Figure 3.
A flowchart showing the processing of the control file creation means when executing a command, FIG. 7 shows the E N in the user program in FIG.
D': 177) - A diagram showing the processing of the control file creation means during execution, Figure 8 is a flowchart showing the processing of the control file reference means in Figure 1, and Figures 9 (a) to (c) are the main FIG. 7 is a diagram illustrating an example of reading a sequential file using a control file according to the method of the embodiment. In the figure, 11... Sequential file access request signal, 12... Control file update request signal, 13.14.15.
Processing request signal, 16. Physical input/output request signal, 101. User program, 102. Service program, 20. Data processing device, 202. Control file initialization preparation means, 203.
Control file creation means, 204 Control file creation means, 205 Control file service means, 301 Sequential file, 302 Control file.
Claims (1)
ードを順次読み込み利用者プログラムからの指示を基に
有効レコードか否かを判定し各レコードに対するレコー
ド制御情報をコントロールファイルに登録していくコン
トロールファイル作成手段と、 このコントロールファイル作成手段によって作成された
コントロールファイル内のレコード制御情報を基に前記
順編成ファイル内の有効レコードのみを順次取り出すこ
とを可能とするコントロールファイル参照手段と、 利用者プログラムからの要求がコントロールファイルの
作成か参照かを判定し作成要求であれば前記コントロー
ルファイル作成手段に制御を渡し参照要求であれば前記
コントロールファイル参照手段に制御を渡すコントロー
ルファイル初期化準備手段と、 作成済みのコントロールファイルのレコード制御情報を
消去したり更新したり別ファイルに複写したりする処理
を可能とするコントロールファイルサービス手段と を有することを特徴とするコントロールファイルを利用
した順編成ファイルアクセス方式。[Claims] Records are sequentially read from a sequential file configured on a large-capacity storage medium, and it is determined whether or not the record is valid based on instructions from the user program, and record control information for each record is stored in a control file. control file creation means for registering; and control file reference means that makes it possible to sequentially retrieve only valid records in the sequential file based on record control information in the control file created by the control file creation means. and determining whether the request from the user program is to create or reference a control file, and if it is a creation request, control is passed to the control file creation means, and if it is a reference request, control is passed to the control file reference means. and a control file service means that enables processes such as erasing, updating, or copying record control information of a created control file to another file. Sequential file access method.
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2015692A JPH03219340A (en) | 1990-01-25 | 1990-01-25 | Sequential organization file accessing system utilizing control file |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2015692A JPH03219340A (en) | 1990-01-25 | 1990-01-25 | Sequential organization file accessing system utilizing control file |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| JPH03219340A true JPH03219340A (en) | 1991-09-26 |
Family
ID=11895817
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP2015692A Pending JPH03219340A (en) | 1990-01-25 | 1990-01-25 | Sequential organization file accessing system utilizing control file |
Country Status (1)
| Country | Link |
|---|---|
| JP (1) | JPH03219340A (en) |
-
1990
- 1990-01-25 JP JP2015692A patent/JPH03219340A/en active Pending
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| US5907703A (en) | Device driver for accessing computer files | |
| JP3005645B2 (en) | How to read and write files on non-erasable storage media | |
| US6192444B1 (en) | Method and system for providing additional addressable functional space on a disk for use with a virtual data storage subsystem | |
| JP2719464B2 (en) | File management system | |
| US6405265B1 (en) | Device driver for accessing computer files | |
| US4593354A (en) | Disk cache system | |
| JP2004355660A (en) | Method of storing data object, using small object data stream | |
| JP2001051882A (en) | Snapshot reference method and storage device | |
| JP4394467B2 (en) | Storage system, server apparatus, and preceding copy data generation method | |
| US8909875B1 (en) | Methods and apparatus for storing a new version of an object on a content addressable storage system | |
| US6591264B1 (en) | Method that allows I/O requests to run concurrently with a rollback from a snapshot in a drive array | |
| JPH03219340A (en) | Sequential organization file accessing system utilizing control file | |
| JPH0322046A (en) | Control method for file using draw type storage medium | |
| JPH07253894A (en) | Shared storage | |
| JP2767966B2 (en) | High-speed file access method | |
| US8010741B1 (en) | Methods and apparatus for controlling migration of content | |
| JP3376316B2 (en) | Disk array device, high-speed communication method used therefor, and recording medium recording control program therefor | |
| JP2771986B2 (en) | Magnetic tape unit | |
| JPH10143406A (en) | File management device | |
| JPH09282202A (en) | Data movement management system | |
| JPH01255918A (en) | Control system for disk system with mixed sector length | |
| JPH03257521A (en) | Medium copy system | |
| JPH06168079A (en) | Data backup system | |
| JPS63271769A (en) | Data correction system for non rewritable medium | |
| Brumbaugh et al. | The'Little Man Storage'model |