Method for communicating data between differently structured data files
In practice an increasing amount of data is exchanged between computer applications with different file structures, installed on dif- ferent computers, localized at more or less large mutual distance and programmed, used, and managed by different persons or organizations. For transferring low data volumes in an unstructured format standard elec¬ tronic mail software (Email) is used. For transferring large data vol¬ umes in a format, which is agreed by the users, use is made of a "file transfer" specifically developed for each type of transfer, or of an EDI (electronic data interchange) system, developed for each type of trans¬ fer.
EP 0,449,494 describes a system for transferring data between two systems each using its own data format and both using the same data structure. In principle data is transmitted by a sender in its own native format and converted by the receiver which for that purpose dis¬ poses of a dedicated conversion program. If differently structured data¬ bases are involved then each database should be related to a number of dedicated conversion programs to enable communication between the vari- ous databases.
US 5,119,465 describes a system for transferring data between two databases each using its own data format. To solve the data format prob¬ lem a format conversion system is developed. According to this prior art publication the sender disposes of front end converter for converting a source data structure in a source format to data for an intermediary. The back end converter converts the data from the intermediary to a target data structure m a target data format used by the receiver. The intermediary includes a rather complicated domain conversion arrange¬ ment. The various conversion processes are controlled by a converter executive.
This prior art system is destined to be used on one computer sys¬ tem to enable data transfer between applications with different data format and/or different data structure and is not suited for communicat¬ ing data between different computers using standard communication chan- nels and commercially available communication software.
EP 0,130,375 also describes a system for transferring data between two computers each using its own data format, both using the same data structure. To solve the data format problem a format conver-
sion system is developed for converting one specific format into another specific format. This prior art system is restricted to the selected specific formats and structures and has therefore no universal applic¬ ability. An object of the invention is now to provide a universally appli¬ cable system which is independent of the number of differently struc¬ tured databases and the number of computers involved and requires only a restricted amount of software.
The invention describes a system (called PMS) for transfer of medium large volumes in a format which is not fixed or formally agreed by the parties (see figure 1).
The method
The method according to the invention (PMS = Packet Message Sys- tem) comprises the following components and procedures.
The sender of an amount of data to be transferred (hereinafter called: a message) disposes of a software program (hereinafter called the message writing program) offering the possibility to compile various messages (variable in structure and composition) from its own specific data collection and to get these messages as separate files ready for transmission. Thereafter, the message can be transmitted using one of the standard on the market available programs for data communication, using a protocol which is supported by the message receiver.
The message is received with one of the standard on the market available data communication programs using the respective protocol.
The message receiver disposes of a software program (hereinafter called the message reading program) offering the possibility to add data from the various messages (variable in structure and composition) to its own specific data collection The dedicated message writing program and the dedicated message reading program are able to compose or process respectively various messages by addjng parameters to the programs to connect the file struc¬ ture of the own data collection with its own different field names and/- or descriptions to the data structure and the field names and/or des- criptions of the various messages.
For writing and reading messages a table with message models (message model table) is offered to the writing/reading software For reading and writing the own specific data collections a table with field
names (connecting table) is offered to the writing/reading software (see also figure 2) .
The Universal Message The basis of the method is a universal message. That is the des¬ cription of all possible messages based on some prescribed rules. All possible messages are specific but have a universal frame. The message contains fields with cells each having a serial number within the mess¬ age. The only thing to be transmitted is the succession number of the cell within the message followed by the contents of the cell. In that way the serial number forms the label of the succeeding value.
As field types the message distinguishes between cells in tables, cells in repetitive groups and single cells. The following rules apply:
- A table is a series of cells which always appears only once. - A row is a repetitive group of cells which either appear not or appear
N times.
- A table, row, or cell can be obligatory or not.
- Within tables and rows other tables and rows can be present.
- Cells can appear withm or outside tables and rows. - The first table, row, or cell within a table or row is always obliga¬ tory.
Using these rules it is possible to draft simple (flat file) mes¬ sages, however, also complex forms which are practically unlimited in length and dimensions can be drafted by defining repetitive groups with- m repetitive groups.
Messages are drafted in agreement with the method and read by comparing the labels (field serial number) to the corresponding unique element numbers as are defined in the message model to be consulted. According to the method values are retrieved and positioned by comparing the unique element number with the numbers in a connecting table in which the position in the own data structure is indicated.
Message-model-table
The message-model-table comprises the following data:
Message name The PMS name of the message
Field serial number The serial number of the field within the message
Type T (table), R (row or repetitive group) or C (cell)
Obligatory Field is obligatory or not
Parent Higher order field serial number in a fleld hier¬ archy
Element number The unique PMS number of the element which should be inscribed in that field
Additional data can be added to simplify or speed up the process¬
Message number The unique PMS message number Message version The version of the message Group name The name of a group (= table or row) Status For instance C (copy) F (fixed) P (presentation)
0 (object)
Element name The unique PMS name of the element
The connecting table
The connecting table comprises the following data:
Message number The unique PMS number of the message Element number The unique PMS number of the element Own application The name of the application from which this message was drafted or in which the message will be input
Own file The name of the file inside the application from within the message was drafted or in which the mes¬ sage was input
Own label The label of the own field within the o.n file for the respective contents
Additional data can be included to speed up or simplify the pro¬ cessing, for instance:
Message version The version of the message Codes/Indexes For instance: bKey, bWhile, bFor, bExpr, for an application programmed in Clipper
Format The format of the element (for instance: numerical)
Code table The name of a code table to be used eventually Element name The unique PMS name of the element Description The description of the element to be used also as Help-text in the software
Example of a message model
Message name School children Version number 1.0
Serial Element number Type Obligatory Parent number (Element and group names)
1 T Y 0 Control data
2 C Y 464661 Model name of the message
3 C Y 548957 Version number of the model name
4 c Y 980931 Name of the sender
5 c N 989243 Data line number of the sender
6 C N 323499 Name of the receiver
7 C Y 187867 Data line number of the receiver
8 R Y 0 Schools
9 C Y 8 565088 Name of the school
10 R Y 8 Classes
11 C Y 10 466610 Class indication
12 R N 10 Children
13 C Y 12 465683 Name of the child
14 C Y 12 654809 Age of the child
Example of a message in agreement with the above described model
2,School children 3,1.0 .van der Meer 7,0123-456789 9,The Weather-vane 11 ,class 2
13, an
14,7
13,Pιet
14,8
9, he Circle
11 ,class 2
11 ,class 3
13,Klaas
14,8
The writing program
The message-writing-program retrieves from the message model table the model of the message to be drafted. The program reads one by one the serial numbers with corresponding PMS element numbers from the model. On the basis of the PMS element number the own connecting table is searched to retrieve the corresponding value in the own application/flle/fleld. The retrieved value, preceded by the field serial number froτi the mess¬ age model, is placed in the message. As soon as the message is drafted the message is ready to be transmitted.
The reading program
After receiving the message the message reading program is start¬ ed. The message reading program retrieves a model of the received mes¬ sage from the message model table. The program reads one after the other the serial numbers with the succeeding values from the message. By con¬ sulting the message model for each serial number the corresponding PMS- element number can be found. With the PMS-ele ent number the own con¬ necting table van be searched to retrieve the own application/f le/field in which the corresponding value should be inserted. The received value is input in the respective field. After processing the message the pro¬ gram is fmnished.