JP3109331B2 - Form output device - Google Patents

Form output device

Info

Publication number
JP3109331B2
JP3109331B2 JP05173635A JP17363593A JP3109331B2 JP 3109331 B2 JP3109331 B2 JP 3109331B2 JP 05173635 A JP05173635 A JP 05173635A JP 17363593 A JP17363593 A JP 17363593A JP 3109331 B2 JP3109331 B2 JP 3109331B2
Authority
JP
Japan
Prior art keywords
record
item
code
file
name
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired - Fee Related
Application number
JP05173635A
Other languages
Japanese (ja)
Other versions
JPH0778214A (en
Inventor
利雄 東原
栗原  隆
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Casio Computer Co Ltd
Original Assignee
Casio Computer Co 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 Casio Computer Co Ltd filed Critical Casio Computer Co Ltd
Priority to JP05173635A priority Critical patent/JP3109331B2/en
Priority to US08/261,723 priority patent/US5642521A/en
Publication of JPH0778214A publication Critical patent/JPH0778214A/en
Application granted granted Critical
Publication of JP3109331B2 publication Critical patent/JP3109331B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Landscapes

  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Description

【発明の詳細な説明】DETAILED DESCRIPTION OF THE INVENTION

【0001】[0001]

【産業上の利用分野】この発明は、オフィスコンピュー
タやパーソナルコンピュータ等において、会計ファイ
ル、人事ファイル等からレコードデータを読み出して帳
票出力する帳票出力装置に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a form output device for reading out record data from an accounting file, a personnel file, etc. and outputting the form in an office computer or a personal computer.

【0002】[0002]

【従来の技術】従来、オフィスコンピュータや汎用コン
ピュータ等の事務処理装置においては、会計ファイル、
人事ファイル、売上伝票ファイル、在庫ファイル等、各
種多様のファイルを記憶管理しているが、各ファイルを
構成するレコード構造は、ファイル毎に異なっており、
同一レコード形態(レコードを構成する各項目が一致す
るレコード)毎にまとめて別ファイルとして記憶管理し
ている。ところで、任意の項目を指定してその項目を含
むレコードをファイルから読み出し、分類毎に区分して
帳票出力させる場合において、項目内のデータを最初、
分類集計し易いような分類コード体系で作っていても、
時の経過につれて分類が現実に適合しなくなり、そのま
までは分類毎に出力することができなくなる。そこで、
従来においては、この対策として分類用のコード変換テ
ーブルを設け、このコード変換テーブルを用いて分類に
最適なコード体系に変換する方法が現状広く採用されて
いる。
2. Description of the Related Art Conventionally, in an office processing device such as an office computer or a general-purpose computer, an accounting file,
Various types of files such as personnel files, sales slip files, and inventory files are stored and managed, but the record structure that constitutes each file is different for each file.
Each file is stored and managed as a separate file for each record of the same form (records in which each item of the record matches). By the way, when an arbitrary item is specified, a record including the item is read from the file, and the data is output in a form that is classified for each classification.
Even if it is made with a classification code system that makes it easy to classify and aggregate,
As time elapses, the classification does not actually match, and it becomes impossible to output each classification as it is. Therefore,
Conventionally, as a countermeasure, a method of providing a code conversion table for classification and using the code conversion table to convert to a code system most suitable for classification is currently widely used.

【0003】[0003]

【発明が解決しようとする課題】しかしながら、コード
変換テーブルを用いる方法では専門家であるシステムエ
ンジニアが分類用のコード体系(変換テーブル)を作成
しなければならなかった。即ち、種々の業務上の要望に
応じて分類コード体系を作成することは極めて専門的で
高度な知識を必要とする為、一般ユーザの業務担当者に
あってはその作成は極めて困難であり、システムエンジ
ニアにその作成を依頼しなければならないのが現状であ
った。この発明の課題は、所望する帳票を得る為に、出
力レベルおよび出力レコードを抽出する際の対象項目を
示すコード条件を複数の項目に対応付けて指定するだけ
で、複数のコード条件に合致するレコードを指定内容通
りの階層構造に分類して出力できるようにすることであ
る。
However, in the method using the code conversion table, a system engineer who is an expert must create a code system (conversion table) for classification. In other words, creating a classification code system in response to various business needs requires extremely specialized and advanced knowledge, and it is extremely difficult for a general user's business staff to create it. At present, it was necessary to ask a system engineer to create it. An object of the present invention is to specify a code condition indicating an output level and a target item at the time of extracting an output record in association with a plurality of items in order to obtain a desired form. The purpose is to classify records into a hierarchical structure as specified and output them.

【0004】[0004]

【課題を解決するための手段】この発明は、複数の項目
からなるレコードを複数記憶するレコード記憶手段と、
レコードを複数階層にて帳票出力する際の第1階層のレ
コード名の第1項目とその第1項目における抽出コード
条件、第2階層のレコード名の第2項目とその第2項目
における抽出コード条件、の対応付けを定義する第1定
義表を記憶する第1定義記憶手段と、上記レコードに含
まれる各項目の中で上記帳票出力に必要な出力対象項目
を定義する第2定義表を記憶する第2定義記憶手段と、
上記第1項目の抽出コード条件に合致する項目コードを
有する第1階層レコード、上記第1項目の抽出コード条
件に合致する項目コードと上記第2項目の抽出コード条
件に合致する項目コードとを共に有する第2階層レコー
ド、を抽出する抽出手段と、上記抽出手段で抽出された
各レコードに基いて帳票作成を行う際は、抽出された上
記第1階層レコードにおける上記第1項目の項目コード
に対応する名称をその帳票におけるレコード名とし、抽
出された上記第2階層レコードにおける上記第2項目の
項目コードに対応する名称をその帳票におけるレコード
名とし、且つ抽出された第1、第2階層の各レコードに
ついて、その個々のレコード毎に上記第2定義表にて定
義された各出力対象項目の内容を読み出して上記レコー
ド名に対応付けて配置した帳票を作成する帳票作成手段
と、上記作成された帳票を出力する出力手段と、を具備
したことを特徴とする。
According to the present invention, a record storage means for storing a plurality of records each including a plurality of items,
The first item of the record name of the first hierarchy and the extraction code condition in the first item, and the second item of the record name of the second hierarchy and the extraction code condition in the second item when the records are output in a plurality of hierarchies , And a second definition table for defining an output target item necessary for the form output among the items included in the record. Second definition storage means;
A first hierarchical record having an item code matching the first item extraction code condition, an item code matching the first item extraction code condition and an item code matching the second item extraction code condition are both included. Extracting means for extracting a second-level record having the information, and when creating a form based on each record extracted by the extracting means, a form corresponding to the item code of the first item in the extracted first-level record Is the record name in the form, the name corresponding to the item code of the second item in the extracted second-level record is the record name in the form, and each of the extracted first and second layers For each record, read out the contents of each output target item defined in the second definition table for each record and associate it with the record name. A form creation unit that creates a form that location, characterized by comprising output means for outputting the created document, the.

【0005】[0005]

【0006】[0006]

【第1実施例】以下、図1〜図15を参照して第1実施
例を説明する。図1は本実施例に係るデータ処理装置の
ブロック構成図である。このデータ処理装置はオフィス
コンピュータを構成するもので、専門的知識を有しない
業務担当者等が集計定義表を用いて集計レベル毎に集計
対象等を任意に指定しておくだけで、この集計定義表の
定義内容に該当するレコードを所定ファイルから読み出
して集計レベルに応じた階層構造でレコードを分類集計
し、この集計結果を帳票データとして印刷出力するもの
である。入力部1は各種のデータやコマンド等を入力す
るキー入力装置で、入力部1から入力されたデータはパ
ラメータ設定部2に取り込まれて処理されると共に表示
部3に表示出力される。なお、入力部1は所定のキー操
作に応答してパラメータ設定部2に対して起動命令を与
える。
First Embodiment Hereinafter, a first embodiment will be described with reference to FIGS. FIG. 1 is a block diagram of the data processing apparatus according to the present embodiment. This data processing device constitutes an office computer, and a person in charge of business, etc. who does not have specialized knowledge simply specifies an aggregation target or the like at each aggregation level using an aggregation definition table. Records corresponding to the definition contents of the table are read from a predetermined file, the records are classified and totaled in a hierarchical structure according to the totaling level, and the totaling result is printed out as form data. The input unit 1 is a key input device for inputting various data, commands, and the like. Data input from the input unit 1 is taken into the parameter setting unit 2, processed, and displayed on the display unit 3. Note that the input unit 1 gives a start command to the parameter setting unit 2 in response to a predetermined key operation.

【0007】パラメータ設定部2は入力部1からの起動
命令に応答して動作し、業務担当者等が所望する任意の
レコード集計を指示する為に集計レコードのレコード名
の配置位置や集計対象項目のコード条件等を定義する定
義表(本実施例にあっては2種類のA表、B表)を入力
部1から入力されたデータにしたがって生成し、表示部
3から表示出力させると共に、パラメータファイル4に
設定する。なお、A表、B表については後で詳細に説明
するので、ここでは簡単に説明しておくものとする。
The parameter setting unit 2 operates in response to a start command from the input unit 1, and in order to instruct an arbitrary record aggregation desired by a business person or the like, the arrangement position of the record name of the aggregation record and the aggregation target item (In this embodiment, two types of tables A and B) are generated in accordance with the data input from the input unit 1 and are displayed and output from the display unit 3, and the parameters are displayed. Set in file 4. The tables A and B will be described in detail later, and will be described briefly here.

【0008】例えば、所望する帳票として図2に示す様
な「売上実績表」を印刷出力させる為に、この帳票の出
力イメージにしたがった集計定義表としてA表およびB
表を生成しておく。ここで、図2に示す帳票は集計レコ
ードのレコード名を行項目に配置し、また集計レコード
のデータ項目名を列項目に配置したものであり、この帳
票を得る為に定義されたA表は図3の(A)、B表は図
3の(B)に示す如く構成されている。A表は集計対象
のファイル名の他、集計レベルに対応して集計レコード
におけるレコード名の配置位置や出力レコードを抽出す
る際の対象項目を示すコード条件等を定義する。即ち、
図示の例において、集計対象のファイル名として「回収
ファイル」が指定され、また、実際のレコード名、例え
ば○○営業所、××営業所等に代わる総括的な代用名称
として「営業所」を括弧書きで記述することによってレ
コード名の配置位置が指定されている。なお、この記述
の仕方は任意であり、レコード名の配置位置に丸印を付
ける等の簡単な方法で位置指定を行ってもよいが、本実
施例においては総括的な代用名称を記述し、その名称が
代用名称であることを示す為に括弧で囲むようにしてい
る。また、集計レコードを抽出する際の対象項目を示す
コード条件として例えば「10?」が指定されている。
このコード条件「10?」は項目コードから3桁の数値
コードから成り、その上位2桁の値「10」を含む全て
の項目コードを集計対象項目とすることを示している。
つまり、複数の項目コードを1つの定義で一括指定する
為に、?マークを付けた記述でコード条件を定義してい
るが、1つの項目コードのみを指定する場合には項目コ
ードをそのままコード条件として定義すればよい。B表
は集計レコードのデータ項目として出力される項目名お
よびこの項目名に対応して帳票印刷時の書式、集計対象
ファイル、データ項目として抽出される集計対象の項目
を定義する。
For example, in order to print out a “sales record table” as shown in FIG. 2 as a desired form, tables A and B are used as a total definition table according to the output image of the form.
Generate a table. Here, the form shown in FIG. 2 has the record name of the tally record arranged in a row item and the data item name of the tally record arranged in a column item. Table A defined to obtain this form is 3A and 3B are configured as shown in FIG. 3B. The table A defines, in addition to the file name of the tallying target, the arrangement position of the record name in the tallying record, the code condition indicating the target item when extracting the output record, and the like corresponding to the tallying level. That is,
In the illustrated example, “collected file” is specified as the file name of the aggregation target, and the actual record name, for example, “business office” is used as a general substitute name instead of XX business office, XX business office, etc. The position of the record name is specified by using parentheses. Note that this description method is arbitrary, and the position may be specified by a simple method such as placing a circle at the arrangement position of the record name. However, in this embodiment, a general substitute name is described. Parentheses are used to indicate that the name is a substitute name. In addition, for example, “10?” Is specified as a code condition indicating a target item when a total record is extracted.
The code condition "10?" Is composed of a three-digit numerical code from the item code, and indicates that all item codes including the upper two-digit value "10" are to be counted.
In other words, to specify multiple item codes at once with one definition, use? Although the code condition is defined by the description with the mark, when only one item code is specified, the item code may be defined as it is as the code condition. Table B defines an item name output as a data item of a tally record, a format for printing a form, a tally file, and a tally item extracted as a data item corresponding to the item name.

【0009】パラメータファイル4にはA表、B表に対
応してその基本フォーマット(罫線データ等)が予めメ
ーカサイドによって固定的に格納されている他に、入力
部1から任意に入力された各種帳票のA表パラメータデ
ータ、B表パラメータデータおよび、入力部1から任意
に入力された各種の帳票名とA表パラメータデータ、B
表パラメータデータとを対応付ける対応テーブルが記憶
されている。
In the parameter file 4, the basic format (ruled line data, etc.) corresponding to the tables A and B is fixedly stored in advance by the manufacturer side, and various types of data input arbitrarily from the input unit 1 are also stored. A table parameter data and B table parameter data of the form, and various form names and A table parameter data arbitrarily input from the input unit 1;
A correspondence table for associating with table parameter data is stored.

【0010】表構造解析部5は帳票印刷時に入力部1か
ら入力された起動命令にしたがって動作し、出力対象と
して任意に指定された帳票名に対応するA表パラメータ
データ、B表パラメータデータを解析し、その解析結果
にしたがって構成ファイル7を作成する。ここで、テー
ブルメモリ6は項目コードと名称とを対応付けて成る索
引テーブル等を記憶するもので、この索引テーブル等は
入力部2からユーザが任意に設定したものである。表構
造解析部5はこのテーブルメモリ6を参照し、A表のコ
ード条件に合致する全ての項目コードに対応する名称を
索引テーブルから読み出しながら構成ファイル7の作成
を行う。
The table structure analysis unit 5 operates according to a start command input from the input unit 1 when printing a form, and analyzes the A table parameter data and the B table parameter data corresponding to a form name arbitrarily specified as an output target. Then, the configuration file 7 is created according to the analysis result. Here, the table memory 6 stores an index table and the like in which item codes and names are associated with each other, and the index table and the like are arbitrarily set by the user from the input unit 2. The table structure analyzing unit 5 refers to the table memory 6 and creates the configuration file 7 while reading out the names corresponding to all the item codes matching the code conditions of the table A from the index table.

【0011】ここで、図4はテーブルメモリ6に設定さ
れているテーブルの一部を示している。ファイル認識テ
ーブルはファイル毎に設けられたもので、ファイル項目
名と索引テーブルのテーブル名とを対応付けたテーブル
で、図示のファイル認識テーブルは回収ファイルに対応
するテーブルである。また、営業所テーブル、得意先テ
ーブルは図示したファイル認識テーブルに対応する索引
テーブルで、項目コードとその名称とを対応付けた構成
となっている。この索引テーブルから項目コードに対応
する名称が読み出されて名称の自動生成が行われる。
FIG. 4 shows a part of a table set in the table memory 6. The file recognition table is provided for each file, and is a table in which file item names are associated with table names of index tables. The illustrated file recognition table is a table corresponding to a collected file. The sales office table and the customer table are index tables corresponding to the illustrated file recognition table, and have a configuration in which item codes are associated with their names. The name corresponding to the item code is read from the index table, and the name is automatically generated.

【0012】なお、構成ファイル7は後で詳述するが、
集計対象の項目コードとそれに対応する集計レコードと
の対応関係や集計レベルの階層構造における親子関係
(上下関係)等を表わす各種の構成レコードから成るも
のである。更に、表構造解析部5はB表のヘッダー位置
に定義されている各欄の項目名、例えば“売上額”等の
名称を読み出して印刷書式メモリ8に設定する他、B表
の書式の位置に定義されている各欄の印刷書式を読み出
して印刷書式メモリ8に設定する。その後、表構造解析
部5は展開ファイル作成部9に起動命令を与える。
Although the configuration file 7 will be described later in detail,
It is composed of various types of configuration records indicating the correspondence between the item code to be totalized and the corresponding totals record, the parent-child relationship (vertical relationship) in the hierarchical structure of the totals level, and the like. Further, the table structure analysis unit 5 reads the item name of each column defined at the header position of the table B, for example, the name such as “sales amount” and sets it in the print format memory 8, and also sets the position of the format of the table B. Is read out and set in the print format memory 8. After that, the table structure analysis unit 5 gives a start command to the expanded file creation unit 9.

【0013】展開ファイル作成部9はパラメータ解析テ
ーブル6内の各種テーブル内容を参照し、データファイ
ル10を構成する各種のソースファイルA……Nの中か
ら集計対象ファイルを指定したり、この集計対象ファイ
ルから抽出したレコードに基づいて1レコードずつ展開
レコードを順次生成し、展開ファイル11に書き出す。
これによって展開ファイル11を作成すると、展開ファ
イル作成部9は展開集計処理部12に起動命令を与え
る。
The development file creation unit 9 refers to the contents of various tables in the parameter analysis table 6 and designates a file to be totaled from among various source files A... Based on the records extracted from the file, the expansion records are sequentially generated one record at a time, and written to the expansion file 11.
When the development file 11 is created in this way, the development file creation unit 9 gives a start instruction to the development totalization processing unit 12.

【0014】展開集計処理部12は構成ファイル7を参
照しながら展開ファイル11の内容に基づいて1レコー
ドずつ集計レコードを順次作成し、集計ファイル13に
書き出す。これによって集計ファイル13を作成する
と、展開集計処理部12は印刷処理部14に起動命令を
与える。印刷処理部14は集計ファイル13の内容を印
刷書式メモリ8に設定されている印刷書式にしたがって
1レコードずつ帳票フォーマットと共にプリンタ15か
ら印字出力させることにより、帳票作成を行う。
The development tabulation unit 12 sequentially creates a total record one record at a time based on the contents of the development file 11 with reference to the configuration file 7 and writes it into the total file 13. When the tally file 13 is created in this way, the development tally processing unit 12 gives a start command to the print processing unit 14. The print processing unit 14 forms a form by causing the printer 15 to print out the contents of the tabulation file 13 together with the form format one record at a time in accordance with the print format set in the print format memory 8.

【0015】次に、本実施例の動作を説明する。先ず、
所望する帳票を得る為に入力部1からA表、B表の作成
を指示すると、パラメータ設定部2はこれに応答して動
作する。先ず、A表作成時にパラメータ設定部2はパラ
メータファイル4から読み出したA表の基本フォーマッ
トにしたがって表枠等を表示出力させる。この状態にお
いて、入力部1からA表のパラメータデータを入力す
る。図3の(A)はA表にパラメータデータを入力した
場合の表示例である。ここで、A表の行方向には集計レ
ベルA、B、Cに対応して集計レコードにおけるレコー
ド名の配置位置を特定する為に、実際のレコード名に代
わる総括的な代用名称が括弧書きで入力されている。例
えば、行No「01」には集計レベルAに対応して「(営
業所)」が入力され、また、行No「02」には集計レベ
ルBに対応して「(得意先)」が入力されている。な
お、集計レベルの階層構造はA>B>Cの関係にあり、
この集計レベルに対応してレコード名の配置位置を定義
しておくと、集計レベルに応じた階層構造でレコード集
計が行われ、集計レベルBのレコードはそれよりも上位
レベルにある集計レコードAのレコードに集計される。
Next, the operation of this embodiment will be described. First,
When an instruction to create a table A and a table B is issued from the input unit 1 to obtain a desired form, the parameter setting unit 2 operates in response to the instruction. First, at the time of creating the A table, the parameter setting unit 2 displays and outputs a table frame and the like according to the basic format of the A table read from the parameter file 4. In this state, the input section 1 inputs the parameter data of Table A. FIG. 3A is a display example when parameter data is input to the A table. Here, in the row direction of the table A, in order to specify the arrangement position of the record name in the aggregation record corresponding to the aggregation levels A, B, and C, a general substitute name instead of the actual record name is written in parentheses. Has been entered. For example, “(Sales office)” is input in row No. “01” corresponding to aggregation level A, and “(Customer)” is input in row No. “02” corresponding to aggregation level B. Have been. Note that the hierarchical structure of the aggregation level has a relationship of A>B> C,
If the position of the record name is defined corresponding to the aggregation level, the records are aggregated in a hierarchical structure according to the aggregation level, and the record of the aggregation level B is compared with the record of the aggregation record A at a higher level. Aggregated into records.

【0016】また、A表には任意のファイル名および項
目名が入力されている。例えば、図3の(A)に示すA
表においては、ファイル名「回収ファイル」が入力され
ており、これによって集計レコードをどのファイルから
抽出すべきかの対象ファイル名が定義される。また、フ
ァイル名に対応する項目名として第1指定項目、第2指
定項目が入力されている。例えば、第1指定項目として
項目名「営業所コード」、第2指定項目として項目名
「得意先コード」が入力されており、これによって集計
レコードとして抽出すべき対象項目名が定義される。こ
れらの2つの項目名に対応してA表には集計対象項目の
コード条件がそれぞれ入力されている。即ち、行No「0
1」には第1指定項目に対応してコード条件「10?」
が入力され、また、行No「02」には第2指定項目に対
応してコード条件「3???」が入力されている。この
コード条件「10?」は3桁の数値コードから成る各項
目コードのうちその上位2桁の値「10」を含む全ての
項目コードを集計対象項目とすることを示している。ま
た、コード条件「3???」は4桁の数値コードから成
る各項目コードのうちその上位1桁の値「3」を含む全
ての項目コードを集計対象項目とすることを示してい
る。このように、図示のA表内には複数の項目名に対応
付けてそのコード条件がそれぞれ定義されている。この
場合、複数のレコード条件にそれぞれ該当するレコード
が集計対象となる。つまり、営業所コードの上位2桁に
「10」の値を持ち、かつ得意先コードの上位1桁に
「3」の値を持つ全てのレコードが集計対象となる。な
お、図示の例では階層関係を明確にする為に第1指定項
目のコード条件を行No「01」に定義したが、行No「0
2」の対応位置に定義しても同等である。
In Table A, arbitrary file names and item names are input. For example, A shown in FIG.
In the table, the file name “collected file” is input, and this defines the target file name from which file the totals record should be extracted. Also, a first specification item and a second specification item are input as item names corresponding to the file names. For example, the item name “sales office code” is input as the first specified item, and the item name “customer code” is input as the second specified item, and this defines the target item name to be extracted as the aggregation record. Corresponding to these two item names, the code conditions of the items to be totaled are entered in Table A, respectively. That is, the row No. “0”
For "1", the code condition "10?"
Is input, and the code condition “3 ???” is input in the row No. “02” corresponding to the second designated item. The code condition “10?” Indicates that all item codes including the upper two-digit value “10” of each item code consisting of a three-digit numerical code are to be counted. The code condition “3 ???” indicates that all item codes including the upper one digit value “3” of each item code consisting of a four-digit numerical code are to be counted. As described above, the code conditions are defined in the table A in association with a plurality of item names. In this case, records respectively corresponding to a plurality of record conditions are counted. That is, all records having a value of "10" in the upper two digits of the office code and a value of "3" in the upper one digit of the customer code are to be totaled. In the illustrated example, the code condition of the first designated item is defined in line No. “01” in order to clarify the hierarchical relationship, but the line No. “0”
It is the same even if it is defined at the corresponding position of "2".

【0017】一方、A表には各行Noに対応して出力順序
エリアが設けられており、この「出力順序」は対応する
コード条件に該当するレコード内容をどの順序で出力す
るかを定義するものである。ここで、行No「01」、
「02」に対応する出力順序として図示の例では「コー
ド順」が入力されており、該当レコードを昇順とする様
な並び順で出力すべきことを示している。即ち、例えば
営業所コードのコード条件に一致する項目コードとして
「102」を持ったレコードと「105」を持ったレコ
ードがそれぞれ該当する場合において、先ず、項目コー
ド「102」を持ったレコード、次に、項目コード「1
05」を持ったレコードの並び順で出力すべきことを定
義している。なお、「出力順序」としてはコード順の
他、名称順、逆順等であってもよい。また、A表には各
行に対応して管理単位エリアが設けられており、任意の
行を指定してそれに対応する位置に丸印を入力する。な
お、この管理単位は構成ファイル7の作成時に参照され
る。このようにしてA表を作成すると、パラメータ設定
部2はそのパラメータデータをパラメータファイル4に
設定する。
On the other hand, the table A has an output order area corresponding to each row No. The "output order" defines the order in which the record contents corresponding to the corresponding code condition are output. It is. Here, row No. “01”,
In the example shown in the figure, "code order" is input as the output order corresponding to "02", indicating that the corresponding records should be output in ascending order. That is, for example, in a case where a record having "102" and a record having "105" as the item codes that match the code condition of the sales office code respectively correspond, first, a record having the item code "102", And item code "1"
05 "should be output in the order of the records. Note that the “output order” may be in the order of names, reverse order, or the like in addition to the order of codes. In the table A, a management unit area is provided corresponding to each row, and an arbitrary row is designated and a circle is inputted at a position corresponding to the row. This management unit is referred to when the configuration file 7 is created. When the table A is created in this way, the parameter setting unit 2 sets the parameter data in the parameter file 4.

【0018】次に、パラメータ設定部2はパラメータフ
ァイル4からB表の基本フォーマットを読み出して表示
出力させる。この行方向の見出し部にはその行項目のラ
ベルとして「書式」、「対象ファイル」、「集計項目」
が予め固定的に設定されており、また、B表の列方向に
おける見出し部の各列項目はその項目位置を示す名称と
して「A」、「B」、「C」……に対応付けられてい
る。
Next, the parameter setting section 2 reads out the basic format of Table B from the parameter file 4 and causes it to be displayed and output. In the heading of this line direction, "Format", "Target file", "Total item"
Are fixedly set in advance, and each column item of the heading portion in the column direction of the table B is associated with “A”, “B”, “C”,. I have.

【0019】いま、B表の基本フォーマットが表示出力
されている状態において、業務担当者は入力部1からB
表のパラメータデータを入力する。図3(B)はB表に
パラメータデータを入力した場合の表示例である。ここ
で、B表の列方向における見出し部には集計レコードの
データ項目として印刷出力される項目名が入力されてい
る。例えば、項目位置「B」には項目名「売上額」が入
力されている。また、B表の行項目において、「書式」
には項目データの印刷書式として列項目毎に欄幅、文字
種、文字サイズ等が入力されている。また、次の「対象
ファイル」には列項目位置「B」に対応して「回収ファ
イル」が入力されている。更に、次の「集計項目」は集
計対象として抽出されたレコードの中からどの項目デー
タを集計すべきかを定義するもので、列項目位置「B」
に対応して「売上額」が入力されている。このようにし
てB表を作成すると、パラメータ設定部2はそのパラメ
ータデータをパラメータファイル4に設定する。
In the state where the basic format of Table B is displayed and output, the business person in charge
Enter the parameter data for the table. FIG. 3B is a display example when parameter data is input to the table B. Here, an item name to be printed out as a data item of the total record is input in the heading portion in the column direction of the table B. For example, the item name “sales amount” is input in the item position “B”. In the line item of Table B, "Format"
The column width, character type, character size, and the like are input for each column item as the print format of the item data. In the next “target file”, “collected file” is input corresponding to the column item position “B”. Further, the next “total item” defines which item data is to be aggregated from the records extracted as the target of aggregation, and the column item position “B”
"Sales amount" is entered in correspondence with. When the table B is created in this way, the parameter setting unit 2 sets the parameter data in the parameter file 4.

【0020】いま、A表、B表を作成した後、入力部1
から任意の帳票名を指定してその印刷指令を与えると、
表構造解析部5はA表パラメータにしたがって構成ファ
イル7を作成する。ここで、図5〜図8は構成ファイル
7を作成する際の動作を示したフローチャート、また、
図9は構成ファイル7を作成する際の動作内容を示した
図、また図10は図3の(A)に示すA表に基づいて作
成された構成ファイル7の具体的な内容を示した図であ
る。なお、構成レコードは「子コード」、「親コー
ド」、「終了印」、「名称」から成り、「子コード」、
「親コード」は集計対象項目とそれに対応する集計レコ
ードとの対応関係を表わしたり、集計レベルの階層構造
における親子関係(上下関係)を表わすコードである。
また、「終了印」は親コードに最上位の集計レベルAが
含まれている場合に“1”となるフラグであり、終了印
に“1”がセットされている場合にはそれよりも上位レ
ベルへのレコード集計を行わないことを示している。ま
た、「名称」は集計レコードのレコード名であり、テー
ブルメモリ6内の索引テーブル等を参照することによっ
て自動的に生成された名称である。
Now, after creating the tables A and B, the input unit 1
If you specify any form name from and give the print command,
The table structure analysis unit 5 creates the configuration file 7 according to the table A parameters. Here, FIGS. 5 to 8 are flowcharts showing the operation when creating the configuration file 7, and FIGS.
FIG. 9 is a diagram showing an operation content when creating the configuration file 7, and FIG. 10 is a diagram showing a specific content of the configuration file 7 created based on the table A shown in FIG. It is. The configuration record is composed of "child code", "parent code", "end mark", and "name".
The “parent code” is a code that indicates the correspondence between the tallying target item and the corresponding tallying record, and the parent-child relationship (up / down relationship) in the hierarchical structure of the tallying level.
The "end mark" is a flag that is set to "1" when the parent code includes the highest aggregation level A, and is higher when the end mark is set to "1". Indicates that record aggregation to the level is not performed. The “name” is the record name of the tally record, and is a name automatically generated by referring to an index table or the like in the table memory 6.

【0021】先ず、表構造解析部5はパラメータファイ
ル4からA表のパラメータデータを読み出し、このA表
内に定義されているファイル名によって示されるデータ
ファイル10内のソースファイルを指定する(ステップ
A1)。次に、A表の先頭行を指定し(ステップA
2)、表構造解析部5内の後述する最終項目ワークメモ
リ(図9の(B)参照)の内容を全てクリアしておくと
共に(ステップA3)、現在着目中のレベル(現在レベ
ル)として指定行のレベルを指定しておく(ステップA
4)。そして、A表に定義されている第1指定項目のコ
ード条件に合致する項目コードを有するレコードを指定
ファイルから検索する(ステップA5)。いま、図3の
(A)に示すA表にはファイル名として「回収ファイ
ル」、第1指定項目(項目名「営業所コード」)のコー
ド条件として「10?」が定義されているので、上位2
桁の値が「10」となる営業所コードを有するレコード
を回収ファイルから検索する。この場合、回収ファイル
は図9の(D)に示す如く構成されているものとする。
即ち、回収ファイルにはその先頭から営業所コードが
「112」、「102」、「102」、「105」、
「105」「125」……を持ったレコードが順次格納
されているものとすると、先ず、第1指定項目のコード
条件「10?」に該当するレコードとして回収ファイル
から2番目のレコードつまり、営業所コード「102」
を持ったレコードが検索される。
First, the table structure analysis unit 5 reads the parameter data of the table A from the parameter file 4, and specifies a source file in the data file 10 indicated by the file name defined in the table A (step A1). ). Next, the first row of the table A is designated (step A
2) Clear all the contents of the later-described work memory (see FIG. 9B) in the table structure analysis unit 5 (step A3), and designate the work memory as the currently focused level (current level). Specify the row level (Step A
4). Then, a record having an item code that matches the code condition of the first designated item defined in Table A is searched from the designated file (step A5). Now, in Table A shown in FIG. 3A, “collected file” is defined as the file name, and “10?” Is defined as the code condition of the first designated item (item name “sales office code”). Top 2
A record having a business office code having a digit value of “10” is retrieved from the collection file. In this case, it is assumed that the collection file is configured as shown in FIG.
That is, the sales office code from the top of the collection file is “112”, “102”, “102”, “105”,
Assuming that records having "105", "125",... Are sequentially stored, first, a record corresponding to the code condition "10?" Place code "102"
The record with is searched.

