JPH0877050A - Device and method for reconstituting data base - Google Patents

Device and method for reconstituting data base

Info

Publication number
JPH0877050A
JPH0877050A JP6210177A JP21017794A JPH0877050A JP H0877050 A JPH0877050 A JP H0877050A JP 6210177 A JP6210177 A JP 6210177A JP 21017794 A JP21017794 A JP 21017794A JP H0877050 A JPH0877050 A JP H0877050A
Authority
JP
Japan
Prior art keywords
information
database
old
updated
old table
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP6210177A
Other languages
Japanese (ja)
Inventor
Kiyoutarou Horiguchi
恭太郎 堀口
Nobuyuki Kobayashi
伸幸 小林
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.)
Nippon Telegraph and Telephone Corp
Original Assignee
Nippon Telegraph and Telephone Corp
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 Nippon Telegraph and Telephone Corp filed Critical Nippon Telegraph and Telephone Corp
Priority to JP6210177A priority Critical patent/JPH0877050A/en
Publication of JPH0877050A publication Critical patent/JPH0877050A/en
Pending legal-status Critical Current

Links

Landscapes

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

Abstract

PURPOSE: To reconstitute a data base which does not have a stand-by system into an on-line data base by reconstituting the data base, which were reconstituted by an in-use system and a stand-by system, by expansion into an old table and a new table in one memory. CONSTITUTION: The data base reconstituting device is so constituted that the old table 203 in the memory 102 contains information on the data base to be reconstituted and the new table 206 contains information after reconstitution. When information in the old table 203 is updated as a result of access from an application program 202, an update history recording means 204 stores an updated history and a matching means 210 after storing all the information of the old table 203 in the new table 206 reflects the information of the updated old table 203 on the new table 206 on the basis of the history stored in the update history recording means 204.

Description

【発明の詳細な説明】Detailed Description of the Invention

【0001】[0001]

【産業上の利用分野】本発明は、データベース再構成装
置及びデータベース再構成方法に係り、特に、データベ
ース管理システム(DBMS)において、サービスを継
続しながら、スキーマを変更してオンラインシステムに
用いられているデータベースを再構成するデータベース
再構成装置及びデータベース再構成方法に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a database restructuring apparatus and a database restructuring method, and more particularly, to a database management system (DBMS) which is used for an online system by changing a schema while continuing service. The present invention relates to a database reconstructing device and a database reconstructing method for reconstructing an existing database.

【0002】[0002]

【従来の技術】データベースの再構成は、データベース
の運用状況に基づいてデータの格納効率、処理効率を向
上させるためにデータベースの物理構造を対象として、
格納領域の拡張、縮小、格納装置の変更(現用系から予
備系)等が行われる。
2. Description of the Related Art Restructuring of a database targets the physical structure of the database in order to improve data storage efficiency and processing efficiency based on the operational status of the database.
The storage area is expanded, reduced, and the storage device is changed (from the active system to the standby system).

【0003】従来データベースの再構成は、データベー
スの論理的構造及び物理的構造を記述するスキーマを変
更する方法がある。データベーススキーマには、実世界
データをモデル化した概念スキーマ、利用者の視点でデ
ータを記述した外部スキーマ、物理構造を記述した内部
スキーマ等があり、これらのスキーマの変更を行うこと
により、データベースの再構成が行われる。
Reconstruction of a conventional database has a method of changing a schema that describes a logical structure and a physical structure of the database. The database schema includes a conceptual schema that models real-world data, an external schema that describes data from the user's perspective, and an internal schema that describes the physical structure.By changing these schemas, the database Reconstruction is performed.

【0004】また、データ実体のデータベースファイル
内での移動を伴う再編成は、現用系・予備系に二重化さ
れているシステムにおいて実現されている。このように
二重化されているデータベースシステムにおいては、現
用系でデータベースシステムの稼働を継続した状態で、
予備系に現用系のDBを複写し、予備系上で再構成を行
い、最後に再構成作業中に現用系で行われた更新の内容
を予備系に反映し、切り替えるものである。
Further, the reorganization accompanied by the movement of the data entity in the database file is realized in the system in which the active system and the standby system are duplicated. In such a duplicated database system, while the database system continues to operate in the active system,
The DB of the active system is copied to the standby system, reconfiguration is performed on the standby system, and the contents of the update made on the active system during the reconfiguration work are finally reflected on the standby system and switched.

【0005】[0005]

【発明が解決しようとする課題】しかしながら、上記の
従来のシステムはデータベースの再構成には、予備系の
データベースを必要とし、予備系のないシステムでは、
現用系の稼働を停止させる以外にはデータの整合がとれ
ないため、実現できないという問題がある。
However, the above-mentioned conventional system requires a spare database to reconstruct the database, and a system without a spare system requires
There is a problem that it cannot be realized because the data cannot be matched except for stopping the operation of the active system.

【0006】本発明は、上記の点に鑑みなされたもの
で、予備系をもたない単独のデータベースシステムでの
オンラインデータベースの再構成を行うことが可能なデ
ータベース再構成装置及びデータベース再構成方法を提
供することを目的とする。
The present invention has been made in view of the above points, and provides a database reconstructing apparatus and a database reconstructing method capable of reconstructing an online database in a single database system having no backup system. The purpose is to provide.

