Contents of the MM.DOC file
MM 2.4 - Mainframe Mania - 1 May 1991
A Utility to Convert Mainframe Data
Handles zoned decimals, overpunch, and trailing signs.
(c) 1987-1991 by Ken Goosens
A utility to convert downloaded mainframe numeric data to a
format that PC programs can read.
Answers to questions about MM, and the latest version, can be gotten
from the bulletin board Your Place at 703-978-6360.
HISTORY OF CHANGES
Version 2.4 - Released 1 May 1991
Speed increased when having runs of same values in the
same field. Runs slightly slower when every consecutive
value in a field in the records changes. On data with
signficant redundancy, easily get 40% in speed.
Recompiled under Professional Basic 7.1.
ZIP file renamed MFRMver rather than MMver because there were
too many conflicts for the name (Menu Master, etc.).
Version 2.3 - Released 2 March 1988
Numbers converted from scientific notation could have
trailing zeros after a decimal point. Now elminated.
Verification added that each record really does end with
the stated record delimitor. Processing halted if does
not. This check can be effectively eliminated by declaring
all characters to be data with no record delimitor. Check
applies to all but last record in the file.
Recompiled under QB 4.0.
Three bug fixes. (1) Was not converting overstriked numbers
properly when the number completely filled the field, e.g.
in a field of length 5, "1000A" would convert to "1000"
rather than to "10001", whereas "01000A" would convert
properly. (2) When running in single step mode, the
display for the number converted was not right when a
shorter number followed a longer. (3) Was truncating the least
significant digits in some cases even though there was
room in the field.
Will no longer write out real numbers in scientific notation.
Occasionally, depending on the value, MM would write out a real
number in scientific notation. For example, 2.1E-002 rather
than .021. Very few PC programs can read scientific notation.
2.1 will check whether output is in scientific format and
convert the number to a standard decimal if necessary. As
a side note, Turbo Basic is far more prone to write out in
scientific format that Microsoft QuickBasic.
Version 2.01 - Released Nov 21, 1987
Treats a blank at the end of a numeric field the same
as a plus sign when looking for a trailing sign. Some mainframe
programs in the trailing sign field will leave a blank rather than
a plus sign and only put in a negative sign. Hence "0031 " is
treated as "+0031" in version 2.01, whereas in 2.00 it is treated
as is. If you said the number had 1 decimal place, 2.00 returned
" 31" whereas 2.01 returns " 3.1". Version 2.01 thus properly
adjusts where the decimal point is added when a number with a trailing
sign has a blank for the sign.
Opening screen now shows format for invoking MM from DOS.
Individuals as well as organizations and companies are free to use this
program, so long as nothing is charged for the program. The author
does not ask for any payment for its use. However, you are not free to
use this program to make money, nor to sell the program, nor to base
a commercial program on it, without the explicit consent of the author.
FILE THAT SHOULD COME WITH THIS PROGRAM
MM.BAS - QuickBasic source code
MM.EXE - Compiled, executable program
MM.DOC - this documentation
MM.ZON - sample mainframe file to be converted
CONV.TBL - specifics on how to read and convert mainframe data in MM.ZON
WHAT DOES MM DO?
This is a routine whose only purpose is to take mainframe data and
convert it to a form that PC's can process. There are three persistent
problems it solves:
o mainframe is often stored with assumed decimal points ("zoned"
o mainframe data is often stored with the sign as an "overstrike"
on the last character.
o signs are often stored as a trailing character after the number
rather than in front of the number.
These problems are both combined when mainframe data is generated in
COBOL using signed numeric pictures where the sign is not a leading
separate. For example, in the picture S99V9(4) the S produces an
"overpunch" on the last character, in which (going) back to card
decks) the sign is "overpunced" over the numeric digit and the digits
are not stored with a decimal point (the V is where is implied
Very few databases on PC's will properly interprete such "zoned" decimals
and virtually none will handle the overstrike (it will appear to be
non-numeric) or trailing sign.
What usually happens with zoned data is that divided by a power of
ten to shift the decimal over, but there is no solution to the latter
MM will handle zoned decimals, overpunches, and trailing signs, converting
the data to a format virtually all data bases on PC's can interprete. MM
assumes that you already have the mainframe data on your PC as ascii text
and simply want to convert it to a format other PC programs can process.
HOW DOES MM WORK?
MM works by passing it necessary parameters in the DOS command line.
The format is
MM[/] [file to edit] [output file] [conversion table]
are either nothing or B (for BATCH, default is non-batch),
or T (for TEST, default are non-test).
is the name of the mainframe data file. Default is