【0022】すると、現在レベルと現在着目しているA
表の行Noと該当するレコード内の項目コードとからレベ
ル行データを生成する(ステップA6)。いま、A表の
先頭行に着目しているので現在レベルは「A」、行Noは
「01」、該当レコード内の項目コードは「102」、
したがってこれらを組み合せたレベル行データ「A01
102」が生成される。次に、該当する項目コードに対
応する名称をテーブルメモリ6内の索引テーブルより読
み出す(ステップA7)。即ち、A表に定義されている
ファイル名に対応するをテーブルメモリ6内のファイル
認識テーブルをアクセスし、このファイル認識テーブル
を参照して第1指定項目の項目名に対応するテーブル名
を呼び出し、このテーブル名に対応する索引テーブルを
アクセスして該当する項目コードに対応する名称をこの
索引テーブルから読み出す。この場合、営業所テーブル
から項目コード「102」に対応する名称「B営業所」
が読み出される。次に、生成したレベル行データと索引
テーブルから読み出した名称とを最終項目ワークメモリ
の現在レベルの位置にセットする(ステップA8)。こ
の結果、図9の(B)に示す様に、最終項目ワークメモ
リの現在レベルAの位置に対応してレベル行データ「A
01102」、名称「B営業所」がセットされる。な
お、最終項目ワークメモリは図9の(B)に示す様に集
計レベルA、B、C、D……に対応してレベル行データ
および名称を記憶する構成となっている。
Then, the current level and the current A
Level row data is generated from the row number of the table and the item code in the corresponding record (step A6). Now, because the focus is on the first row of table A, the current level is “A”, the row number is “01”, the item code in the corresponding record is “102”,
Therefore, the level row data "A01"
102 "is generated. Next, the name corresponding to the corresponding item code is read from the index table in the table memory 6 (step A7). That is, the file recognition table in the table memory 6 corresponding to the file name defined in the table A is accessed, and the table name corresponding to the item name of the first designated item is called by referring to the file recognition table, The index table corresponding to the table name is accessed, and the name corresponding to the corresponding item code is read from the index table. In this case, the name "B office" corresponding to the item code "102" from the office table
Is read. Next, the generated level row data and the name read from the index table are set at the current level position of the last item work memory (step A8). As a result, as shown in FIG. 9B, the level row data “A” corresponds to the current level A position of the last item work memory.
01102 "and the name" B office ". The final item work memory is configured to store level row data and names corresponding to the aggregation levels A, B, C, D... As shown in FIG. 9B.

