dBMAN Tutorials #1 in a Series General/Bug Report by John C. Leon August 20, 1986 distributed through the H.A.S.T.E. BBS Houston Atari ST Enthusiasts 713-955-9532 permission granted to distribute unaltered original text There are precious few serious databases on the market at present for the Atari ST. The majors are dBMAN, the Manager, and Zoomracks. H&D Base is a dead horse, as Mirage has appparently gone out of business. Others will come. This series of articles concentrates on what appears to this writer to be the single most versatile and powerful program, dBMAN by Versasoft (versions 2.00L and 2.02L are included in all remarks, with known differences pointed out). We assume you have a working knowledge of relational databases, and have made some effort to use the product. For those who have never used a dBMAN or dBASE type of command-driven relational database, I urge you to buy a book or two on dBASE programming before tackling any heavy-duty work with dBMAN. The two products are very similar, but far from directly compatible, despite consistent claims by reviewers and any ads you may see. Compatibility between dBMAN and dBASE extends only to the ability to use the CONVERT command in dBMAN to convert a dBASE data file to dBMAN format. Command files (programs) written in dBASE will not run in dBMAN without modification. The syntax of the two languages is different, and there exist commands in each language that do not exist in the other. Suffice it to say that the commands are similar enough to make the porting of programs relatively easy. The dBMAN documentation is pretty stiff. It is packaged in an attractive slipcase and three-ring binder, containing logical sections: basic, advance, reference, commands, functions, appendices and index. However, the level of detail leaves a lot to be desired. You are often merely presented a brief description of a command or function with no explanation of its power or usefulness. The SET RELATION TO command is incredibly powerful, but it receives the briefest of treatment (two pages - long by Versasoft's standards!) and no hint is given on when it would be useful. Versasoft seems to assume that users of the product already have a great deal of savvy on power programming of relational databases. I would define their entire manual as a technical reference piece. dBMAN Tutorials - 1 - Gene - 1 - An Initial Review sales file. The linking element between the files is the customer number. This is the stuff of relational databases, where you normalize your data to eliminate redundancies, and relate files easily for total freedom in data manipulation. The second distinction that any relational database has over file managers is its PROGRAMMABILITY. The more complex applications you may wish to design would require typing numerous commands at the keyboard to accomplish even the simplest tasks. These same commands can be programmed, saved in a COMMAND file, to automate such tasks. Think of such programs as super macros, where the computer executes your stored commands in sequences you design, to facilitate the running of your system. Many people make a living out of designing turnkey database systems for business (offices, banks, stores, etc). In fact, these database languages are so refined that they actually belong in a legitimate class of their own as programming languages! With the utilities around these days, you could use any text editor to write a dBASE system, compile it, and have it run as a separate stand-alone package, without ever even having owned the actual database itself! There are no dBMAN compilers per se, but you do use an outside editor to compose programs, and can run your programs with the runtime package available separately from Versasoft. In other words, you can supply dBMAN custom programs to be run under the runtime package. Your customers do not have to own dBMAN! The IBM version of dBMAN sells for $295. The ST version lists for $149.95. It is identical to the IBM version. This is a very fair price in my opinion. I would not hesitate to recommend dBMAN to anyone wanting an incredibly useful tool for data management. The product itself is delivered on two single-sided disks, unprotected. One disk is the dBMAN interpreter itself with related files. The other is a snappy little tutorial disk, that gets you going with the rudiments of using dBMAN. The tutorial disk also includes some sample dBMAN command files for mailing list management. I ignored them in favor of writing my own for the sake of flexibility, and as an exercise, but they will give you the flavor of programming. By all means, print out the command files on this tutorial disk. Read through them. Study the processes and logic involved. This is a great way to learn! The dBMAN package is an attractive grey slipcase, inside which is the hardcover 3-ring binder holding the documentation. Ah, the documentation. It's not the best. I found it sketchy on details regarding command syntax. This product is definitely not dBASE compatible, I assure you, though everywhere you read that it is. You can use a dBMAN command to CONVERT a dBASE data file to dBMAN format, but the programming languages are SIMILAR, not compatible. For example, in dBASE, the command to delete a dBMAN by Versasoft - 2 - An Initial Review file is "ERASE". In dBMAN, the "ERASE" command merely clears the screen! There are numerous other differences in the language, but they are similar enough so that you would benefit from buying a dBASE III programming book at a bookstore and studying it a little to get the hang of things. If you are a novice, you will not be able to dive into dBMAN programming without a substantial investment in man-hours spent deciphering the documentation. Although the manual is accurate, it is not as complete as it could be, and does not have the best organization. I remember looking hard to find the operator that would allow me to chain a command line over more than one line. It was buried in a section of the manual titled "File Types"!!! There is no "LABEL" command. This means that you will have to write your own label maker programs. Label programs are among the simplest to write, so this is no big loss in my view. There is no text editor built into the product. Please note that using the product from command level does not require an editor. You simply enter commands one after the other. It's the programming that requires an outside editor. This can mean constant loading of your editor, then dBMAN, exiting, re-loading your editor, composing code, re-loading dBMAN, etc. I use a simple technique to simplify things. On my 1-meg 520ST I create a 550K ramdisk with Solapak, copy the editor files and DBMAN.TTP to the ramdisk with Solapak's COPY2RAM program, and work out of the ramdisk. My data and program files are on a floppy. Switching between dBMAN and an editor is a breeze when done at the speed of a ramdisk. Be careful in your choice of an editor. It must be capable of producing pure ASCII files. I used Final Word exclusively until I started using "procedures" in my programs. There was never any prior indication of trouble, but using the SET PROCEDURE TO command in any command files created with the Final Word caused dBMAN to crash to the desktop. This problem gave me countless hours of grief until, on a lark, I loaded my procedure file into Regent Word. Lo and behold, the last byte in the file appeared on my screen as a non-ASCII character. When I had called Versasoft for help, one of the questions they had asked me was if I was certain the file contained only ASCII characters. When you save a Final Word file, it puts an odd character (a non-ASCII character) at its end as an end-of-file marker. This is all it took to bomb my dBMAN programs. It was a hard problem to troubleshoot, as that darn non-ASCII character does not appear on your screen in the Final Word. I now use another editor for dBMAN programming. Remember one command above all others: SET TALK OFF. If you run a program and don't include that statement, each line of your code will be reflected onscreen in the command line (a reserved area at the top of the screen). This can be a help in the debugging stages, but slows down execution to a snail's dBMAN by Versasoft - 3 - An Initial Review pace. My club membership list program runs in seconds with talk off, but with talk on it can take 15 minutes! The "@SAY--GET" commands don't permit a "RANGE" clause, leaving it up to you to hack data input v