home *** CD-ROM | disk | FTP | other *** search
- PC-COMMA Version 1.0
- April 21, 1987
- Fred Willshaw Software (c) 1987
-
- Fred Willshaw
- P.O. Box 32414
- Charlotte, NC 28232
-
- CIS 73075,321
-
- PC-COMMA is a utility program used to generate a comma delimited file from
- an ASCII or Direct file stored on the PC. Through the use of a control file,
- hereafter called a profile, the program outputs a file in comma delimited
- format for importation into other software. This program is useful in
- creating input for 1-2-3, Paradox, PC/Datacom, Ideal Escort, etc. An
- example would be to creating a report print file (PRN) in 1-2-3 and then use
- this program to create a data file for another program from the PRN file.
-
- The PROFILE Structure
- ---------------------
-
- The Profile which describes the input and output files is constructed using
- the following formats:
-
- PROFILE KEY PROFILE BODY DESCRIPTION REQUIRED/
- cc 1-3 cc 4-80 DEFAULT
- ----------- -------------------------------------------------------- ---------
- DSN |cc 4-42 Drive\Path\DSN of the input file |Yes/None
- |cc 43-80 Drive\Path\DSN of the output file |
- | |
- |EX: DSNC:\TEST1\TEST2\FILEA.DAT DSNA:FILEA.CMA |
- | DSNC:\TEST1\TEST2\FILEB.DAT DSNC:\TEST3\FILEB.CMA|
- | |
- |note: you may have up to as many as 50 files which will |
- | be processed under the same format specifications |
- | in the group (see the GO command) |
- | |
- INP |cc 4-6 Indicates input file type where ASCII files are |No/ASC
- | indicated with ASC and direct files DIR |
- | |
- |EX: INPDIR |
- | |
- HDR |No additional input required - this card causes PC-COMMA|No/No
- |to produce the first output record with labels created |
- |from the field label section of the FLD card described |
- |later. This is useful when building files for such |
- |programs as PC/Datacom |
- | |
- LRL |cc 4-6 Indicates the length of the input records which |No (for
- | to be processed. For ASCII files this is |ASCII)
- | useful in extracting specific records. For DIR |Yes (for
- | files it is required in order for the program |DIR)/
- | to read and process the input file |Actual
- | |length
- | |for ASC
- | |
- |EX: LRL095 |
- | |
- SKP |cc 4-6 Indicates the number of records to be bypassed |No/None
- | when first reading the input file. Used for |
- | such instances as dropping header records, etc. |
- | |
- |EX: SKP005 |
- | |
- DRP |cc 4-80 Causes records which include the search field |No/None
- | in 4-80 to be bypassed. You may have up to |
- | 200 DRP entries for each execution group (see |
- | the GO command) |
- | |
- |EX: DRPRALPH NADER |
- | |
- CHG |cc 4-80 Indicates global search and replace values |No/None
- | which are separated by a tilde (~). You may |
- | have up to 200 CHG entries for each execution |
- | group (see the GO command). |
- | |
- |EX: CHG~LOSER ~WINNER~ |
- | |
- ZRO |No additional input required - indicates whether |No/blank
- |numeric output fields are output as blank or 0. If |
- |this card is present then the output will be 0, if not |
- |then a blank will be output |
- | |
- |EX: ZRO |
- | |
- DLM |CC 4 Indicates the delimiter character to be used |No/,
- | if something other than the default comma |
- | is used. If entered and you want the delimiter|
- | to be a blank enter a blank, it will be |
- | interpreted properly |
- | |
- |EX: DLM# |
- | |
- FLD |cc 4 Indicates field type for output, C for |Yes/None
- | character which will be enclosed with quotes |
- | or N for numeric which will not be enclosed |
- |cc 5-7 Indicates the input record starting position |
- | for this field |
- |cc 8-10 Indicates the length of the field in both the |
- | input and output record for this field |
- |cc 11 Indicates with a Y or an N if the field is to |
- | have leading and trailing blanks removed |
- |cc 12-80 Label to be used in conjunction with the HDR |
- | card described above |
- | |
- |EX: FLDC001025YLABEL 1 |
- | FLDN026007NLABEL 2 |
- | |
- | note: you may have up to 200 FLD cards per |
- | group (see GO command) |
- | |
- GO |Tells the program to execute all of the Profile commands|Yes/None
- |processed to this point and then clear all internal |
- |arrays and try to read another set. If no more sets |
- |are found the program returns to DOS. The program does |
- |NOT process the input and output file commands until |
- |the GO card is encountered. You must have at least one |
- |GO card, as you can see it must also come at the end of |
- |any group of command cards which describe a different |
- |file input or output structure. |
- | |
- |EX: GO |
-
- EXECUTING PC-COMMA
- ------------------
-
- In order to execute PC-COMMA simply enter the DOS command PC-COMMA. You
- will then be asked to supply the Profile dataset name containing the control
- cards described above. If you do not supply a dataset name and depress
- ENTER the program will search for the default profile dataset PC-COMMA.PRO.
- From there on the program will run without intervention. Should you desire
- to abort the program depress the ESC key.
-
- Included in this ARC file are the following modules:
-
- PC-COMMA.EXE The executable module
- PC-COMMA.DOC This file
- PC-COMMA.PRO A sample PROFILE
- SAMPLE.ASC A sample ASCII input file
- SAMPLE.DIR A sample DIRect input file
-
- In order to run the samples, enter the DOS command PC-COMMA and then depress
- ENTER when asked for the profile name. The resulting files created will be
- SAMPLE1.CMA and SAMPLE2.CMA.
-