【0007】[0007]

【課題を解決するための手段】図1は、本発明の原理構
成図である。
FIG. 1 is a block diagram showing the principle of the present invention.

【0008】本発明は、データベース管理システムにお
けるデータベースを再構成するデータベース再構成装置
において、再構成対象のデータベースの情報を格納する
旧テーブル203と、再構成後の情報を格納する新テー
ブル206と、アプリケーションプログラム202から
のアクセスにより旧テーブル203の情報が更新された
場合に、更新された履歴を蓄積する更新履歴記憶手段2
04とを有する1つのメモリと、旧テーブル203の全
ての情報を新テーブル206に格納後、更新履歴記録手
段204に蓄積されている履歴に基づいて、更新された
旧テーブル203の情報を新テーブル206に反映させ
る整合手段210とを有する。
According to the present invention, in a database reconfiguring device for reconfiguring a database in a database management system, an old table 203 for storing information on a database to be reconfigured, a new table 206 for storing information after reconfiguration, Update history storage unit 2 that accumulates updated history when information in the old table 203 is updated by access from the application program 202
After storing all the information of the old table 203 in the new table 206, the information of the old table 203 updated based on the history accumulated in the update history recording unit 204 is stored in the new table. And a matching means 210 for reflecting the same in 206.

【0009】また、本発明は、整合手段210により情
報の整合処理の完了後に、アプリケーションプログラム
202のアクセス対象を旧テーブル203から新テーブ
ル206に切り替えるアクセス切替手段211を有す
る。
Further, the present invention has the access switching means 211 for switching the access target of the application program 202 from the old table 203 to the new table 206 after the matching means 210 completes the information matching processing.

【0010】図2は、本発明の原理を説明するためのフ
ローチャートである。
FIG. 2 is a flow chart for explaining the principle of the present invention.

【0011】本発明は、データベース管理システムにお
けるデータベースを再構成を行うデータベース再構成方
法において、1つのメモリ内にアプリケーションプログ
ラムのアクセス対象となる旧テーブルと再構成された情
報を格納する新テーブルとを生成し(ステップ1)、デ
ータベースの情報を旧テーブルに展開し(ステップ
2)、旧テーブルの情報を新テーブルに再構成する。
According to the present invention, in a database restructuring method for reconfiguring a database in a database management system, an old table to be accessed by an application program and a new table for storing reconfigured information are stored in one memory. It is generated (step 1), the information in the database is expanded into the old table (step 2), and the information in the old table is reconfigured into the new table.

【0012】再構成は、アプリケーションプログラムの
稼働中にアクセス対象の旧テーブルの情報を新テーブル
に複写し(ステップ3)、複写中にアプリケーションプ
ログラムにより更新された旧テーブルの情報を識別して
おき(ステップ4)、複写が終了した時点で(ステップ
5)、更新された旧テーブルの情報を新テーブルの情報
に反映させる(ステップ6)。
In the reconfiguration, the information of the old table to be accessed is copied to the new table while the application program is running (step 3), and the information of the old table updated by the application program during copying is identified ( At step 4), when the copying is completed (step 5), the updated old table information is reflected on the new table information (step 6).

【0013】また、上記のステップ3において、複写中
に更新された旧テーブルのレコードの識別子を識別し、
記憶する。
In step 3 above, the identifier of the record of the old table updated during copying is identified,
Remember.

【0014】また、上記のステップ4の後に、即ち、更
新された旧テーブルの情報を新テーブルの情報に反映さ
せた後に、アクセス対象を旧テーブルから新テーブルの
情報に切り替える(ステップ7)。
After step 4, that is, after the updated old table information is reflected in the new table information, the access target is switched from the old table to the new table information (step 7).

【0015】さらに、本発明は、旧テーブルの情報を新
テーブルの情報に反映中、または、反映後に旧テーブル
の情報が更新された場合に、更新された情報を新テーブ
ルに再度反映させる。
Further, according to the present invention, when the information of the old table is being reflected in the information of the new table or when the information of the old table is updated after the reflection, the updated information is reflected again in the new table.

【0016】[0016]

【作用】本発明は、従来、現用系と予備系で行っていた
データベースの再構成を、1つのメモリ内において旧テ
ーブルと新テーブルに展開して再構成を行うものであ
る。
According to the present invention, the restructuring of the database, which has been conventionally performed in the active system and the standby system, is expanded into the old table and the new table in one memory to perform the reconfiguration.

【0017】本発明は、再構成対象テーブル(上記で
は、旧テーブル)の再構成後のレコードを格納するため
のテーブル(新テーブル)を作成し、旧テーブルへのア
プリケーションプログラムのアクセス処理を続行させ、
アプリケーションプログラムにより更新された旧テーブ
ルのレコードの識別子を更新履歴記録として記録しなが
ら、旧テーブルの全ての情報を新テーブルに格納する。
従って、旧テーブルの情報を新テーブルへ複写した後
に、更新履歴記録を参照して更新履歴記録の識別子に該
当する旧テーブルの更新済情報を新テーブルに反映する
ことにより、情報の整合をとることが可能である。
The present invention creates a table (new table) for storing reconstructed records of a table to be reconstructed (in the above, the old table), and continues the access processing of the application program to the old table. ,
All the information of the old table is stored in the new table while recording the identifier of the record of the old table updated by the application program as the update history record.
Therefore, after the information in the old table is copied to the new table, the updated information of the old table corresponding to the identifier of the update history record is reflected in the new table by referring to the update history record, so that the information can be consistent. Is possible.