【0023】次に、現在行の管理単位エリアに丸印が付
されているか否かをチェックする(ステップA9)。い
ま、A表の先頭行には丸印が付されていないので、A表
の次行に着目してその行にデータが設定されているか否
かをチェックする(ステップA10)。ここで、設定有
りが検出されると、現在行を更新して次行の指定を行う
(ステップA11)。これによってA表の2行目が指定
されてステップA12に進み、指定行のレベルが現在レ
ベル以上か否かのエラーチェックを行い、現在レベル以
上であれば、最終項目メモリ内で指定行のレベル以下の
内容を全てクリアしておく(ステップA13)。いま、
指定行レベルBは現在レベルA未満であるので、ステッ
プA14に進み、指定行レベルを現在レベルとして現在
レベルの更新を行う。
Next, it is checked whether or not the management unit area of the current line is marked with a circle (step A9). Since the first row of the A table is not marked with a circle, it is checked whether data is set in the next row of the A table (step A10). Here, when the setting is detected, the current line is updated and the next line is designated (step A11). As a result, the second row of the table A is specified and the process proceeds to step A12, where an error check is performed to determine whether or not the level of the specified row is equal to or higher than the current level. The following contents are all cleared (step A13). Now
Since the designated row level B is less than the current level A, the process proceeds to step A14, and the current level is updated using the designated row level as the current level.

