Vancouver Utilities Summary

The Vancouver Utilities are best known for migrating mainframe applications to Linux/Unix/Windows applications - converting JCL to shell scripts, mainframe COBOL to Micro Focus or AIX COBOL, EBCDIC data to ASCII data preserving packed.

This news letter will describe the usefulness of the Vancouver Utilities for sites that have already converted their mainframe applications or for any site that needs to work with mainframe file types on LUW systems

Please read the summary for each of these utilities and then use the links at the bottom of this newsletter to investigate items that are of interest to you.


'uvsort' provides mainframe sorting capability to Linux/Unix/Windows systems. The unix system sort is totally unsatisfactory for mainframe file types (migrated to LUW systems) because:

  1. unix sort cannot sort fixed length record files without LineFeeds
  2. unix sort cannot sort on packed decimal fields
  3. unix sort cannot sort Indexed files (Micro Focus compatible)
  4. unix sort does not have select/delete/reformat capabilities (uvsort has capabilities comparable to mainframe DFSORT or SYNCSORT).

uvsort provides for 600 record selects/deletes for input time & a further 600 record selects/deletes for output time. These select/deletes may be based on multiple and/or conditions comparing record fields to constants. uvsort also provides for 600 instructions for reformatting records at both input time & output time (move,add,subtract,multiply,compare,skip,etc).