【0018】さらに、アプリケーションプログラムが停
止するまで、または、整合処理中に旧テーブルの情報が
更新された場合でも、再度更新履歴記録を参照すること
により、最終時点での旧テーブルの情報を新テーブルに
反映することができるので、無矛盾に整合をとることが
可能である。
Further, even when the information of the old table is updated until the application program is stopped or during the matching process, the information of the old table at the final point is updated to the new table by referring to the update history record again. Since it can be reflected in, it is possible to achieve consistent consistency.

【0019】さらに、情報の整合処理の終了後、アプリ
ケーションプログラムのアクセス対象を旧テーブルから
新テーブルへと切り替える。これにより、整合がとれた
状態のデーブルをアクセスすることが可能である。
Further, after the information matching process is completed, the access target of the application program is switched from the old table to the new table. This makes it possible to access the table in a consistent state.

【0020】[0020]

【実施例】以下、図面と共に本発明の実施例を説明す
る。
Embodiments of the present invention will be described below with reference to the drawings.

【0021】本発明は、図3に示す環境で実施される。
即ち、メインメモリ102上にデータベース103を展
開し、プロセッサ101がアプリケーションプログラム
を実行することにより、処理を行うものである。このと
き、データベース103は、データベース管理システム
(DBMS)により管理されている。
The present invention is implemented in the environment shown in FIG.
That is, the database 103 is expanded on the main memory 102, and the processor 101 executes an application program to perform processing. At this time, the database 103 is managed by a database management system (DBMS).

【0022】図4は、本発明の一実施例のデータベース
の再構成を行うシステムの構成を示す。同図に示すシス
テムは、図3に示すようなシステム上で動作するもので
ある。プロセッサ101は、アクセス部201、データ
内容変換部207、アプリケーションプログラム20
2、205より構成される。メインメモリ102は、旧
テーブル203、新テーブル206及び更新履歴記録部
204とを有し、データベース103の内容を旧テーブ
ル203に展開しているものとする。従って、旧テーブ
ル203は、再構成前のテーブルであり、アプリケーシ
ョンプログラム202によりアクセスされる。新テーブ
ル206は、再構成により生成されるテーブルであり、
旧テーブル203の複写情報及び更新情報が格納され
る。
FIG. 4 shows the structure of a system for reconstructing a database according to an embodiment of the present invention. The system shown in the figure operates on the system as shown in FIG. The processor 101 includes an access unit 201, a data content conversion unit 207, an application program 20.
2, 205. The main memory 102 has an old table 203, a new table 206, and an update history recording unit 204, and the contents of the database 103 are expanded in the old table 203. Therefore, the old table 203 is a table before reconstruction and is accessed by the application program 202. The new table 206 is a table generated by reconfiguration,
The copy information and update information of the old table 203 are stored.

【0023】アクセス部201は、アプリケーションプ
ログラム202、205より旧テーブル203または、
新テーブル206へのアクセスを制御すると共に、更新
履歴記録部204へ旧テーブルの更新履歴情報の書込み
及び参照等の処理を行う。データ内容変換部207は、
再構成の際にデータの内容を変換する必要がある場合
に、ユーザにより定義され、データ内容変換アプリケー
ションプログラムに従って、データの内容が更新され
る。また、再構成の際に必要に応じて新テーブル206
を動作対象とする新アプリケーションプログラム205
と入れ換える。
The access unit 201 has a table 203 older than the application programs 202 and 205, or
While controlling access to the new table 206, processing such as writing and referring to the update history information of the old table in the update history recording unit 204 is performed. The data content conversion unit 207
When it is necessary to convert the contents of the data during the reconstruction, the contents of the data are updated according to the data contents conversion application program defined by the user. In addition, the new table 206 may be reconfigured if necessary.
New application program 205 that targets
Replace with.

【0024】更新履歴記録部204は、再構成中の旧テ
ーブル203の内容が、アプリケーションプログラム2
02により更新された際に、更新履歴として旧テーブル
203のレコードIDを記録する。
In the update history recording unit 204, the contents of the old table 203 being reconstructed are
When updated by 02, the record ID of the old table 203 is recorded as the update history.

【0025】図5は、本発明の一実施例の処理動作を説
明するためのフローチャートである。
FIG. 5 is a flow chart for explaining the processing operation of one embodiment of the present invention.

【0026】ステップ101)まず、データベースの再
構成を行う際に、データベース103の内容をメインメ
モリ102内の旧テーブル203に展開し、アプリケー
ションプログラム202がアクセス部201を介して旧
テーブル203をアクセスする。
Step 101) First, when reconstructing the database, the contents of the database 103 are expanded into the old table 203 in the main memory 102, and the application program 202 accesses the old table 203 via the access unit 201. .

