Rapid random record retrieval. (evaluation) C.A. Johnson.
Practically everyone has a need for a good indexing program with efficient random searching capabilities at one time or another. There have been many times when I had a desperate requirement for such a program but did not have the time to write the program myself. My solution had been to build a text file with my word processing program and do my search and retrieval with the FIND command. It worked, but the limitations were severe, and it generally required that the data be entered manually from the keyboard.
When I encountered Newtrieve recently, I had mixed emotions. I was overjoyed that such a program was available and at the same time, skeptical of its flexibility. I now have several applications using it and I am just overjoyed.
Newtrieve is delivered on a single, 35-track disk, with no operating system. It consists of the demonstration program, NT/DEM; an enhancement subprogram, ENHAN/BAS; and two indexes, INDEXA/LM and INDEXB/LM. The hardware specified is a 48K TRS-80 Model I or III with one disk drive. The manual makes the point that two drives greatly expand the capability of the program, but it does not tell you how to copy the programs onto a disk with an operating system if you are using TRSDOS and one drive.
Minor modifications must be made to the demonstration program to make it compatible with the operating systems for Model I TRSDOS, Model III TRSDOS, or NEWDOS/80.
All of the statements needed are already in the program, but are REM statements. The proper statements are made active by editing out the REM portion of those statements.
Although it does not purport to do everything, Newtrieve is an indexing algorithm with sufficient flexibility to enable it to handle a multitude of different applications.
As delivered, Newtrieve consists of two parts, the index and a Basic demonstration program which references the index by USR routines. The index provided is preformatted to 500 strings of 40 characters each. Other indexes are available from the manufacturer.
To get the most from the package, you need a knowledge of one of the operating systems and Basic programming. Newtrieve is designed as a programming tool, making it the basis of program development, but it can be used as delivered. The demonstration program is menu driven, but does not demonstrate the full capability of Newtrieve. The use of alternate indexes and alternate Basic programs is not included in the demonstration program. However, the documentation describes their use and gives some clues for expanding the system accordingly.
Included is a subprogram to enhance the demonstration program. The enhancement adds the ability to add a new search string immediately if a match is not found and to add data into the key string to further limit the search. It appears that the enhancement program was not included as much for actual enhancement as to provide an example for those who wish to make modifications of their own. Using The Indexes
Indexes can be created interactively, from the keyboard, or loaded from an existing data file, using a modification of one of the subroutines included in the demonstration program.
Once an index has been created, it may be modified by selecting the line to be changed and entering the new data.
Searching the index is both simple and rapid. Enter the string or a subset of the string (key string) and Newtrieve will display all strings which contain the key entered. For example, STE will locate occurrences of SYSTEM, MASTER, and STERILE. By your choice it will display all occurrences at once, the first occurrence, or, if you have added the program which enhances the demonstration, one at a time as you press the ENTER key. Searching the entire index of 20,000 characters takes about one second.
If a search string returns too many data entries, it can be further limited with the Exclude feature. Entering E sets the exclusion flag and causes the program to request a string to be used to exclude strings. For example, STE with the exclusion of MA would return SYSTEM and STERILE in the example above, excluding MASTER.
Another feature provided is the ability to "browse" through the index. You may start at any index entry and browse in either direction, stop when you wish, change direction, continue, or return to the menu.
Included in the menu is the option to divide the index into two equal parts. Either half may then be searched individually. This is a nice feature which allows the inclusion of two short indexes or of two indexes which may be conceptually linked, as in an inventory system in which the first part of the index might be used to determine the part number from a description and the second part of the index to provide the number of items on hand, minimum quantity before ordering, wholesale cost, and retail price.
The program is exited by entering a 0. If any changes have been made to the index being used, the program reminds you and asks if you wish to save the index. If you do, you select the proper option and the program branches to the "dump" routine. The one thing I found in Newtrieve which did not work on my machine was the "dump" routine. However, keying a suggested sequence under DOS accomplished a successful copy of the new index to replace the old one.
The documentation is, in general, very well done. The beginner may find much of it a bit too technical, but he will find enough that he can use immediately that he will probably not feel left out. As he gains experience with his computer, operating system, and Basic programming, he will appreciate the ability to use Newtrieve to expand his use of his system. Spelling Errors
I do not understand why a software publisher will strive to produce a quality program and not take the time or trouble to eliminate spelling errors. The Newtrieve documentation has quite a few such errors, both in its internal documentation and in the printed manual. Such carelessness makes me uneasy with the program until I have satisfied myself that the same carelessness does not permeate the program as well.
I have not as yet pushed Newtrieve to the limit of its capability, but I am impressed with what I have seen and I have several more applications already planned for it. It is definitely an innovative concept worthy of extensive exploration.
Products: Unique Printing and Stationery Newtrieve (computer program)