【0024】次に、図6のステップA15に進み、検索
レコード(第1指定項目のコード条件に基づいてステッ
プA5で検索されたレコード)内にA表に定義されてい
る第2指定項目のコード条件に該当する項目コードが含
まれているかをチェックする。いま、第2指定項目(項
目名「得意先コード」)のコード条件は「3???」
で、検索レコードは図9の(D)に示す2番目のレコー
ド、つまり営業所コード「102」を有するレコードで
あり、この2番目の検索レコード内の得意先コード「3
001」はそのコード条件「3???」に合致する為、
ステップA16でそのことが検出されてステップA17
に進み、最終項目ワークメモリ内において、現在レベル
Bよりも1つ上位のレベル位置(集計レベルAの位置)
に格納されているレベル行データの中から行No「01」
と項目コード「102」とを読み出す。そして、現在レ
ベルBと最終項目ワークメモリから読み出した行No「0
1」および項目コード「102」と、第2指定項目のコ
ード条件に該当する項目コード「3001」とを順次組
み合せてレベル行データ「B011023001」を生
成する(ステップA18)。次に、第2指定項目のコー
ド条件に該当する項目コード「3001」に基づいてそ
れに対応する名称「○○商店」を索引テーブル(得意先
テーブル)から読み出し(ステップA19)、この名称
をステップA18で生成したレベル行データと共に最終
項目ワークメモリ内の現在レベルに対応するレベル位置
にセットする(ステップA20)。これによって最終項
目ワークメモリのレベルBの位置にはレベル行データ
「B011023001」と名称「○○商店」がセット
される(図9の(B)参照)。そして、次のステップA
21ではこのレベル行データを構成レコードの子コード
としてセットする(図9の(A)参照)。
Next, the process proceeds to step A15 in FIG. 6, and the code of the second designated item defined in the table A in the search record (the record retrieved in step A5 based on the code condition of the first designated item) Check whether the item code corresponding to the condition is included. Now, the code condition of the second designated item (item name “customer code”) is “3 ???”
The search record is the second record shown in FIG. 9D, that is, the record having the sales office code "102", and the customer code "3" in the second search record.
001 ”matches the code condition“ 3 ??? ”
This is detected in step A16 and step A17
To the last item in the work memory, the level position one level higher than the current level B (the position of the aggregation level A)
Row No. "01" from the level row data stored in
And the item code “102”. Then, the current level B and the row No. “0” read from the last item work memory
1 and the item code "102" and the item code "3001" corresponding to the code condition of the second designated item are sequentially combined to generate level row data "B011023001" (step A18). Next, based on the item code "3001" corresponding to the code condition of the second designated item, the corresponding name "XX store" is read from the index table (customer table) (step A19), and this name is stored in step A18. Is set to the level position corresponding to the current level in the last item work memory together with the level line data generated in step (A20). As a result, the level row data “B011023001” and the name “XX store” are set at the level B position of the last item work memory (see FIG. 9B). And the next step A
In step 21, this level line data is set as a child code of the constituent record (see FIG. 9A).

【0025】次に、図7のステップA31に進み、最終
項目ワークメモリの中から(現在レベル+1)のレベル
位置に格納されているレベル行データを読み出し、これ
を構成レコードの親コードとしてセットする。いま、現
在レベルはB、したがって最終項目ワークメモリのレベ
ルAの位置に格納されているレベル行データ「A011
02」が親コードとなる(図9の(A)参照)。ここ
で、親コードのレベルがAであれば(ステップA3
3)、構成レコードの終了印に“1”をセットする(ス
テップA34)。次に、親コードの名称を最終項目ワー
クメモリから読み出して構成レコードの名称としてセッ
トする(ステップA35)。このようにして1レコード
分のデータとして子コード「B011023001」、
親コード「A01102」、終了印「1」、名称「B営
業所」が揃うと、この構成レコ−ドは図10に示す様に
構成ファイル7の1レコード目のデータとして書き出さ
れる(ステップA36)。
Next, proceeding to step A31 in FIG. 7, the level row data stored at the (current level + 1) level position is read from the last item work memory, and this is set as the parent code of the configuration record. . Now, the current level is B, and therefore the level line data “A011” stored at the level A position of the last item work memory.
02 "is the parent code (see FIG. 9A). Here, if the level of the parent code is A (step A3)
3), "1" is set as the end mark of the configuration record (step A34). Next, the name of the parent code is read from the last item work memory and set as the name of the configuration record (step A35). In this manner, the child code “B011023001” as data for one record,
When the parent code "A01102", the end mark "1", and the name "B office" are prepared, this configuration record is written out as data of the first record of the configuration file 7 as shown in FIG. 10 (step A36). .

【0026】このようにして1レコード目の構成レコー
ドを生成すると、次に図5のステップA9に戻るが、こ
の場合、現在行つまり、行No「02」に対応する管理単
位エリアには丸印が付されているので、図8のステップ
A36に進み、最終項目ワークメモリ内の現在レベル位
置に格納されているレベル行データから第1指定項目の
コード条件に該当する項目コード「102」と第2指定
項目のコード条件に該当する項目コード「3001」と
をそれぞれ読み出し、この組み合せコードを次の構成レ
コードの子コードとしてセットする(図9の(C)参
照)。次に、最終項目ワークメモリ内の現在レベル位置
に格納されているレベル行データ「B01102300
1」を読み出し、これを構成レコードの親コードとして
セットし(ステップA37)、また、この親コードの名
称を最終項目ワークメモリから読み出して構成レコード
の名称としてセットする(ステップA38)。図9の
(C)はこれによって生成された構成レコードを示し、
この構成レコードは子コードが「1023001」、親
コードが「B011023001」、名称が「○○商
店」から成るもので、構成ファイル7の2レコード目の
データとして書き出される(ステップA39)。
When the first configuration record is generated in this way, the process returns to step A9 in FIG. 5. In this case, the current row, that is, the management unit area corresponding to the row No. "02" is indicated by a circle. , The process proceeds to step A36 in FIG. 8, and from the level line data stored at the current level position in the last item work memory, the item code “102” corresponding to the code condition of the first designated item and the The item code “3001” corresponding to the code condition of the two specified items is read out, and this combination code is set as a child code of the next configuration record (see FIG. 9C). Next, the level row data “B01102300” stored at the current level position in the last item work memory
"1" is read and set as the parent code of the configuration record (step A37), and the name of this parent code is read from the last item work memory and set as the name of the configuration record (step A38). FIG. 9C shows the configuration record generated by this,
This configuration record has a child code of “1023001”, a parent code of “B011023001”, and a name of “XX store”, and is written out as data of the second record of the configuration file 7 (step A39).

【0027】このようにして2レコード目を構成レコー
ドを生成すると、図6のステップA22に進み、最終項
目ワークメモリ内において、現在レベルの1つ上位のレ
ベル位置に格納されているレベル行データの中から項目
コード「102」を読み出し、この項目コードと同一コ
ードを持つ他のレコードがソースファイル内に有るかを
検索する(ステップA23)。いま、図9の(D)に示
す様に回収ファイルの3レコード目の営業所コードも
「102」であるので、ステップA24で同一コード有
りが検出されてステップA15に戻る。この場合、この
検索レコードの得意先コードは「3003」、したがっ
て第2指定項目のコード条件「3???」と一致する
為、以下、上述と同様にこの検索レコードに基づいて構
成レコードの生成を行う。即ち、最終項目ワークメモリ
内の1つ上位のレベル位置から読み出した行No「0
1」、項目コード「102」と、現在レベルBと、第2
指定項目の項目コード「3003」とからレベル行デー
タ「B011023003」を生成すると共に(ステッ
プA17、A18)、この項目コード「3003」に対
応する名称「××販売」を得意先テーブルから読み出し
(ステップA19)、このレベル行データと名称とを最
終項目ワークメモリの現在レベル位置にセットする(ス
テップA20)。この結果、図9の(B)に示す最終項
目ワークメモリのレベルB位置の内容が書き替えられ、
そのレベル行データは「B011023003」、名称
は「××販売」となる。そして、このレベル行データを
構成レコードの子コードとしてセットする(ステップA
21)。次に、最終項目ワークメモリのレベルAの位置
から読み出したレベル行データ「A01102」を構成
レコードの親コードとしてセットすると共に(ステップ
A31)、構成レコードの終了印に“1”をセットし
(ステップA33)、また親コードの名称「B営業所」
を構成レコードの名称としてセットする(ステップA3
4)。これによって生成された構成レコードは構成ファ
イル7の3レコード目に書き出される(図10参照)。
When the second record is formed as described above, the process proceeds to step A22 in FIG. 6, and in the last item work memory, the level row data stored in the level position one level higher than the current level is stored. The item code "102" is read from the file, and a search is made to determine whether another record having the same code as the item code exists in the source file (step A23). Now, as shown in FIG. 9D, the sales office code of the third record of the collection file is also "102", so the presence of the same code is detected in step A24, and the process returns to step A15. In this case, the customer code of this search record is "3003", and therefore matches the code condition "3 ???" of the second designated item, so that a configuration record is generated based on this search record as described above. I do. That is, the row No. “0” read from the next higher level position in the last item work memory
1 ", item code" 102 ", current level B, second
The level line data "B011023003" is generated from the item code "3003" of the designated item (steps A17 and A18), and the name "xx sales" corresponding to the item code "3003" is read from the customer table (step A17). A19), the level line data and the name are set at the current level position of the last item work memory (step A20). As a result, the contents of the level B position of the last item work memory shown in FIG.
The level row data is “B011023003” and the name is “xx sales”. Then, this level line data is set as a child code of the constituent record (step A).
21). Next, the level row data “A01102” read from the level A position of the last item work memory is set as the parent code of the configuration record (step A31), and “1” is set as the end mark of the configuration record (step A31). A33) and the name of the parent code "B office"
Is set as the name of the configuration record (step A3).
4). The configuration record generated in this way is written to the third record of the configuration file 7 (see FIG. 10).