【0027】ステップ102)アプリケーションプログ
ラム202は、再構成後のレコードを格納するための新
テーブル206をメインメモリ102内に作成する。
(Step 102) The application program 202 creates a new table 206 in the main memory 102 for storing the reconstructed record.

【0028】ステップ103)全ての旧テーブル203
のレコードが複写済であれば、ステップ109に移行す
る。
Step 103) All old tables 203
If the record is already copied, the process proceeds to step 109.

【0029】ステップ104)アプリケーションプログ
ラム202がアクセス部201を介して旧テーブル20
3内のレコードを読み出す。
Step 104) The application program 202 causes the access table 201 to access the old table 20.
Read the record in 3.

【0030】ステップ105)旧テーブル203から読
み出されたレコードに対してデータ形式変換アプリケー
ションプログラムによりデータ形式変換処理を行う。こ
のとき、アプリケーションプログラム202によりデー
タ内容変換処理を行うように指定されていれば、さらに
データ内容変換部207のアプリケーションプログラム
を用いてデータ内容変換を行う。
Step 105) The data format conversion processing is performed by the data format conversion application program on the record read from the old table 203. At this time, if the application program 202 specifies to perform the data content conversion process, the data content conversion is further performed using the application program of the data content conversion unit 207.

【0031】ここで、データ形式変換とは、データの格
納形式を新テーブル206のフィールド形式に合致する
ように変換することである。例えば、8ビットの整数の
フィールドを16ビットに拡張する場合や、文字フィー
ルドを32文字から48文字に拡張する等の変換を行
う。
Here, the data format conversion is to convert the data storage format so as to match the field format of the new table 206. For example, conversion is performed to expand an 8-bit integer field to 16 bits, or to expand a character field from 32 characters to 48 characters.

【0032】また、内容の変換とは、数値のフィールド
の内容、意味を一律に変更するような変換であり、例え
ば、“価格”のフィールドには、今まで消費税抜きの価
格が入っていたが、アプリケーションプログラムの変更
に伴って税込みの価格に変更するような変換を言う。
Further, the content conversion is a conversion in which the content and meaning of a numerical field are uniformly changed. For example, in the "price" field, a price excluding consumption tax has been entered until now. However, it is a conversion that changes to a price including tax as the application program changes.

【0033】さらに、形式の変換と、内容の変換を同時
に行う場合もあり、これらは、アプリケーションプログ
ラムによって任意に変換が可能である。
Further, the format conversion and the content conversion may be performed at the same time, and these can be arbitrarily converted by an application program.

【0034】ステップ106)上記のステップ105に
おいて、データ形式変換処理及びデータ内容変換処理が
施された旧テーブル203のレコードは、新テーブル2
06に格納される。
Step 106) The record of the old table 203 which has been subjected to the data format conversion processing and the data content conversion processing in the above step 105 is the new table 2
It is stored in 06.

【0035】ステップ107)ここで、アプリケーショ
ンプログラム202により旧テーブル203のレコード
の更新が行われた場合には、ステップ108に移行し、
更新が行われていない場合には、ステップ103に移行
する。
(Step 107) If the record of the old table 203 is updated by the application program 202, the process proceeds to Step 108,
If it has not been updated, the process proceeds to step 103.

【0036】ステップ108)アクセス部201は、旧
テーブル203のレコードの更新が行われた場合には、
更新されたレコードのIDを更新履歴記録部204に格
納する。
Step 108) The access unit 201, when the record of the old table 203 is updated,
The ID of the updated record is stored in the update history recording unit 204.

【0037】ステップ109)全ての旧テーブルのレコ
ードの複写が終了したらアプリケーションプログラム処
理を停止する。
Step 109) When the copying of all the records of the old table is completed, the application program processing is stopped.

【0038】ステップ110)アクセス部201は、更
新履歴記録部204より再変換が必要なレコードのID
を取り出す。ここで取り出されるレコードIDは、アプ
リケーションプログラム202によりn(n≧1)回更
新されている旧テーブル203のレコードである。
Step 110) The access unit 201 determines the ID of the record that needs to be reconverted by the update history recording unit 204.
Take out. The record ID fetched here is a record of the old table 203 that has been updated n (n ≧ 1) times by the application program 202.

【0039】ステップ111)取り出したレコードのI
Dに該当するレコードを旧テーブル203から読み出
す。
Step 111) I of the retrieved record
The record corresponding to D is read from the old table 203.

【0040】ステップ112)旧テーブル203から取
り出したレコードを新テーブル206に適応するように
データ変換を行う。
Step 112) Data conversion is performed so that the record taken out from the old table 203 is adapted to the new table 206.

【0041】ステップ113)データ変換された旧テー
ブル203のレコードは、新テーブル206に格納され
る。
Step 113) The data-converted record of the old table 203 is stored in the new table 206.

【0042】ステップ114)ここで、更新履歴記録部
204に記録されているIDの全ての処理が終了してい
れば、ステップ115に移行し、まだ、処理されていな
いIDが残っていれば、ステップ110に移行する。
(Step 114) Here, if all the processing of the ID recorded in the update history recording unit 204 has been completed, the process proceeds to Step 115, and if there are still unprocessed IDs, Go to step 110.