uvsort allows 20 input files, 60 output files. Actually the number of files is unlimited using the option to input all files in a directory (or all files matching a pattern using '*' wildcard. There is also an option to output a new file on a control break in the sort key.

uvsort example

 uvsort "fili1=dat1/sales2,rcs=64,typ=RST,filo1=tmp/s2,key1=30(6),sel1=10(2):21"
 - sort sales2 demo file by product#, selecting only salesman #21
 - output 'typ=RSF' Record Sequential Fixed, recsize=64, no linefeed
 - could specify 'typ=RST' to force Linefeed into the last 64th byte
 - 'key1=30(6)' is product# in bytes 30-35 (zero relative) columns 31-36 (one relative)
 - see many more examples using the uvsort link at the bottom of this email

Goto:   Begin this document End this document UVSI Home-Page


'uvhd' is a FREE download from UV Software, see link at bottom. uvhd is a file investigation utility that displays records in vertical hexadecimal. uvhd is especially useful for files with packed/binary fields &/or that do not have the LineFeeds required by most Linux/Unix/Windows system utilities. uvhd is an easy-to-use interactive utility with 25 help screens documenting commands (browse, search, update, select, print, translate, etc).

uvhd can help diagnose problems with data file conversions & FTP transfers because it shows the hexadecimal values of packed/binary fields, record headers, & record terminators. These fields can not be shown by the usual unix editors.

By default uvhd will display any file in vertical hexadecimal in chunks of 256 bytes. uvhd will display discrete records when you specify the option for the several known file-types, which are:

uvhd sample display ASCII variable length RDW file

 uvhd dat1/vendorpay3 z4    <-- investigate vendorpay3 file
 =======================      - option 'z4' for file-type RDW
                10        20        30        40        50        60
 r#  1 0123456789012345678901234567890123456789012345678901234567890123
     0 .>..DELL10 P  20100131  INV00010  000195000 Dell server 2900..
 rec#=1 rsize=62 rcount=8 fsize=513 fptr=0

This is the 1st record of demo file vendorpay3. Option 'z4' tells uvhd that this is an RDW file (variable length with rec-size in 1st 2 bytes binary). Third & fourth bytes are nulls & data begins in the 5th byte.

uvhd shows the decimal record-size as 'rsize=62', which has been converted from the binary size in the prefix. The 1st 2 bytes in horizontal hex are x'003E' = 3*16+14 = 48+14 = 62.

Goto:   Begin this document End this document UVSI Home-Page

uvhdcob - shows data with COBOL copybook fieldnames

'uvhdcob' is similar to uvhd, but also displays the COBOL copybook fieldnames beside the data file field contents. Here is a sample display, showing copybook fieldnames on left, start/end bytes in center,& data contents on right:

 uvhdcob dat1/vendorpay3 cobol/maps/vendorpay z4  <-- sample command
 record#    1                 start end typ<------ data ----->
 001 venpay-num                   0   5    DELL10
 002 venpay-type                  6   9     P
 003 venpay-date                 10  19    20100131
 004 venpay-inv                  20  29    INV00010
 005 venpay-amt                  30  38 n  000195000
 006 venpay-item                 40  63    Dell server 2900
 rec#=1 rcount=8 rsize=60 fsize=496 fptr=0
 c=chkseq#,t=tally,q=quit,?=help -->

The command line above specifies both the data-file, copybook-file,& file-type. You can specify data-file-name only if you set up a control file to relate the data-file-name to the copybook-file-name.

Goto:   Begin this document End this document UVSI Home-Page


'uvlist' is a file print utility with many options for laser printers (font, cpi, lpi, margins, Portrait/Landscape, Simplex/Duplex, page restart, etc).

It is especially valuable for mainframe conversions to Linux/Unix/Windows. You can print the 132 column reports on 8.5 by 11 paper Landscape & Duplex. Options to begin & end on specified page#s are particularly useful.

I think you will find it useful for listing programs,scripts,documentation,etc. The page headings always show you the filename, date/time, userid, and page#. uvlist solves the frustration of not knowing these essential items.


'uvcopy' is essential to running mainframe applications on Linux/Unix/Windows systems, because it can do many things not possible with the standard LUW utilities such as: processing 'packed decimal' fields, files without LineFeeds, 'Indexed files' (compatible with Micro Focus COBOL),& field addressing by column# (common in mainframe utilities, but not in unix utilities).

uvcopy is a general purpose (can do anything) data file manipulation utility. It gives you the power of assembler without the complexity. uvcopy understands mainframe concepts and can replace the data file maintenance of mainframe utilities such as IEBGENER,IDCAMS,FILEAID,EASYTRIEVE,QUIKJOB,etc.

uvcopy is the ultimate in power and flexibility. You can do whatever kind of data transformations & translations are required, no matter how complex. A good example is converting mainframe data files to Linux/Unix/Windows. COBOL copybooks are used to automatically generate the uvcopy instructions to translate character fields from EBCDIC to ASCII, and preserve the packed/binary fields.

Goto:   Begin this document End this document UVSI Home-Page

Pre-Programmed uvcopy jobs

There are over 500 pre-programmed jobs for the uvcopy interpreter. This interpretive code is easily modified & customized in case the original job does not meet your precise needs. Many jobs would be useful to any Unix site.

For example 'cobmap1' will create a record layout from a COBOL copybook, adding field start, end, length,& type on the right side.

 uvcopy cobmap1,fili1=cpys/armaster.cpy,filo1=maps/armaster.cpy
 maps/armaster                                     RCSZ=00256  bgn  end  lth typ
 * armaster - cobol copy book for custmas1 file
      10 cm-num           pic  9(10).                         0000 0009  009 n  6
      10 cm-name          pic  x(25).                         0010 0034  025
      10 cm-adrs          pic  x(25).                         0035 0059  025
      10 cm-city          pic  x(16).                         0060 0075  016
      10 cm-prov          pic  x(2).                          0077 0078  002
      10 cm-thisyr-sales  pic  s9(7)v99 comp-3 occurs 12.     0120 0124  005pns 9
      10 cm-lastyr-sales  pic  s9(7)v99 comp-3 occurs 12.     0180 0184  005pns 9

Cross References

There are several pre-programmed jobs to create cross references for COBOL programs, copybooks, MVS JCL, VSE JCL, and the Korn shell scripts converted from MVS/VSE JCL. See more at Here are the 3 most useful of 15 available & a sample of the copybook crossref.

  • show all PROGRAMs calling each CALLED-PROGRAM
  • show all PROGRAMs copying each COPYBOOK
  • show all JCL/SCRIPTs executing each PROGRAM

  xcobcopy2 ** crossref all PROGRAMS using each COPYBOOK **
  custmas.cpy_2    car100.cbl      car200.cbl
  saledtl.cpy      car200.cbl
  sdline.cpy       car200.cbl


'table2' is a pre-programmed job to create table summary reports based on any one argument field in your file & accumulating up to six specified quantity or amount fields with automatic record counts. Here is a sample report:

 sltbl2 2008/03/30_10:07:45 sales analysis by slsmn#/product# of qty & amount
 tbl#001 pg#001     -argument-       acum#1   %        acum#2      %
 line#  count    %   product#        sale qty           sale amt
     1       1  11   BIT001            90    19        8,100.00    28
     2       4  44   HAM001           180    39       10,900.00    38
     3       2  22   SAW012            90    19        5,300.00    18
     4       2  22   TAB013            92    20        4,100.00    14
             9*100   *TOTAL*          452  *100       28,400.00  *100

Note that it only takes 1 instruction (tbl) to build the table in memory & 1 instruction to dump the table at End Of File. The entire job is only 12 instructions.

Goto:   Begin this document End this document UVSI Home-Page

links to more information                 - UV Software Home Page      - uvsort documentation        - uvhd file investigation utility     - shows copybook fieldnames with data     - download uvhd FREE utility      - uvlist print utility     - uvcopy data utility functions     - uvcopy data manipulation instructions     - uvcopy pre-programmed jobs - JCL Conversion to scripts - instructions for your conversion vs demos    - DATA conversion preserving packed    - prices & partner agreements  - customer list & reference letters           - all newsletters past & present

I invite your feedback. Let me know if these news letters are useful to you, and any suggestions you may have for improvements.

Thank You, Owen Townsend, UV Software Inc.

Goto:   Begin this document End this document UVSI Home-Page