【0028】続いて、ステップA9に戻るが、この場合
においても管理単位に丸印有りが検出されるので、図8
のステップA36〜A39が実行される結果、図10に
示す4レコード目の構成レコードが生成される。この場
合、子コードは「1023003」、親コードは「B0
11023003」、名称は「××販売」となる。
Subsequently, the process returns to step A9. In this case as well, since the presence of a circle is detected in the management unit, FIG.
As a result of the execution of steps A36 to A39, the fourth configuration record shown in FIG. 10 is generated. In this case, the child code is “1023003” and the parent code is “B0”.
11023003 ", and the name is" xx sale ".

【0029】そして、図6のステップA22に戻るが、
この場合、回収ファイルには図9の(D)に示す様に、
営業所コードが「102」となる他のレコードは存在し
ない為、ステップA25に進み、第1指定項目のコード
条件「10?」に該当する他の項目コードを回収ファイ
ルから検索する。この場合、図9の(D)に示す様に、
このコード条件に該当するレコードとして回収ファイル
の4レコード目には営業所コードが「105」となるレ
コードが存在する為、ステップA26で該当コード有り
が検出されてステップA27に進み、最終項目ワークメ
モリ内において現在レベルの1つ上位のレベル位置に格
納されているレベル行データの中からレベル名および行
Noを読み出し、このレベル名および行Noと、第1指定項
目のコード条件に該当する項目コードとからレベル行デ
ータを生成する(ステップA28)。この場合、レベル
行データとして「A01105」が生成される。次に第
1指定項目に該当する項目コード「105」に基づいて
対応する名称「E営業所」を索引テーブルから読み出し
(ステップA29)、これをレベル行データと共に最終
項目ワークメモリの1つ上位のレベル位置にセットする
(ステップA30)。この結果、図9の(B)に示す最
終項目ワークメモリのレベルA位置の内容が書き替えら
れ、そのレベル行データは「A01105」、名称は
「E営業所」となる。
Then, returning to step A22 in FIG.
In this case, as shown in FIG.
Since there is no other record whose sales office code is “102”, the process proceeds to step A25, and another item code corresponding to the code condition “10?” Of the first designated item is searched from the collection file. In this case, as shown in FIG.
As a record corresponding to this code condition, there is a record having the office code "105" in the fourth record of the collection file, so the presence of the corresponding code is detected in step A26, and the process proceeds to step A27. Name and line from the level line data stored in the level position one level higher than the current level
No. is read out, and level line data is generated from the level name and the line No. and the item code corresponding to the code condition of the first designated item (step A28). In this case, “A01105” is generated as the level row data. Next, based on the item code "105" corresponding to the first designated item, the corresponding name "E business office" is read out from the index table (step A29), and this is displayed together with the level row data and one level higher than the last item work memory. It is set at the level position (step A30). As a result, the contents of the level A position of the last item work memory shown in FIG. 9B are rewritten, and the level row data is “A01105” and the name is “E business office”.

【0030】次に、ステップA15に戻るが、この場
合、回収ファイルの4レコード目の得意先コードは「3
102」、したがって第2指定項目のコード条件「3?
??」に該当する為、このレコードに基づいて構成レコ
ードが生成される(ステップA17〜A21、A31〜
A35)。これによって生成された5レコード目の構成
レコードは図10に示す如く、子コードが「B0110
53102」、親コードが「A01105」、終了印が
「1」、名称が「E営業所」となる。以下、ステップA
10でA表の次行に設定無しが検出されるまで構成レコ
ードを生成する処理を1レコードずつ繰り返す。これに
よって図10に示す様な構成ファイル7が作成される。
Next, returning to step A15, in this case, the customer code of the fourth record of the collection file is "3
102 ", and therefore the code condition" 3?
? ? , A configuration record is generated based on this record (steps A17 to A21, A31 to A31).
A35). As shown in FIG. 10, the fifth record generated by this process has a child code “B0110”.
53102 ", the parent code is" A01105 ", the end mark is" 1 ", and the name is" E office ". Hereinafter, step A
In step 10, the process of generating the configuration record is repeated one record at a time until no setting is detected in the next row of the table A. As a result, a configuration file 7 as shown in FIG. 10 is created.

【0031】このようにして構成ファイル7を作成する
と、表構造解析部5はパラメータファイル4からB表パ
ラメータを読み出し、このパラメータデータから書式デ
ータを読み出して印刷書式モリ8にセットしておく。こ
の場合、表構造解析部5はB表のヘッダー位置に定義さ
れている各欄の項目名を読み出して印刷書式モリ8にセ
ットする。その後、表構造解析部5は展開ファイル作成
部9を起動させる。
When the configuration file 7 is created in this way, the table structure analysis unit 5 reads out the table B parameters from the parameter file 4, reads out the format data from the parameter data, and sets them in the print format memory 8. In this case, the table structure analysis unit 5 reads out the item names of each column defined in the header position of the table B and sets them in the print format memory 8. After that, the table structure analysis unit 5 activates the expanded file creation unit 9.

【0032】すると、展開ファイル作成部9は図11の
フローチャートにしたがって展開ファイル作成処理を行
う。なお、展開ファイル11は帳票の出力データである
集計ファイル13を作成するまでに中間的に生成される
ファイルである。ここで、図12はソースファイルが回
収ファイルの場合に、そのファイル内容にしたがって生
成された展開レコードを示している。先ず、展開ファイ
ル作成部9はパラメータファイル4内のA表に定義され
ているファイル名に対応するソースファイルを指定する
と共に(ステップB1)、この指定ファイルの先頭レコ
ードを指定する(ステップB2)。そして、この指定レ
コードからA表に定義されている第1指定項目に対応す
る項目コードを読み出し(ステップB3)、この項目コ
ードがそのコード条件に該当するかをチェックする(ス
テップB4)。いま、回収ファイルの先頭レコードが指
定されて第1指定項目「営業所コード」に対応する項目
コード「112」が読み出されるが、この項目コードは
そのコード条件「10?」に該当しない為、ステップB
7に進み、指定ファイル内に次のレコードが有るかを調
べ、有れば、ステップB8で次のレコードを指定したの
ち、ステップB3に戻る。
Then, the expanded file creating section 9 performs an expanded file creating process according to the flowchart of FIG. The development file 11 is an intermediate file that is generated before the tally file 13 that is the output data of the form is created. Here, FIG. 12 shows an expanded record generated according to the contents of the source file when the source file is a collected file. First, the development file creator 9 specifies a source file corresponding to the file name defined in the table A in the parameter file 4 (step B1), and specifies a first record of the specified file (step B2). Then, an item code corresponding to the first specified item defined in Table A is read from the specified record (step B3), and it is checked whether the item code satisfies the code condition (step B4). Now, the head record of the collection file is specified and the item code “112” corresponding to the first specified item “sales office code” is read. However, since this item code does not correspond to the code condition “10?” B
The process proceeds to step 7 to check whether or not the next record exists in the specified file. If so, the next record is specified in step B8, and the process returns to step B3.

【0033】これによって回収ファイルの2番目のレコ
ードが指定されてその営業所コード「102」が読み出
される。この営業所コードは、第1指定項目のコード条
件に該当する為、ステップB5に進み、指定レコードか
らA表の第2指定項目に対応する項目コードを読み出
し、そのコード条件に該当するかをチェックする(ステ
ップB6)。いま、第2指定項目は「得意先コード」で
あり、その項目コード「3001」はそのコード条件
「3???」に該当する為、ステップB9に進み、第1
指定項目および第2指定項目に対応する該当コード「1
02」、「3001」を結合し、これを展開レコードの
分類キーとしてセットする。次に、指定レコードからB
表の集計項目に対応する項目データを読み出し(ステッ
プB10)、展開レコードの対応位置にセットする(ス
テップB11)。ここで、B表の集計項目としてその列
項目位置Bには「売上額」が定義されているので、回収
ファイルの2番目のレコードからこの売上額「200,
000」が読み出されて展開レコードの対応位置Bにセ
ットされる。これによって生成された展開レコードは展
開ファイル11の1レコード目に書き出される(ステッ
プB12)。
As a result, the second record of the collection file is specified, and the office code “102” is read. Since this office code satisfies the code condition of the first designated item, the process proceeds to step B5, where the item code corresponding to the second designated item of Table A is read from the designated record, and it is checked whether the code condition is met. (Step B6). Now, the second designated item is “customer code”, and the item code “3001” corresponds to the code condition “3 ???”.
The corresponding code "1" corresponding to the specified item and the second specified item
02 "and" 3001 "are combined and set as the classification key of the expanded record. Next, from the specified record
The item data corresponding to the tabulated item in the table is read (step B10), and is set at the corresponding position of the expanded record (step B11). Here, since “sales amount” is defined in the column item position B as a total item of the table B, the sales amount “200,
000 "is read out and set to the corresponding position B of the expanded record. The developed record thus generated is written to the first record of the developed file 11 (step B12).

【0034】次に、ステップB7に戻り、以下、指定フ
ァイルの3レコード目が指定される。このレコードもA
表に定義されている第1および第2指定項目のコード条
件にそれぞれ該当する為、そのレコードに基づいて展開
レコードが生成される。この場合の展開レコードは図1
2に示す2レコード目の内容となる。更に回収ファイル
の4レコード目においてもそれに基づいて展開レコード
が生成され、図12に示す3レコード目の内容となる。
以下、指定ファイルの全レコードについて上述の動作を
繰り返し、展開レコードを1レコードずつ生成する処理
を行う。これによって展開ファイル11を作成すると、
展開ファイル作成部9は展開集計処理部12を起動させ
る。
Next, returning to step B7, the third record of the designated file is designated. This record is also A
Since each of the code conditions of the first and second designated items defined in the table is satisfied, an expanded record is generated based on the record. The expanded record in this case is shown in FIG.
The contents of the second record shown in FIG. Further, a development record is generated based on the fourth record of the collection file, and the contents of the third record shown in FIG. 12 are obtained.
Hereinafter, the above-described operation is repeated for all records of the specified file, and processing for generating an expanded record one record at a time is performed. Thus, when the expanded file 11 is created,
The development file creation unit 9 activates the development totalization processing unit 12.