【0043】ステップ115)アプリケーションプログ
ラム202がアクセスするテーブルを旧テーブル203
から新テーブル206に切り替える。
Step 115) The table accessed by the application program 202 is the old table 203.
To the new table 206.

【0044】ステップ116)ステップ109において
停止しているアプリケーションプログラム202の起動
禁止を解除する。また、必要であれば、使用するアプリ
ケーションプログラムを他のプログラム205に切り替
える。
(Step 116) The prohibition of starting the application program 202 stopped in Step 109 is released. Also, if necessary, the application program to be used is switched to another program 205.

【0045】次に、旧テーブル203と新テーブルの各
状態を説明する。
Next, each state of the old table 203 and the new table will be described.

【0046】図6は、本発明の一実施例の再構成を行っ
ていない通常の動作状態を示す。アプリケーションプロ
グラム202により、アプリケーションプログラム20
2は、旧テーブル203のレコード番号“2”、“8”
にアクセスしており、レコード番号“4”、“6”を参
照している。
FIG. 6 shows a normal operation state in which one embodiment of the present invention is not reconfigured. The application program 202 allows the application program 20
2 is the record numbers “2” and “8” of the old table 203
Is being accessed, and the record numbers “4” and “6” are referenced.

【0047】図7は、本発明の一実施例の新テーブルに
旧テーブルの情報が複写された状態を示す。アプリケー
ションプログラム202が起動し、データベースの再構
成を行うために、旧テーブル203のレコード番号1〜
4がデータ形式変換処理及びデータ内容変換処理が施さ
れて新テーブルのレコード番号1〜4に複写される。さ
らに、旧テーブル203のレコード番号“1”、と
“3”が更新される。従って、更新履歴記録部204に
は、更新履歴リストとして旧テーブル203のコードI
D“1”、“3”が記録される。
FIG. 7 shows a state in which the information of the old table is copied to the new table according to the embodiment of the present invention. In order to reconfigure the database by starting the application program 202, the record numbers 1 to 1 in the old table 203
4 is subjected to data format conversion processing and data content conversion processing and is copied to record numbers 1 to 4 of the new table. Further, the record numbers “1” and “3” of the old table 203 are updated. Therefore, the update history recording unit 204 stores the code I of the old table 203 as an update history list.
D "1" and "3" are recorded.

【0048】図8は、本発明の一実施例の旧テーブルが
再度更新された状態を示す。同図は、旧テーブルの全て
の(同図では10レコード)レコードが新テーブル20
6に複写されており、さらに、更新履歴記録部204の
リストには、更新済の旧テーブルのレコードIDとして
“5,2,8,1,3”が記録されている。この場合に
は、更新履歴記録部204の更新履歴リストに記録され
ているIDの全ての旧テーブル203のレコード(更新
済レコード)を読出し、データ変換を行い、新テーブル
206に格納する。
FIG. 8 shows a state in which the old table according to the embodiment of the present invention is updated again. In the figure, all the records (10 records in the figure) of the old table are the new table 20.
6 is recorded in the list of the update history recording unit 204, and “5, 2, 8, 1, 3” is recorded as the record ID of the updated old table. In this case, all the records (updated records) of the old table 203 with the ID recorded in the update history list of the update history recording unit 204 are read, data conversion is performed, and the new table 206 is stored.

【0049】次に具体的な例を用いて説明する。図9
は、本発明の一実施例の旧テーブル、新テーブル及び更
新履歴記録部の各状態を示す。
Next, a specific example will be described. Figure 9
Shows respective states of the old table, new table, and update history recording unit according to the embodiment of the present invention.

【0050】アプリケーションプログラム202が起動
され、データベースの再構成処理が開始されているとす
る。
It is assumed that the application program 202 is activated and the database restructuring process is started.

【0051】ここで、最初に、旧テーブル203のレ
コード番号“1”のデータ“A”が新テーブル206に
複写される。この時は、旧テーブル203は更新されな
い。
Here, first, the data “A” of the record number “1” of the old table 203 is copied to the new table 206. At this time, the old table 203 is not updated.

【0052】次に、旧テーブル203のレコード番号
“2”のデータ“B”が新テーブル206に複写され
る。このとき、旧テーブルレコード番号“1”のデータ
が“A”から“α”に更新される。従って、更新履歴記
録部204のリストには、旧テーブル203のレコード
番号“1”が記録される。
Next, the data "B" of the record number "2" of the old table 203 is copied to the new table 206. At this time, the data of the old table record number “1” is updated from “A” to “α”. Therefore, the record number “1” of the old table 203 is recorded in the list of the update history recording unit 204.

【0053】さらに、旧テーブル203のレコード番
号“3”のデータ“C”が新テーブル206に複写され
る。
Further, the data “C” of the record number “3” of the old table 203 is copied to the new table 206.

【0054】旧テーブル203のレコード番号“4”
のデータ“D”が新テーブル206に複写される。
Record number "4" of old table 203
Data “D” of the above is copied to the new table 206.

