uvhd free download

'uvhd' is a FREE download from UV Software, see link at bottom.

It 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 Unix/Linux/Windows system utilities. uvhd is an easy-to-use interactive utility with 25 help screens documenting commands (browse, search, update, select, drop, print, translate, scan/replace, count records, accumulate fields, sequence number, sequence check, 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.

uvhd displays any file-type

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. Part 5 of the documentation (see link at bottom) describes the various file types commonly used on Unix/Linux/Windows systems by applications that have been transferred from a mainframe.

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

uvhd sample display EBCDIC file

 uvhd dat1/custmas0 r256s2a  <-- display EBCDIC demo file, using option 'a'
 ==========================      to translate the character lines to ASCII
 rec#=1 rsize=256 fptr=0 fsize=8192 rcount=32
                  10        20        30        40        50        60
 r#    1 0123456789012345678901234567890123456789012345678901234567890123
       0 130140    EVERGREEN MOTORS LTD.    1815 BOWEN ROAD          NANA
      64 IMO          BC V9S1H1    250-754-5531 LARRY WRENCH     ...V@...
     128 .........W.....-.........X'..f.....m*..................V'...f...
     192 .E@...V'........c..............f..............f.C 19950531

Notes re uvhd EBCDIC file display

  1. This is one of the many demo files used to illustrate Vancouver Utilities. 'custmas0' is the EBCDIC version vs 'custmas1' the ASCII version which can also be seen in the uvhd documentation (see link at bottom).

  2. Note the options 'r256s2a'. Option 'r' (r256) defines the Record-size as 256, Option 's' (s2) space 2 inserts a blank line between the 3 line groups of the vertical hexadecimal display (characters, zones,& digits).

  3. Especially note option 'a' which translates the character line to Ascii so we can read character fields of EBCDIC files on unix/linux machines.

  4. Mainframers will easily recognize the EBCDIC vertical hex zone/digit codes. For example the 1st character above is '1' which is x'F1' in horizontal hex & you can see the zone/digit F/1 on the zones & digits lines below. The letter 'E' (of EVERGREEN MOTORS) in EBCDIC is x'C5' (zone 'C' & digit '5').

    Packed Decimal fields

  5. Note that there are 24 * 5 byte packed fields in bytes 120-240 (monthly sales for this-year & last-year). Each 3 line vertical hex group displays 64 bytes, so byte 120 is 56 bytes into the 2nd row. In horizontal hex the 1st packed field is x'001234567C' which is $12,345.67.

  6. You can easily identify the end of each 5 byte packed field by the sign, x'_C' (positive) or x'_D' (negative).

  7. The characters above the packed fields are meaningless/coincidental results of displaying packed field digits as characters. x'001234567C' just happens to display as '...V@' since any non-displayable character is shown as a '.', x'56' is a 'V' in ASCII,& x'7C' is a '@' in ASCII.

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

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
                10        20        30        40        50        60
 r#  2 0123456789012345678901234567890123456789012345678901234567890123
     0 .D..HP0010 P  20100215  INV00020  000350000 HP XW 9400 Workstati
    64 on..
 rec#=2 rsize=68 rcount=7 fsize=513 fptr=62

Notes re uvhd display ASCII RDW file

  1. Above shows the first 2 records of 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.

  2. uvhd shows the record-size below the hexdump - see 'rsize=62' under 1st and 'rsize=68' under 2nd. These decimal values have been converted from the binary record prefixes.

  3. The binary rec-size of 1st record is x'003E' = 3*16+14 = 48+14 = 62 The binary rec-size of 2nd record is x'0044' = 4*16+04 = 64+04 = 68

  4. RDW files are commonly used to FTP variable length files from mainframes to Unix/Linux/Windows. Binary mode is required to preserve the record prefixes so the files would still be EBCDIC (vs ASCII shown here).

  5. The data in RDW files starts in the 5th byte (byte 4 zero relative). See 'DELL10' in the 1st record above. The vertical hex display shows the ASCII codes for the zones & digits on the 2 lines below the character line. In horizontal hex these are x'44454C4C3130'. In an EBCDIC file these would be x'C4C5D3D3F1F0'.

  6. You could use uvhd's write command with option 'ta' to translate the data portion to ASCII preserving the binary prefixes. And you could use other options to write out an all text file dropping prefixes & inserting LineFeeds after the last non-blank. Or you could write fixed length records with blank padding to a specified record-size.

  7. The records above are terminated with Carriage-Return + Line-Feed (CR+LF). The CR/LF terminators are redundant here since the RDW record prefixes defines the record size in binary. I wanted to illustrate both RDW and Text file terminators in 1 example. Record terminators are often a problem in FTP transfers since they are not shown by the usual unix/linux editors.

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

uvhdcob = uvhd + 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.

Links to more information

 http://www.uvsoftware.ca                 - UV Software Home Page
 http://www.uvsoftware.ca/libuvhd.htm     - download uvhd (free)
 http://www.uvsoftware.ca/uvhd.htm        - full documentation for uvhd
 http://www.uvsoftware.ca/uvhd.htm#Part_5 - uvhd tutorials for various filetypes
 http://www.uvsoftware.ca/uvhdcob.htm     - full documentation for uvhdcob
 http://www.uvsoftware.ca/uvintro.htm#G1  - customer list & reference letters
 http://www.uvsoftware.ca/uvprices.htm    - prices & partner agreements
 http://www.uvsoftware.ca/jclcnv1demo.htm - JCL Conversion to Unix/Linux scripts
 http://www.uvsoftware.ca/jclcnv2real.htm - instructions for your conversion vs demos
 http://www.uvsoftware.ca/datacnv1.htm     - DATA conversion pr
 http://www.uvsoftware.ca/uvsort.htm      - uvsort (replaces DFSORT/SYNCSORT)
 http://www.uvsoftware.ca/news/           - 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 owen@uvsoftware.ca, www.uvsoftware.ca

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