【0035】図13は展開集計処理部12の動作を示し
たフローチャート、また、図14は展開集計処理部12
の動作内容を具体的に説明する為の図である。展開ファ
イル作成部9は展開ファイル11の内容と構成ファイル
7の内容とに基づいて集計ファイル13を部品展開手法
にしたがって生成する。先ず、展開集計処理部12は展
開ファイル11の先頭から1レコード分のデータを読み
込む(ステップC1)。そして、次のステップC2では
データ終了か、つまり、展開ファイル11の先頭から全
てのレコードを読み出したか否かをチェックする。最初
は展開ファイル11の先頭から1レコード分のデータを
読み込んだ場合であるから、次のステップC3に進み、
構成ファイル7の内容をサーチし、その分類キーと一致
する子コードを構成ファイル7から検索する。いま、図
12に示す様に展開ファイル11の先頭レコード内の分
類キーは「1023001」であり、構成ファイル7に
は図10に示す様にこれと一致する子コードを持った構
成レコードがその2レコード目に存在する為、ステップ
C3でそのことが検出されてステップC4に進み、集計
ファイル13のレコード(集計レコード)を生成する。
即ち、図14の具体例において、先ず、展開集計処理部
12はこの子コード「1023001」に対応する親コ
ードを構成ファイル7から読み出し、この親コード「B
011023001」を集計レベルとそれ以外の数値と
に分解し、この数値「011023001」を集計ファ
イル13の1レコード目の先頭項目に配置し、また集計
レベルの「B」をそれに続けて配置する。そしてこの子
コードに対応する名称「○○商店」を構成ファイル7か
ら読み出し、集計レコードの次の項目に配置する。これ
に続けて展開ファイル11のデータ項目「200,00
0」を集計レコードの次項目以降に順次配置する。
FIG. 13 is a flowchart showing the operation of the development and aggregation processing unit 12, and FIG.
FIG. 4 is a diagram for specifically explaining the operation content of FIG. The development file creation unit 9 generates the total file 13 based on the contents of the development file 11 and the contents of the configuration file 7 in accordance with the component development method. First, the development tabulation unit 12 reads data of one record from the top of the development file 11 (step C1). Then, in the next step C2, it is checked whether or not the data has ended, that is, whether or not all the records have been read from the beginning of the development file 11. Since the first case is a case where data for one record is read from the beginning of the development file 11, the process proceeds to the next step C3,
The contents of the configuration file 7 are searched, and a child code that matches the classification key is searched from the configuration file 7. Now, as shown in FIG. 12, the classification key in the first record of the development file 11 is “1023001”, and the configuration file 7 has a configuration record having a child code that matches this as shown in FIG. Since it exists in the record, the fact is detected in step C3 and the process proceeds to step C4, where a record (total record) of the total file 13 is generated.
That is, in the specific example of FIG. 14, first, the development and aggregation processing unit 12 reads the parent code corresponding to the child code “1023001” from the configuration file 7 and reads the parent code “B
“011023001” is decomposed into a totaling level and other numerical values, and this numerical value “011023001” is arranged as the first item of the first record of the totalizing file 13, and “B” of the totaling level is arranged subsequently thereto. Then, the name “XX store” corresponding to the child code is read from the configuration file 7 and is arranged in the next item of the tally record. Following this, the data item "200,00"
"0" is sequentially arranged after the next item of the tally record.

【0036】これによって集計ファイル13の1レコー
ド目のデータが生成されると、この生成レコードを集計
ファイル13に書き出すが、その際、集計ファイル13
内に既に同一分類キーを持つレコードが存在していれ
ば、それを1レコードにまとめて集計ファイル13内に
書き込み、また同一分類キーのレコードが存在していな
ければ、今回生成したレコードを新たに集計ファイル1
3に追加する(ステップC5)。
When the first record data of the totalization file 13 is generated, the generated record is written to the totalization file 13.
If a record having the same classification key already exists in the file, the record is collected into one record and written in the aggregation file 13, and if no record with the same classification key exists, the newly generated record is newly added. Total file 1
3 (step C5).

【0037】次に、構成ファイル7内の該当レコード位
置に終了印がセットされているか否かをチェックする
(ステップC6)。ここで、構成ファイル7内の終了印
は親コードの集計レベルが「A」のときに“1”となる
もので、終了印が“1”のときにはそのままステップC
3に戻るが、終了印が“1”でなければ新たな展開レコ
ードを生成して展開ファイル11への書き出しを行う
(ステップC7)。この場合、構成ファイル7の該当レ
コード位置には終了印がセットされていないので、図1
4に示す様な新たな展開レコードを生成して展開ファイ
ル11へ戻す。即ち、今回生成した集計レコードよりも
上位レベルにあるレコードがA表に定義されていれば、
今回生成した集計レコードの集計結果を上位レベルにあ
るレコードへ集計させる為に、新たな展開レコードを生
成してプリンタ15への書き出しを行う。ここで、構成
ファイル7内の該当する親コード「B01102300
1」を先頭項目に配置し、これに続けて展開ファイル1
1から読み出した項目データを対応位置に順次配置して
成るレコードを展開ファイル11へ書き出す。
Next, it is checked whether or not the end mark is set at the corresponding record position in the configuration file 7 (step C6). Here, the end mark in the configuration file 7 is "1" when the aggregation level of the parent code is "A".
Returning to step 3, if the end mark is not "1", a new expansion record is generated and written to the expansion file 11 (step C7). In this case, since the end mark is not set in the corresponding record position of the configuration file 7, FIG.
A new expansion record as shown in FIG. 4 is generated and returned to the expansion file 11. In other words, if a record at a higher level than the total record generated this time is defined in Table A,
In order to add up the totaling result of the totaling record generated this time to a record at a higher level, a new expanded record is generated and written to the printer 15. Here, the corresponding parent code “B01102300” in the configuration file 7
"1" is placed in the first item, followed by the expanded file 1
A record formed by sequentially arranging the item data read from No. 1 at corresponding positions is written to the development file 11.

【0038】その後、ステップC3に戻り、以下、構成
ファイル7の内容を全てサーチし、該当レコードが検出
されなくなるまで上述の動作を繰り返す。この結果、ス
テップC3で該当レコード無しが検出されて不一致終了
となると、ステップC1に戻り、展開ファイル11から
次のレコードを読み出す。このような動作は展開ファイ
ル11の全レコードに対して行われる。すると、ステッ
プC1でデータ終了が検出されてステップC8に進み、
集計ファイル13を構成する各レコードをその先頭項目
のキー内容にしたがってソートする。この場合、展開集
計処理部12はパラメータファイル4内のA表に定義さ
れている出力順序にしたがって集計ファイル13の内容
をソートする。図15はこの場合の集計ファイル13の
内容を示し、(A)はソート前、(B)はソート後を示
している。ここで、A表に定義されている「出力順序」
は「営業所」、「得意先」共、コード順である為、集計
ファイル13内の対応するレコードはそのキー内容にし
たがって昇順(コード順)にソートされ、図15の
(B)に示す様な並びとなる。その後、展開集計処理部
12は印刷処理部14を起動させる。すると、印刷処理
部14は印刷書式メモリ8の内容を取り込んでその印刷
書式にしたがって集計ファイル13の内容を帳票フォー
マットと共にプリンタ15から印刷出力させることによ
り帳票作成を行う。この場合、印刷処理部14は集計フ
ァイル13の先頭から1レコードずつ集計レコードを読
み出し、この集計レコード内に含まれている集計レベル
を判別し、それに対応する括り用の罫線フォーマットと
共に、集計レコード内の名称およびデータを1レコード
ずつ印字出力させると共に、印刷書式メモリ8に記憶さ
れている各項目名を順次取り出して罫線フォーマットの
対応位置に印刷出力させる。図2はこの場合の帳票印刷
例で、その行方向には集計レベルに応じた階層構造のフ
ォーマットと共に、集計レコードの名称が印刷されると
共に、列方向には集計レコードの項目名が印刷され、更
に、集計ファイル13の内容が1レコード毎に印刷出力
される。
Thereafter, the flow returns to step C3, and thereafter, the entire contents of the configuration file 7 are searched, and the above operation is repeated until the corresponding record is not detected. As a result, when the absence of the record is detected in step C3 and the mismatch ends, the process returns to step C1 and reads the next record from the development file 11. Such an operation is performed for all records in the development file 11. Then, the end of data is detected in step C1, and the process proceeds to step C8.
The records constituting the tally file 13 are sorted according to the key content of the first item. In this case, the development tabulation unit 12 sorts the contents of the tabulation file 13 in accordance with the output order defined in the table A in the parameter file 4. FIG. 15 shows the contents of the tally file 13 in this case, in which (A) shows before sorting and (B) shows after sorting. Here, "output order" defined in Table A
Since “sales office” and “customer” are in code order, the corresponding records in the totalization file 13 are sorted in ascending order (code order) according to the key contents, as shown in FIG. It becomes a line. After that, the development tabulation unit 12 activates the print processing unit 14. Then, the print processing unit 14 fetches the contents of the print format memory 8 and prints out the contents of the aggregation file 13 together with the form format from the printer 15 in accordance with the print format, thereby creating a form. In this case, the print processing unit 14 reads the total records one record at a time from the top of the total file 13, determines the total level included in the total records, and, together with the corresponding ruled line format for grouping, displays the total records in the total records. Is printed out one record at a time, and each item name stored in the print format memory 8 is sequentially taken out and printed out at a corresponding position in the ruled line format. FIG. 2 shows a form printing example in this case. In the row direction, the name of the totaling record is printed along with the format of the hierarchical structure corresponding to the totaling level, and the item name of the totaling record is printed in the column direction. Further, the contents of the aggregation file 13 are printed out for each record.

【0039】以上の様に、本実施例においては、集計レ
コードを抽出する際の対象項目をコード条件で定義する
ことによって多数の項目コードを一括指定したとして
も、そのコード条件に該当する全てのレコードの名称を
索引テーブルから読み出して自動生成し、予め定義して
おいたレコード名の配置位置に出力するので、集計レコ
ードの名称を1レコードずつ記述しておく必要はなく、
その記述を大幅に簡略化することが可能となり、全体が
見易くなって記述ミスも削減することが可能となる。ま
た、多数の項目コードを集計対象として指定する場合、
その項目コードの内容を出力順序の並び順にしたがって
1つずつ直接記述しておく必要はなく、コード条件の記
述によって一括指定したとしても、このコード条件に該
当する全てのレコードが予め定義されている出力順序に
したがった並び順で出力されるので、集計定義表の記述
を更に簡略化することができる。また、複数のコード条
件を集計レベルに応じた階層構造で定義した場合には、
複数のコード条件に該当する全てのレコードを集計レベ
ルに応じて分類集計すると共に、この集計結果を階層構
造で出力するので、予めシステムエンジニア等の専門家
によって分類集計用のコード体系(コード変換テーブ
ル)を作成しておく必要はなく、簡単な集計定義表を記
述しておくだけで、誰でも容易に所望する帳票を得るこ
とが可能となる。
As described above, in this embodiment, even if a large number of item codes are collectively designated by defining the target items for extracting the total record by the code condition, all the items corresponding to the code condition are specified. The name of the record is read from the index table, automatically generated, and output to the position where the record name is defined in advance. Therefore, it is not necessary to describe the name of the totaled record one by one.
The description can be greatly simplified, the whole can be easily viewed, and description errors can be reduced. Also, when specifying a large number of item codes as aggregation targets,
It is not necessary to directly describe the contents of the item codes one by one in accordance with the arrangement order of the output order. Even if the codes are collectively specified by describing the code conditions, all records corresponding to the code conditions are defined in advance. Since the output is performed in the arrangement order according to the output order, the description of the aggregation definition table can be further simplified. Also, when multiple code conditions are defined in a hierarchical structure according to the aggregation level,
All records corresponding to a plurality of code conditions are classified and tabulated according to the tabulation level, and the tabulation results are output in a hierarchical structure. ) Does not need to be created, and anyone can easily obtain a desired form simply by writing a simple summary definition table.