【0055】中略 旧テーブル203のレコード番号“9”のデータ
“I”が新テーブル206に複写される。このとき、旧
テーブル203のレコード番号“7”のデータ“G”が
“θ”に更新される。従って、この時の更新履歴記録部
204のリストには、“1,2,4,7”が記録されて
いる。
The data "I" of the record number "9" of the old table 203 is copied to the new table 206. At this time, the data “G” of the record number “7” of the old table 203 is updated to “θ”. Therefore, "1, 2, 4, 7" is recorded in the list of the update history recording unit 204 at this time.

【0056】旧テーブル203の最後のレコード番号
“10”のデータ“J”が新テーブル206に複写され
る。最後のレコード番号“10”の内容を新テーブル2
06に複写した時点の更新履歴記録部204のリストに
は、“1,2,4,7”が記録されている。
The data "J" of the last record number "10" of the old table 203 is copied to the new table 206. The contents of the last record number "10" are set in the new table 2
"1, 2, 4, 7" is recorded in the list of the update history recording unit 204 at the time of copying to 06.

【0057】ここで、全ての旧テーブル203のデー
タの複写が終了しているので、更新履歴記録部204に
記録されている更新済の旧テーブル203のレコードI
Dに基づいて新テーブル206の内容を更新していく。
更新した結果は以下のようになる。
Since all the data in the old table 203 has been copied, the record I of the updated old table 203 recorded in the update history recording unit 204 is recorded.
The contents of the new table 206 are updated based on D.
The updated result is as follows.

【0058】[0058]

【表1】 [Table 1]

【0059】ここで、反映処理中にさらに、旧テーブル
203の内容がアプリケーションプログラム202によ
り更新されたとする。この例では、旧テーブル203の
レコード番号“6”のデータが“F”から“γ”に更新
され、さらに、レコード番号“3”のデータが“C”か
ら“ε”に更新されたとする。この時の更新履歴記録部
204のリストは、“1,2,4,7,6,3”とな
り、更新されているデータを旧テーブル203のレコー
ドIDに対応する新テーブル206のレコード番号
“6”及び“3”に更新されたデータ反映させる。即
ち、データ“F”を“γ”に、“C”を“ε”に更新す
る。従って、最終的な新テーブルの反映処理のデータ
は、以下のようになる。
Here, it is assumed that the contents of the old table 203 are further updated by the application program 202 during the reflection process. In this example, it is assumed that the data of the record number “6” in the old table 203 is updated from “F” to “γ”, and the data of the record number “3” is updated from “C” to “ε”. At this time, the list of the update history recording unit 204 is “1, 2, 4, 7, 6, 3”, and the updated data has the record number “6” corresponding to the record ID of the old table 203. The updated data is reflected in "" and "3". That is, the data “F” is updated to “γ” and “C” is updated to “ε”. Therefore, the final reflection data of the new table is as follows.

【0060】[0060]

【表2】 [Table 2]

【0061】上記の例から分かるように、更新履歴を更
新履歴記録部204に記録し、データの変換、新テーブ
ルの格納が終了した時点で、更新履歴記録部204より
更新されたレコードのID(番号)を取り出し、当該レ
コードを再び変換し、新テーブル206に格納する。
As can be seen from the above example, the update history is recorded in the update history recording unit 204, and when the data conversion and the storage of the new table are completed, the ID of the record updated by the update history recording unit 204 ( Number) is extracted, the record is converted again, and stored in the new table 206.

【0062】更新された情報を新テーブル206に反映
中(または、反映処理終了からアプリケーションプログ
ラム起動禁止完了までの間)に、旧テーブル203の情
報が更新されている場合にも同様に、更新履歴記録部2
04のリストを参照して再度新テーブル206への反映
処理を行うことで、データの整合をとることが可能であ
る。
Similarly, when the information in the old table 203 is being updated while the updated information is being reflected in the new table 206 (or from the end of the reflecting process to the completion of the application program start prohibition), the update history is similarly changed. Recording unit 2
The data can be matched by referring to the list No. 04 and performing the reflection process on the new table 206 again.

【0063】なお、上記の実施例では、旧テーブル20
3のレコードの新テーブル206への複写処理が終了し
た後に、整合処理を行う間、アプリケーションプログラ
ムの実行を停止させ、更新履歴記録部204のリストに
基づいて整合処理を行い、再実行させるが、実際には、
整合されるレコードは1、2個であるので、事実上、ア
プリケーションプログラムを停止させておく時間は短
く、無中断と見做すことができる。
In the above embodiment, the old table 20 is used.
After the copying process of the record of No. 3 to the new table 206 is completed, while executing the matching process, the execution of the application program is stopped, the matching process is performed based on the list of the update history recording unit 204, and the re-execution is performed. actually,
Since the number of matched records is one or two, the time period for which the application program is stopped is practically short and can be regarded as uninterrupted.

【0064】本発明は、上記の実施例に限定されること
なく、特許請求の範囲内で種々変更・応用が可能であ
る。
The present invention is not limited to the above embodiments, but various modifications and applications are possible within the scope of the claims.

【0065】[0065]

