Abstract:
A method for updating a document by means of appending an updated file to the document comprises the steps of reading an original document; initializing the original document to have a name and an index number for correspondingly identifying the original document; opening the updated file; establishing a name for correspondingly identifying the updated file; and appending the updated file to the original document to form an updated document. By utilizing the method, the file size and the download time of the updated document are reduced, as well as enabling a user to easily carry out a query to documents with different versions and a switching between them.

Description:
FIELD OF THE INVENTION 
     The present invention relates to a method for updating a document, and more particularly to a method for updating a document by means of appending new materials to an old version document. 
     BACKGROUND OF THE INVENTION 
     Typically, there are two techniques employed to obtain updated information, namely 1) by mail, i.e., information provider mails a diskette or CD comprising the updated information to a user, or 2) by accessing information through Internet. Information retrieved by both techniques are stored in an updated document comprising the updated information and information stored in the old document. Then, the updated document replaces the old document in the next data update. 
     Both techniques are easy to implement. However, the updated document size tends to become larger as the update version becomes newer. Further, the download time for such updated document is going to become longer as the file size grows. As a result, a user may cost more on retrieving information through Internet as well as have to use a larger capacity disk to store the growing file. Additionally, it is impossible to implement the document updating and the identification of the old and new versions automatically. To the worse, the determination between different versions is difficult and time consuming. 
     Thus, it is desirable to provide an improved document updating method to overcome the above drawbacks of prior art. 
     SUMMARY OF THE INVENTION 
     It is an object of the present invention to provide a method for updating a document by means of appending for reducing the file size of an updated document as well as reducing the time to download the updated document through Internet. 
     It is another object of the present invention to provide a method for updating a document by means of appending for enabling a user to easily carry out a query to documents with different versions and a switching between them. 
     The advantages of the present invention are realized by providing a method for updating a document by means of appending new materials to an old version document. The method comprises the steps of reading an old version original document; initializing the original document to have a name and an index number for correspondingly identifying the original document; opening an updated file consisting of a new file; establishing a name for correspondingly identifying the updated file; and appending the updated file to the original document to form an updated document. 
    
    
     The above and other objects, features and advantages of the present invention will become apparent from the following detailed description taken with the accompanying drawings. 
     BRIEF DESCRIPTION OF THE DRAWINGS 
     FIG. 1A schematically illustrates the updating of a document of the present invention; 
     FIG. 1B schematically illustrates the relationship of a document with respect to its corresponding index number; 
     FIG. 2 is a flowchart illustrating how to initialize an original document of the present invention; 
     FIG. 3 is a flowchart illustrating how to produce an updated document of the present invention; 
     FIG. 3A is a flowchart illustrating the identification of an updated document of the present invention; 
     FIG. 4 is a flowchart illustrating the switching between two documents with different versions in accordance with the present invention; 
     FIG. 5 is a flowchart illustrating the reading of an index document of FIG. 4; 
     FIG. 6 is a graph schematically illustrating the implementation of the present invention; 
     FIG. 6A schematically illustrates a first embodiment of the present invention; 
     FIG. 6B schematically illustrates a second embodiment of the present invention; and 
     FIG. 6C schematically illustrates a third embodiment of the present invention. 
    
    
     DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS 
     Referring to FIGS. 1A and 1B, the following steps need to be performed during an old version original document (e.g., S 0 ) provided by an application program developer being updated to an updated version document (e.g., S 1 ): 
     First, read the old version original document by the developer&#39;s computer. Second, initialize the original document (S 0 ) for generating an index number (e.g., zero). Then, open an updated document (S 1 ) comprising a new file (i.e., the generated document (δ 0 . 1 )) not included in the original document (S 0 ). Then, transfer the updated document (S 1 ) through Internet to the users&#39; computers each having the old version document. It is apparent to persons skilled in the art that the updated document (S 1 ) can also be stored in a diskette and mailed to the users. Then, append the generated document (δ 0 . 1 ) to the old version original document (S 0 ) to form a new version document. At this moment, a corresponding index number (e.g., one) is established by the user&#39;s computer with respect to the combined new document (S 0 +δ 0 . 1 ). Similarly, as the developer continues to update the versions of a document for example from versions S 1  to S 2 , . . . , Sn−1 to Sn, and sequentially transfer the updated or generated documents (δ 0 . 1 , δ 1 . 2 , . . . , δn−1.n) directly to the user and append the generated documents (δ 0 . 1 , δ 1 . 2 , . . . , δn−1.n) to the latest old version document owned by the user to form a new version document, the user&#39;s computer will establish a corresponding index number (e.g., 0, 1, . . . , n) with respect to the new version document (S 0 +δ 0 . 1  . . . +δn−1. n). 
     Referring to FIG. 2, during the old version original document being updated to the new version document, the developer&#39;s computer will read and initialize the old version original document in accordance with the following steps: 
     At step  201 , initialize the old version original document for generating a name and a unique identification (“ID”) corresponding to the original document. 
     At step  202 , divide the original document into a number of sub-documents, each of the sub-documents respectively being assigned a unique ID. The computer will store the content of the sub-documents into the new version of the original document, and record the addresses of the sub-documents stored in the new version document. 
     At step  203 , a query is made as to whether the computer has stored all content of the sub-documents in the new version document. It yes, the process proceeds to step  204 . If not, the process loops back to step  202  to keep on storing. 
     A step  204 , assign all index number with respect to the new version document. 
     At step  205 , sequentially read the content of the index document comprising the IDs of the sub-documents, the addresses of the sub-documents, and the ID of the document. 
     At step  206 , a query is made as to whether the content of the index document have been completely read out. If yes, the process proceeds to step  207 . If not, the process loops back to step  205  to keep on reading. 
     At step  207 , the computer stores a predetermined name, and the name and the unique ID being read from the document into a predetermined address of a descriptive document. The descriptive document functions to store relevant document. And, set the number of times the document has been updated to one, number to one. Then end the process. 
     Referring to FIG. 3, during the old version original document being updated to the new version document, the developer&#39;s computer generates an updated document in accordance with the following steps: 
     At step  301 , open the corresponding descriptive document of the original document after initializing the original document. Then, read the times of updating (i.e., one as stated at step  207 ) and ascertain the document (i.e., the original document) corresponding to a previous index document based on index number one. 
     At step  302 , open the document corresponding to the previous index document and record it in table A. 
     At step  303 , open the descriptive document of the updated document and record the name of the index document and the index number thereof. 
     At step  304 , open the updating index document and record it in table B. 
     At step  305 , process table A and table B to obtain an updated index document and record it in table C. 
     At step  306 , sequentially output the content of the updated document recorded in table C comprising the IDs of the sub-documents, the addresses of the sub-documents, and the ID of the document. The output subsequently forms an index document. 
     At step  307 , the index number of the current document is incremented by one as the index number of the updating document. 
     At step  308 , the times of updating the original descriptive document is incremented by one as the times of the current updating. Insert the name of the updated document (in table C) into a suitable position of the document table. Insert the name of the updated document and the ID of the updated document into a suitable position of the document table. 
     At step  309 , output an updated descriptive document. 
     At step  310 , close all opened documents for accomplishing the purpose of updating document. Then end up the process. 
     In FIG. 3A, a flowchart illustrates the processing of index document (in table B) and its corresponding previous index document (in table C) for identifying an updated index document (in table C) as follows: 
     At step  3   a   1 , copy the content of table A to table C. 
     At step  3   a   2 , read the first index unit of table B. 
     At step  3   a   3 , a query is made as to whether the content of the first index unit is in table C. If yes, the process proceeds to step  3   a   4 . If not, the process proceeds to step  3   a   5 . 
     At step  3   a   4 , replace the index unit in table C with the index unit in table B. 
     At step  3   a   5 , insert the index unit in table B into table C. 
     At step  3   a   6 , a query is made as whether there is an unprocessed index unit in table B. If yes, the process loops back to step  3   a   3 . If not, the process proceeds to step  3   a   7 . 
     At step  3   a   7 , output the result to table C. Then end up the process. 
     In FIG. 4, a flowchart illustrates the processing of retrieving data from an old version document after an updated document being used as follows: 
     At step  401 , open the descriptive document of the updated document. Read the times of updating and the current index number (e.g., X). 
     At step  402 , input a new index number (e.g., Y) from the user&#39;s computer. 
     At step  403 , a query is made as to whether X is equal to Y, i.e., ascertain whether the index document being used is the current index document. If yes, the process proceeds to step  406 . If not, the process proceeds to step  404 . 
     At step  404 , a query is made as to whether index number Y is valid. If yes, the process proceeds to step  405 . If not, the process proceeds to step  406 . 
     At step  405 , set the current index number of the descriptive document as Y. 
     At step  406 , close the descriptive document. Then end up the process. 
     In FIG. 5 a flowchart illustrates the reading of an index document of FIG. 4 by the user&#39;s computer as follows: 
     At step  501 , open the descriptive document. Read the index number of the current index document (i.e., the document of the latest updated document). Ascertain the name of the current index document. 
     At step  502 , open the current index document. Read the content of the first item of the index document. 
     At step  503 , identifying a corresponding name of the index document based on the IDs of the index document. 
     At step  504 , open the corresponding document. Ascertain that the sub-documentis in the document based on the address of the sub-documentspecified by the index number. Read the sub-document. 
     At step  505 , a query is made as to whether a next index number exists in the document. If yes, i.e., end of the document has not been reached, the process loops back to step  502 . If not, i.e., end of the document has been reached, the process proceeds to step  506 . 
     At step  506 , close all documents. 
     At step  507 , the user is allowed to use information stored in the document. Then end up the process. 
     In FIG. 6, a graph schematically illustrates the implementation of the present invention. Reference is now made to the upper pat of FIG.  6 . It is assumed that an original document is created in a service center on March 1. The document is downloaded to a user&#39;s computer through the Internet and stored as a file. Now refer to the lower part of FIG.  6 . The file is updated on May 1, July 1, and November 1 and stored as file Upgrade 1 , Upgrade 2 , and Upgrade 3  respectively. These three files are also downloaded to the user&#39;s computer through the Internet. 
     In FIG. 6A, the upgrade 1  is appended automatically to the original user&#39;s file by the user&#39;s computer to form an updated file having an index number one (e.g., index 1 ) on May 1. In other words, the user can use information stored in the file of May 1 version. 
     In FIG. 6B, the Upgrade 2  is appended automatically to the original user&#39;s file and the Upgrade 1  by the user&#39;s computer to form an updated file having an index number two (e.g., Index 2 ) on July 1. In other words, the user can use information stored in the file of July 1 version. 
     In FIG. 6C, the Upgrade 3  is appended automatically to the original user&#39;s file, Upgrade 1 , and the Upgrade 2  by the user&#39;s computer to form an updated file having an index number three (e.g., Index 3 ) on November 1. In other words, the user can use information stored in the file of November 1 version. 
     In brief, a user is able to retrieve the required file by identifying the unique index number. For example, retrieve the May 1 version file by identifying the Index 1 , the July 1 version file by identifying the Index 2 , and the November 1 version file by identifying the Index 3 , and so on. It is apparent that a version auto-identification, and document update tracking is made possible in accordance with the teaching of the invention. 
     While the invention herein disclosed has been described by means of specific embodiments, numerous modifications and variations could be made thereto by those skilled in the art without departing from the scope of the invention set forth in the claims.