【0040】[0040]

【第2実施例】以下、図16〜図19を参照して第2実
施例を説明する。図16は本実施例のA表を示し、A表
の行No「01」、「02」に対応する定義内容は上記第
1実施例と同様であるが、行No「03」には集計レコー
ドの任意のレコード名を集計レベルに対応させて直接記
述すると共に、集計レコードを抽出する際の対象項目の
コード内容をそのまま第1指定項目、第2指定項目に対
応させて定義したものである。即ち、本実施例において
は、上記第1実施例の第1および第2の指定項目に対応
するコード条件に該当しない項目も集計対象とすること
ができるようにしたもので、図示の例では第1指定項目
のコード条件「10?」には該当するが第2指定項目の
コード条件「3???」には該当しない項目、つまり、
第1指定項目のコード内容が「105」で第2指定項目
のコード内容が「2001」の項目を集計対象とする定
義内容を示している。なお、この行No「03」には集計
レベルBに対応させてレコード名「ZZ販売」が直接記
述されているが、この名称は上記第1実施例の様な総括
的な代用名称ではない実際のレコード名である為、括弧
書きで記述する必要はない。このように、複数の集計対
象項目を一括して指定する記述と、集計対象を個々に指
定する記述が混在していても、本実施例においてはこの
定義内容にしたがってレコード集計を行うと共に、定義
内容通りのイメージで帳票出力を行うようにしたもので
ある。
Second Embodiment Hereinafter, a second embodiment will be described with reference to FIGS. FIG. 16 shows the table A of the present embodiment. The definition contents corresponding to the row Nos. “01” and “02” of the table A are the same as those of the first embodiment, but the row No. Is directly described in association with the aggregation level, and the code content of the target item when extracting the aggregation record is defined as it is in association with the first specified item and the second specified item. That is, in the present embodiment, items that do not correspond to the code conditions corresponding to the first and second designated items of the first embodiment can also be counted. An item that satisfies the code condition “10?” Of the first specified item but does not correspond to the code condition “3 ???” of the second specified item, ie,
The code content of the first designated item is “105”, and the code content of the second designated item is “2001”. The record name “ZZ sales” is directly described in the row No. “03” in correspondence with the aggregation level B, but this name is not a general substitute name as in the first embodiment. Since it is a record name, there is no need to write it in parentheses. As described above, even when the description for collectively specifying a plurality of calculation target items and the description for individually specifying the calculation targets are mixed, in the present embodiment, the record calculation is performed according to the definition contents and the definition is performed. The form is output with the image as the contents.

【0041】図17は図16に示すA表を基に作成され
た構成ファイル7の内容を示している。ここで、構成フ
ァイル7の7レコード目と8レコード目が本実施例にお
いて新たに生成された構成レコードで、その他は上記第
1実施例と同様である。この新たに生成された構成レコ
ードは、その子コード、親コードのコード形態に特徴が
あり、デルタ記号という特殊な記号が用いられている。
即ち、7レコード目の子コードと8レコード目の親コー
ドは本来「B011052001」となるが、「B01
105Δ03」で表現され、また、8レコード目の子コ
ードは本来「1052001」となるが、これも「10
5Δ03」で表現されている。ここで、デルタ記号に続
く「03」は行Noを示している。このように第2指定項
目のコード内容「2001」に代えてそれをデルタ記号
で表現したのは、帳票出力時にこの例外的な「ZZ販
売」のレコードを最下行に配置させる為である。即ち、
上述した様に、この構成ファイル7の内容にしたがって
作成された集計ファイル13は、構成レコードの親コー
ド(集計レベルを除く)をキーとし、このキー内容を参
照してA表に定義されている出力順序でソートされ、帳
票出力時の印刷順に並べ替えられる為、例外的なレコー
ドのキーに第2指定項目のコード内容がそのまま含まれ
ていると、このレコードが最下行に配置されなくなる。
これを防ぐ為に、本実施例においては、第2指定項目の
コード内容に代わってデルタ記号を用いている。ここ
で、集計ファイル13の内容をコード順(昇順)にソー
トする場合、0〜9、A〜Z、a〜z、Δの順でソート
するようにしている。
FIG. 17 shows the contents of the configuration file 7 created based on the table A shown in FIG. Here, the seventh record and the eighth record of the configuration file 7 are newly generated configuration records in the present embodiment, and the others are the same as those in the first embodiment. The newly generated configuration record is characterized by the code form of its child code and parent code, and uses a special symbol called a delta symbol.
In other words, the child code of the seventh record and the parent code of the eighth record are originally “B011052001”, but “B011052001”.
105Δ03 ”, and the child code of the eighth record is originally“ 1052001 ”.
5Δ03 ”. Here, “03” following the delta symbol indicates a row number. The reason why the code content of the second designated item is represented by the delta symbol instead of "2001" is to arrange the exceptional "ZZ sales" record at the bottom line when outputting the form. That is,
As described above, the tabulation file 13 created according to the contents of the configuration file 7 is defined in the table A with the parent code (excluding the tabulation level) of the configuration record as a key and referring to the key contents. Since the sort is performed in the output order and the print order when the form is output, if the code content of the second specified item is included as it is in the key of the exceptional record, this record is not arranged at the bottom line.
To prevent this, in this embodiment, a delta symbol is used instead of the code content of the second designated item. Here, when the contents of the tally file 13 are sorted in code order (ascending order), the contents are sorted in the order of 0-9, AZ, az, and Δ.

【0042】図18は集計ファイル13のソート前、ソ
ート後における内容を示し、例外的なレコードが集計フ
ァイル13の途中に含まれていてもそれをコード順にソ
ートすることによってそのレコードは最終のレコード位
置に並べ替えられる。このソート後の集計ファイル13
の内容を印刷出力すると、図19に示す様な帳票が得ら
れ、「ZZ販売」の集計結果は帳票の最下行に配置さ
れ、定義内容通りのイメージで帳票出力される。なお、
構成レコード内にデルタ記号に続けて行Noを付加したの
は、例外的なレコードが複数定義されている場合にその
定義内容通りの並び順で帳票出力させる為である。
FIG. 18 shows the contents of the tallying file 13 before and after sorting. Even if an exceptional record is included in the middle of the tallying file 13, the record is sorted in the order of the code so that the record becomes the last record. Sorted by position. Total file 13 after this sort
Is printed out, a form as shown in FIG. 19 is obtained, and the tabulation result of “ZZ sales” is arranged at the bottom line of the form, and the form is output with an image as defined. In addition,
The reason why the line number is added after the delta symbol in the configuration record is that, when a plurality of exceptional records are defined, the form is output in the order of the definition.

【0043】このように構成された本実施例においても
上記第1実施例と同様の効果を有する他、複数の集計対
象項目を一括指定する記述に含まれない例外的な項目も
個別にレコード集計されて帳票出力することが可能とな
る。
The present embodiment having the above-described structure has the same effect as the first embodiment. In addition, exceptional items which are not included in the description for collectively specifying a plurality of items to be totaled are also individually tabulated. Then, the form can be output.

【0044】[0044]

【第3実施例】以下、図20、図21を参照して第3実
施例を説明する。図20は本実施例のA表を示し、上記
第1実施例と相違する点は集計レベルに対応して記述さ
れる総括的な代用名称に「,」を付加して括弧書きにし
たものである。このように「,」を代用名称に付加して
おくと、帳票出力時に、対応する項目コードがレコード
名に添えて印刷出力される(図21参照)。この場合、
集計ファイル13の内容をその先頭から1レコードずつ
読み出す際に、そのキーに含まれている項目コードを名
称と共に読み出して印字出力すればよい。このように構
成された本実施例においても上記第1実施例と同様の効
果を有する他、項目コードを正確に覚えてない場合に
は、それを再認識することが可能となる。
Third Embodiment Hereinafter, a third embodiment will be described with reference to FIGS. FIG. 20 shows Table A of this embodiment. The difference from the first embodiment is that parentheses are added by adding "," to the general substitute name described corresponding to the aggregation level. is there. If "," is added to the substitute name in this way, the corresponding item code is printed out along with the record name when the form is output (see FIG. 21). in this case,
When reading the contents of the tallying file 13 one record at a time from the beginning, the item code included in the key may be read out together with the name and printed out. The present embodiment thus configured has the same effects as the first embodiment, and if the item code is not memorized correctly, it can be recognized again.

【0045】なお、上記各実施例においては集計対象項
目のコード条件として「10?」、「3???」という
様に、項目コードの一部に?マークを付けて複数の項目
を一括指定するようにしたが、例えば、123<?<1
34というようなコード条件で指定してもよい。また、
上記実施例は第1指定項目、第2指定項目にコード条件
を定義するようにしたが、第3指定項目を設け、この第
3指定項目にもコード条件を定義するようにしてもよ
い。更に、上記実施例はA表およびB表をそれぞれ別個
に定義するようにしたが、A表、B表をまとめて定義す
るようにしてもよい。また、上記第3実施例においては
総括的な代用名称に「,」を付加することにより項目コ
ードと名称とを対応付けて印字出力させることを定義し
たが、特別な記号を付加しなくてもレコード名の配置位
置を単に指定しておくだけで名称と項目コードとを対応
付けて印字出力するようにしてもよい。
In each of the above embodiments, the code condition of the item to be summed is "10?" Or "3 ???". A plurality of items are designated collectively by attaching a mark. For example, 123 <? <1
34 may be specified. Also,
In the above embodiment, the code condition is defined for the first and second specified items. However, a third specified item may be provided, and the code condition may be defined for the third specified item. Further, in the above embodiment, the A table and the B table are defined separately, but the A table and the B table may be defined collectively. Further, in the third embodiment, it is defined that the item code and the name are associated with each other to be printed out by adding “,” to the general substitute name, but it is not necessary to add a special symbol. By simply specifying the arrangement position of the record name, the name and the item code may be correlated and printed out.

【0046】[0046]