【発明の効果】上述のように本発明によれば、二重化さ
れていないデータベースシステムにおいて、データベー
スアクセス処理を中断せずに、システム稼働状態のまま
データベースのスキーマ変更/データ内容の一括更新等
の再構成を行うことができ、データベース保守によるサ
ービス中断時間が極めて短くなり、データベースの稼働
率を向上させることができる。
As described above, according to the present invention, in a non-redundant database system, the database access process is not interrupted and the database schema is changed / the data contents are collectively updated without changing the system operating state. The configuration can be performed, the service interruption time due to database maintenance can be extremely shortened, and the operation rate of the database can be improved.

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

【図1】本発明の原理構成図である。FIG. 1 is a principle configuration diagram of the present invention.

【図2】本発明の原理を説明するためのフローチャート
である。
FIG. 2 is a flow chart for explaining the principle of the present invention.

【図3】本発明の一実施例のシステム構成図である。FIG. 3 is a system configuration diagram of an embodiment of the present invention.

【図4】本発明の一実施例のデータベース管理システム
の構成図である。
FIG. 4 is a configuration diagram of a database management system according to an embodiment of the present invention.

【図5】本発明の一実施例の処理動作を説明するための
フローチャートである。
FIG. 5 is a flowchart illustrating a processing operation according to an embodiment of the present invention.

【図6】本発明の一実施例の再構成を行っていない通常
の動作状態を示す図である。
FIG. 6 is a diagram showing a normal operation state in which reconstruction is not performed according to an embodiment of the present invention.

【図7】本発明の一実施例の新テーブルに旧テーブルの
情報が複写された状態を示す図である。
FIG. 7 is a diagram showing a state in which information on an old table is copied to a new table according to an embodiment of the present invention.

【図8】本発明の一実施例の旧テーブルが再度更新され
た状態を示す図である。
FIG. 8 is a diagram showing a state in which an old table according to an embodiment of the present invention is updated again.

【図9】本発明の一実施例の旧テーブル、新テーブル及
び更新履歴記録部の各状態を示す図である。
FIG. 9 is a diagram showing respective states of an old table, a new table, and an update history recording unit according to an embodiment of the present invention.

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

101 プロセッサ 102 メインメモリ 103 データベース 200 データベース管理システム(DBMS) 201 アクセス部 202 アプリケーションプログラム 203 旧テーブル 204 更新履歴記録部 205 新アプリケーションプログラム 206 新テーブル 207 データ内容変換部 210 整合手段 211 アクセス切替手段 101 processor 102 main memory 103 database 200 database management system (DBMS) 201 access unit 202 application program 203 old table 204 update history recording unit 205 new application program 206 new table 207 data content conversion unit 210 matching unit 211 access switching unit

Claims (7)

【特許請求の範囲】[Claims] 【請求項1】 データベース管理システムにおけるアプ
リケーションプログラムの動作を継続させたまま、デー
タベースを再構成するデータベース再構成装置におい
て、 再構成対象の該データベースの情報を格納する旧テーブ
ルと再構成後の情報を格納する新テーブルと、アプリケ
ーションプログラムからのアクセスにより該旧テーブル
の情報が更新された場合に、更新された履歴を蓄積する
更新履歴記憶手段とを有する1つのメモリと、 該旧テーブルの全ての情報を該新テーブルへ格納後、該
更新履歴記憶手段に蓄積されている履歴に基づいて、更
新された該旧テーブルの情報を該新テーブルに格納する
整合手段とを有することを特徴とするデータベース再構
成装置。
1. A database reconfiguring apparatus for reconfiguring a database while continuing the operation of an application program in a database management system, wherein an old table storing information of the database to be reconfigured and information after reconfiguration are displayed. One memory having a new table to be stored and update history storage means for accumulating an updated history when information of the old table is updated by access from an application program, and all information of the old table Is stored in the new table, and a matching means for storing the updated information of the old table in the new table based on the history accumulated in the update history storage means. Configuration device.
【請求項2】 前記整合手段により情報の整合処理の完
了後に、アクセス対象を前記旧テーブルから新テーブル
に切り替えるアクセス切り替え手段を有する請求項1記
載のデータベース再構成装置。
2. The database reconfiguring apparatus according to claim 1, further comprising an access switching unit that switches an access target from the old table to the new table after the matching unit completes the information matching process.
【請求項3】 データベース管理システムにおけるアプ
リケーションプログラムの動作を継続させたままデータ
ベースを再構成を行うデータベース再構成方法におい
て、 1つのメモリ内にアプリケーションプログラムのアクセ
ス対象となる旧テーブルと、再構成された情報を格納す
る新テーブルとを生成し、 該データベースの情報を該旧テーブルに展開し、 該旧テーブルの情報を該新テーブルに再構成することを
特徴とするデータベース再構成方法。
3. A database restructuring method for reconfiguring a database while continuing the operation of an application program in a database management system, wherein an old table to be accessed by the application program is reconfigured in one memory. A new table for storing information is generated, the information of the database is expanded to the old table, and the information of the old table is reconfigured to the new table.
【請求項4】 アプリケーションプログラムの稼働中に
アクセス対象の前記旧テーブルの情報を前記新テーブル
に複写し、 複写中に該アプリケーションプログラムにより更新され
た該旧テーブルの情報を識別しておき、 複写が終了した時点で、更新された前記旧テーブルの情
報を前記新テーブルの情報に反映させる請求項3記載の
データベース再構成方法。
4. The information of the old table to be accessed is copied to the new table while the application program is running, and the information of the old table updated by the application program is identified during copying, and copying is performed. The database restructuring method according to claim 3, wherein the updated information of the old table is reflected in the information of the new table when the processing is completed.
【請求項5】 複写中に更新された前記旧テーブルのレ
コードの識別子を識別し、記憶する請求項3記載のデー
タベース再構成方法。
5. The database restructuring method according to claim 3, wherein the identifier of the record of the old table updated during copying is identified and stored.
【請求項6】 更新された前記旧テーブルの情報を前記
新テーブルの情報に反映させた後に、アクセス対象を前
記新テーブルに切り替える請求項4記載のデータベース
再構成方法。
6. The database restructuring method according to claim 4, wherein after the updated information of the old table is reflected in the information of the new table, the access target is switched to the new table.
【請求項7】 前記旧テーブルの情報を前記新テーブル
の情報に反映中、または、反映後に、前記旧テーブルの
情報が更新された場合に、更新された情報を前記新テー
ブルに再度反映させる請求項4記載のデータベース再構
成方法。
7. The updated information is reflected again in the new table when the information in the old table is updated during or after the information in the old table is reflected in the information in the new table. Item 4. The database reconstruction method according to item 4.
JP6210177A 1994-09-02 1994-09-02 Device and method for reconstituting data base Pending JPH0877050A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP6210177A JPH0877050A (en) 1994-09-02 1994-09-02 Device and method for reconstituting data base

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP6210177A JPH0877050A (en) 1994-09-02 1994-09-02 Device and method for reconstituting data base

Publications (1)

Publication Number Publication Date
JPH0877050A true JPH0877050A (en) 1996-03-22

Family

ID=16585059

Family Applications (1)

Application Number Title Priority Date Filing Date
JP6210177A Pending JPH0877050A (en) 1994-09-02 1994-09-02 Device and method for reconstituting data base

Country Status (1)

Country Link
JP (1) JPH0877050A (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20040050958A (en) * 2002-12-11 2004-06-18 텔코웨어 주식회사 Memory database back-up apparatus by duplicating management and method thereof
KR100498520B1 (en) * 1997-02-28 2005-11-22 소니 가부시끼 가이샤 Information processing method and information processing device
JP2006251990A (en) * 2005-03-09 2006-09-21 Fujitsu Ltd Database reorganization program and database reorganization method
JP2012226453A (en) * 2011-04-15 2012-11-15 Toshiba Corp Database device and database reorganization method
CN113704265A (en) * 2021-08-31 2021-11-26 上海华力集成电路制造有限公司 Data maintenance method, system, electronic equipment and storage medium

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR100498520B1 (en) * 1997-02-28 2005-11-22 소니 가부시끼 가이샤 Information processing method and information processing device
KR20040050958A (en) * 2002-12-11 2004-06-18 텔코웨어 주식회사 Memory database back-up apparatus by duplicating management and method thereof
JP2006251990A (en) * 2005-03-09 2006-09-21 Fujitsu Ltd Database reorganization program and database reorganization method
JP2012226453A (en) * 2011-04-15 2012-11-15 Toshiba Corp Database device and database reorganization method
CN113704265A (en) * 2021-08-31 2021-11-26 上海华力集成电路制造有限公司 Data maintenance method, system, electronic equipment and storage medium

Similar Documents

Publication Publication Date Title
US5745753A (en) Remote duplicate database facility with database replication support for online DDL operations
CA2288016C (en) Method and system for recovery in a partitioned shared nothing database system using virtual shared disks
EP1461700B1 (en) Appliance for management of data replication
US6898688B2 (en) Data management appliance
JP4237354B2 (en) Transaction processing method and transaction processing system
JP4028820B2 (en) Method and apparatus for selective caching of transactions in a computer system
US8239356B2 (en) Methods and apparatuses for data protection
US20080183776A1 (en) Database backup, refresh and cloning system and method
US20030131253A1 (en) Data management appliance
JPH07175700A (en) Database management system
US20070061540A1 (en) Data storage system using segmentable virtual volumes
US20090094366A1 (en) Coordinated Quiesce of a Distributed File System
JP5201133B2 (en) Redundant system, system control method and system control program
WO2016192496A1 (en) Data migration processing method and device
US10585895B2 (en) Method and apparatus for reconstructing standby node database
JP4046893B2 (en) Database copying apparatus, database copying method, and computer-readable recording medium recording a database copying program
JP2004318288A (en) Method and device for processing data and its processing program
JPH0877050A (en) Device and method for reconstituting data base
CA2167902A1 (en) Remote duplicate database facility with database replication support for online ddl operations
JP2002318717A (en) Database system
JPH06250830A (en) Service non-interruption program substituting device
JP3330006B2 (en) Network system including information storage system, input system of the system, and
JP2004199264A (en) Data base processing method and device for its implementation and its processing program
JPH08278911A (en) Multiple-system processing system
JPH0962554A (en) Quiescent point save generation system