【発明の効果】本発明によれば、レコードを複数階層に
て帳票出力する際の第1階層のレコード名の第1項目と
その第1項目における抽出コード条件、第2階層のレコ
ード名の第2項目とその第2項目における抽出コード条
件、の対応付けを定義する第1定義表と、レコードに含
まれる各項目の中で帳票出力に必要な出力対象項目を定
義する第2定義表に予め定義を行っておくことにより、
複数レコードの内で、その各定義表における定義内容に
基いた階層別のレコードの抽出、階層別のレコード名の
決定、及びレコード内項目の内で出力対象項目の絞込み
を行った帳票を直ちに作成することができる。
According to the present invention, the first item of the record name of the first hierarchy, the extraction code condition in the first item, and the second item of the record name of the second hierarchy when the record is output in the form of a plurality of hierarchies. A first definition table that defines correspondence between two items and an extraction code condition in the second item, and a second definition table that defines an output target item necessary for form output among the items included in the record in advance By defining it,
Within multiple records, extract records by hierarchy based on the definition contents in each definition table, determine record names by hierarchy, and immediately create a form that narrows down the output target items among the items in the record can do.

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

【図1】実施例に係るデータ処理装置のブロック構成
図。
FIG. 1 is a block diagram of a data processing apparatus according to an embodiment.

【図2】帳票の印刷出力例を示した図。FIG. 2 is a diagram illustrating an example of a print output of a form.

【図3】集計定義表を示し、(A)はA表、(B)はB
表の内容を示した図。
FIG. 3 shows a summary definition table, where (A) is Table A and (B) is B
The figure which showed the content of the table.

【図4】テーブルメモリ6の一部を示し、(A)はファ
イル認識テーブル、(B)は営業所テーブル、(C)は
得意先テーブルを示した図。
4A and 4B show a part of a table memory 6, wherein FIG. 4A shows a file recognition table, FIG. 4B shows a business office table, and FIG. 4C shows a customer table.

【図5】構成ファイル作成処理の一部を詳細に示したフ
ローチャート。
FIG. 5 is a flowchart showing a part of a configuration file creation process in detail.

【図6】図5に続く構成ファイル作成処理の一部を示し
たフローチャート。
FIG. 6 is a flowchart showing a part of a configuration file creation process following FIG. 5;

【図7】図5に続く構成ファイル作成処理の一部を示し
たフローチャート。
FIG. 7 is a flowchart showing a part of a configuration file creation process following FIG. 5;

【図8】図5に続く構成ファイル作成処理の一部を示し
たフローチャート。
FIG. 8 is a flowchart showing a part of a configuration file creation process following FIG. 5;

【図9】構成レコードの作成状態を具体的に示した図
で、(A)、(C)は構成レコード、(B)は最終項目
ワークメモリの内容、(D)は回収ファイルの一部を示
した図。
9A and 9C are diagrams specifically showing a state of creating a configuration record, wherein FIG. 9A and FIG. 9C are configuration records, FIG. 9B is the contents of the last item work memory, and FIG. FIG.

【図10】構成ファイルの具体的な内容を示した図。FIG. 10 is a diagram showing specific contents of a configuration file.

【図11】展開ファイル作成処理を示した図。FIG. 11 is a diagram showing a development file creation process.

【図12】展開レコード作成状態を示した図。FIG. 12 is a diagram showing a development record creation state.

【図13】展開集計処理を示したフローチャート。FIG. 13 is a flowchart illustrating a development tabulation process.

【図14】展開集計処理の動作内容を具体的に示した図
で、(A)は展開ファイル、構成ファイルから集計レコ
ードが生成される様子を示した図、(B)は新たに生成
される展開レコードを示した図。
14A and 14B are diagrams specifically showing the operation contents of the development and aggregation processing, in which FIG. 14A shows a state in which a summary record is generated from a development file and a configuration file, and FIG. The figure which showed the expansion record.

【図15】集計ファイルのソート前、ソート後における
集計ファイルの内容を示した図。
FIG. 15 is a diagram showing the contents of a tally file before and after the tally file is sorted.

【図16】第2実施例に係るA表の記述例を示した図。FIG. 16 is a diagram showing a description example of a table A according to the second embodiment.

【図17】第2実施例に係る構成ファイルの内容を示し
た図。
FIG. 17 is a diagram showing the contents of a configuration file according to the second embodiment.

【図18】第2実施例に係る集計ファイルのソート前、
ソート後の内容を示した図。
FIG. 18 shows a state before sorting of a total file according to the second embodiment;
The figure which showed the content after sorting.

【図19】第2実施例に係る帳票印刷例を示した図。FIG. 19 is a diagram illustrating a form printing example according to the second embodiment.

【図20】第3実施例に係るA表の記述例を示した図。FIG. 20 is a diagram showing a description example of a table A according to the third embodiment.

【図21】第3実施例に係る帳票出力例を示した図。FIG. 21 is a diagram showing a form output example according to the third embodiment.

【符号の説明】[Explanation of symbols]

1 入力部 2 パラメータ設定部 3 表示部 4 パラメータファイル 5 表構造解析部 6 テーブルメモリ 7 構成ファイル 8 印刷書式メモリ 9 展開ファイル作成部 10 データファイル 11 展開ファイル 12 展開集計処理部 13 集計ファイル 14 印刷処理部 15 プリンタ DESCRIPTION OF SYMBOLS 1 Input part 2 Parameter setting part 3 Display part 4 Parameter file 5 Table structure analysis part 6 Table memory 7 Configuration file 8 Printing format memory 9 Development file creation part 10 Data file 11 Development file 12 Development total processing part 13 Total file 14 Printing processing Part 15 Printer

───────────────────────────────────────────────────── フロントページの続き (58)調査した分野(Int.Cl.7,DB名) G06F 19/00 G06F 17/21 - 17/27 ──────────────────────────────────────────────────続 き Continued on the front page (58) Fields surveyed (Int. Cl. 7 , DB name) G06F 19/00 G06F 17/21-17/27

Claims (1)

(57)【特許請求の範囲】(57) [Claims] 【請求項1】 複数の項目からなるレコードを複数記憶
するレコード記憶手段と、 レコードを複数階層にて帳票
出力する際の第1階層のレコード名の第1項目とその第
1項目における抽出コード条件、第2階層のレコード名
の第2項目とその第2項目における抽出コード条件、の
対応付けを定義する第1定義表を記憶する第1定義記憶
手段と、 上記レコードに含まれる各項目の中で上記帳票
出力に必要な出力対象項目を定義する第2定義表を記憶
する第2定義記憶手段と、 上記第1項目の抽出コード条
件に合致する項目コードを有する第1階層レコード、上
記第1項目の抽出コード条件に合致する項目コードと上
記第2項目の抽出コード条件に合致する項目コードとを
共に有する第2階層レコード、を抽出する抽出手段と、
上記抽出手段で抽出された各レコードに基いて帳票作成
を行う際は、抽出された上記第1階層レコードにおける
上記第1項目の項目コードに対応する名称をその帳票に
おけるレコード名とし、抽出された上記第2階層レコー
ドにおける上記第2項目の項目コードに対応する名称を
その帳票におけるレコード名とし、且つ抽出された第
1、第2階層の各レコードについて、その個々のレコー
ド毎に上記第2定義表にて定義された各出力対象項目の
内容を読み出して上記レコード名に対応付けて配置した
帳票を作成する帳票作成手段と、 上記作成された帳票を
出力する出力手段と、を具備したことを特徴とする帳票
出力装置。
1. A plurality of records including a plurality of items are stored.
Record storage means and records in multiple layers
The first item of the first layer record name and the first
Extraction code condition for one item, record name of second layer
Of the second item and the extraction code condition in the second item
First definition storage for storing a first definition table for defining association
Means and the form in each item included in the record
Stores the second definition table that defines the output items required for output
A second definition storage means for performing the above, and an extraction code section of the first item.
First-level record with item code that matches the condition, above
Item code that matches the extraction code condition of the first item
Item code that meets the extraction code condition of the second item
Extracting means for extracting a second hierarchical record having the same,
Form creation based on each record extracted by the above extraction means
When performing the above, in the extracted first-level record
Enter the name corresponding to the item code of the first item in the form
And the extracted second-level record
Name corresponding to the item code of the second item in
The name of the record in the form and the extracted
1. For each record in the second layer, its individual record
Of each output target item defined in the second definition table
Read the contents and place them in association with the above record name
A form output device, comprising: a form creation unit for creating a form; and an output unit for outputting the created form.
JP05173635A 1993-06-22 1993-06-22 Form output device Expired - Fee Related JP3109331B2 (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
JP05173635A JP3109331B2 (en) 1993-06-22 1993-06-22 Form output device
US08/261,723 US5642521A (en) 1993-06-22 1994-06-17 Data processing apparatus for extracting and processing arbitrary records from a file

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP05173635A JP3109331B2 (en) 1993-06-22 1993-06-22 Form output device

Publications (2)

Publication Number Publication Date
JPH0778214A JPH0778214A (en) 1995-03-20
JP3109331B2 true JP3109331B2 (en) 2000-11-13

Family

ID=15964268

Family Applications (1)

Application Number Title Priority Date Filing Date
JP05173635A Expired - Fee Related JP3109331B2 (en) 1993-06-22 1993-06-22 Form output device

Country Status (1)

Country Link
JP (1) JP3109331B2 (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2001277640A (en) * 2000-03-29 2001-10-09 Casio Comput Co Ltd Device for controlling printing of business form, and memory medium

Also Published As

Publication number Publication date
JPH0778214A (en) 1995-03-20

Similar Documents

Publication Publication Date Title
US6678693B1 (en) Database design system, database design method and record medium
US5765167A (en) Data file update processing apparatus
US20040088650A1 (en) Methods and apparatus for generating a spreadsheet report template
US20060064428A1 (en) Methods and apparatus for mapping a hierarchical data structure to a flat data structure for use in generating a report
US20020010708A1 (en) Defining a uniform subject classification system incorporating document management/records retention functions
JPH05113879A (en) Program creation and data processing method
JP6623754B2 (en) Tabular data processing program, method and apparatus
US6792145B2 (en) Pattern recognition process for text document interpretation
US6108677A (en) Data processing apparatus
JP3109331B2 (en) Form output device
US5642521A (en) Data processing apparatus for extracting and processing arbitrary records from a file
JP3109324B2 (en) Data aggregation device
JP4501459B2 (en) Program, method and apparatus for creating cross table
JP3109330B2 (en) Form output device
US6631380B1 (en) Counting and displaying occurrences of data records
JP3548866B2 (en) Data processing device
JP3064706B2 (en) Data processing device
JP3554768B2 (en) Data aggregation device
JP3551445B2 (en) Form processing device
JP3533469B2 (en) Form output device
Cornell Excel as your database
JP3482651B2 (en) Data processing device
JP3337469B2 (en) Information processing device
JPH08235287A (en) Data processor
JP2000315242A (en) Summary table creating device and storage medium for summary table creating program

Legal Events

Date Code Title Description
FPAY Renewal fee payment (prs date is renewal date of database)

Free format text: PAYMENT UNTIL: 20070914

Year of fee payment: 7

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

Free format text: PAYMENT UNTIL: 20080914

Year of fee payment: 8

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

Free format text: PAYMENT UNTIL: 20090914

Year of fee payment: 9

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

Free format text: PAYMENT UNTIL: 20100914

Year of fee payment: 10

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

Free format text: PAYMENT UNTIL: 20100914

Year of fee payment: 10

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

Free format text: PAYMENT UNTIL: 20110914

Year of fee payment: 11

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

Free format text: PAYMENT UNTIL: 20120914

Year of fee payment: 12

LAPS Cancellation because of no payment of annual fees