CBLVLRC7, File Convert
Variable Sequential to ASCII/Text
  Table of Contents  v-24.01.01 - cblvlrc7.htm 
  Introduction
  The COBOL Program
  The COBOL Copy Files
  COBOL Copy File, ASCEBCB1
  COBOL Copy File, PASSBSIO
  Summary
  Software Agreement and Disclaimer
  Downloads and Links
  Current Server or Internet Access
  Internet Access Required
  Glossary of Terms
  Contact or Feedback
  Company Overview
The SimoTime Home Page 

Table of Contents Previous Section Next Section Introduction

This document includes the COBOL source code for the program that converts a Micro Focus formatted sequential file with variable length records with the size varying from 4 to 32,760 bytes to a Micro Focus Line Sequential (or ASCII/Text) file with a maximum record size of 80 bytes.


We have made a significant effort to ensure the documents and software technologies are correct and accurate. We reserve the right to make changes without notice at any time. The function delivered in this version is based upon the enhancement requests from a specific group of users. The intent is to provide changes as the need arises and in a timeframe that is dependent upon the availability of resources.

Copyright © 1987-2025
SimoTime Technologies and Services
All Rights Reserved

Table of Contents Previous Section Next Section The COBOL Program

The following source code (CBLVLRC7.cbl) is the COBOL program that does file format conversion

       IDENTIFICATION DIVISION.
       PROGRAM-ID.    CBLVLRC7.
       AUTHOR.        SIMOTIME TECHNOLOGIES.
      *****************************************************************
      *           This program was generated by SimoZAPS              *
      *             A product of SimoTime Technologies                *
      *        Our e-mail address is: helpdesk@simotime.com           *
      *     Also, visit our Web Site at http://www.simotime.com       *
      *                                                               *
      *  Generation Date: 2004-05-11  Generation Time: 23:12:36:64    *
      *     Program Name:             Generation Mode: ASCII          *
      *                                                               *
      *                                   Record    Record     Key    *
      *  Function  Name     Organization  Format    Max-Min  Pos-Len  *
      *  INPUT     ALPHAV01 SEQUENTIAL    VARIABLE   32760            *
      *                                              00004            *
      *  OUTPUT    ALPHALS3 ASCII/CRLF    VARIABLE   00080            *
      *                                                               *
      *            Translation Mode is EBCDIC to ASCII                *
      *                                                               *
      *****************************************************************
       ENVIRONMENT DIVISION.
       INPUT-OUTPUT SECTION.
       FILE-CONTROL.
           SELECT ALPHAV01-FILE ASSIGN TO ALPHAV01
                          ORGANIZATION IS SEQUENTIAL
                           ACCESS MODE IS SEQUENTIAL
                           FILE STATUS IS ALPHAV01-STATUS.
           SELECT ALPHALS3-FILE ASSIGN TO ALPHALS3
                          ORGANIZATION IS LINE SEQUENTIAL
                           ACCESS MODE IS SEQUENTIAL
                           FILE STATUS IS ALPHALS3-STATUS.

      *****************************************************************
       DATA DIVISION.
       FILE SECTION.
       FD  ALPHAV01-FILE
           DATA RECORD    IS ALPHAV01-REC
           RECORDING MODE is V
           RECORD is VARYING in SIZE from 4 to 32760
           depending on ALPHAV01-LREC.

       01  ALPHAV01-REC.
           05  ALPHAV01-DATA-01 PIC X(32760).

       FD  ALPHALS3-FILE
           DATA RECORD    IS ALPHALS3-REC
           .
       01  ALPHALS3-REC.
           05  ALPHALS3-DATA-01 PIC X(00080).

      *****************************************************************
      * This program was created using the SYSMASK1.TXT file as input.*
      * The SYSMASK1 provides for the sequential reading of the input *
      * file and the sequential writing of the output file.           *
      * If the output file is indexed then the input file must be in  *
      * sequence by the field that will be used to provide the key    *
      * for the output file.                                          *
      * If the key field is not in sequence then refer to SYSMASK2    *
      * to provide for a random add or update of the indexed file.    *
      *****************************************************************
       WORKING-STORAGE SECTION.
       01  SIM-TITLE.
           05  T1 pic X(11) value '* CBLVLRC7 '.
           05  T2 pic X(34) value 'RSEQ-V-4-32760-E to LSEQ-V-80-A   '.
           05  T3 pic X(10) value 'v08.03.13 '.
           05  T4 pic X(24) value ' http://www.simotime.com'.
       01  SIM-COPYRIGHT.
           05  C1 pic X(11) value '* CBLVLRC7 '.
           05  C2 pic X(20) value 'Created by SimoZAPS,'.
           05  C3 pic X(20) value '  a utility package '.
           05  C4 pic X(28) value 'of   SimoTime Technologies  '.

       01  ALPHAV01-STATUS.
           05  ALPHAV01-STATUS-L     pic X.
           05  ALPHAV01-STATUS-R     pic X.
       01  ALPHAV01-EOF              pic X       value 'N'.
       01  ALPHAV01-OPEN-FLAG        pic X       value 'C'.

       01  ALPHALS3-STATUS.
           05  ALPHALS3-STATUS-L     pic X.
           05  ALPHALS3-STATUS-R     pic X.
       01  ALPHALS3-EOF              pic X       value 'N'.
       01  ALPHALS3-OPEN-FLAG        pic X       value 'C'.

      *****************************************************************
      * The following buffers are used to create a four-byte status   *
      * code that may be displayed.                                   *
      *****************************************************************
       01  IO-STATUS.
           05  IO-STAT1            pic X.
           05  IO-STAT2            pic X.
       01  IO-STATUS-04.
           05  IO-STATUS-0401      pic 9     value 0.
           05  IO-STATUS-0403      pic 999   value 0.
       01  TWO-BYTES-BINARY        pic 9(4)  BINARY.
       01  TWO-BYTES-ALPHA         redefines TWO-BYTES-BINARY.
           05  TWO-BYTES-LEFT      pic X.
           05  TWO-BYTES-RIGHT     pic X.

      *****************************************************************
      * Message Buffer used by the Z-DISPLAY-MESSAGE-TEXT routine.    *
      *****************************************************************
       01  MESSAGE-BUFFER.
           05  MESSAGE-HEADER      pic X(11)   value '* CBLVLRC7 '.
           05  MESSAGE-TEXT.
               10  MESSAGE-TEXT-1  pic X(68)   value SPACES.
               10  MESSAGE-TEXT-2  pic X(188)  value SPACES.

      *****************************************************************
       01  PROGRAM-NAME            pic X(8)     value 'CBLVLRC7'.

       01  SYSTEM-DATE.
           05  SYSTEM-DATE-YYYY    pic X(4)     value 'yyyy'.
           05  SYSTEM-DATE-MM      pic X(2)     value 'mm'.
           05  SYSTEM-DATE-DD      pic X(2)     value 'dd'.
       01  SYSTEM-TIME.
           05  SYSTEM-TIME-HH      pic X(2)     value 'hh'.
           05  SYSTEM-TIME-MM      pic X(2)     value 'mm'.
           05  SYSTEM-TIME-SS      pic X(2)     value 'ss'.
           05  SYSTEM-TIME-00      pic X(2)     value '00'.

       01  EDITED-DATE.
           05  EDITED-DATE-YYYY    pic X(4)     value 'yyyy'.
           05  filler              pic X        value '/'.
           05  EDITED-DATE-MM      pic X(2)     value 'mm'.
           05  filler              pic X        value '/'.
           05  EDITED-DATE-DD      pic X(2)     value 'dd'.
       01  EDITED-TIME.
           05  EDITED-TIME-HH      pic X(2)     value 'hh'.
           05  filler              pic X        value ':'.
           05  EDITED-TIME-MM      pic X(2)     value 'mm'.
           05  filler              pic X        value ':'.
           05  EDITED-TIME-SS      pic X(2)     value 'ss'.
           05  filler              pic X        value ':'.
           05  EDITED-TIME-00      pic X(2)     value '00'.

       01  APPL-RESULT             pic S9(9)    comp.
           88  APPL-AOK            value 0.
           88  APPL-EOF            value 16.

       01  ALPHAV01-LREC           pic 9(5)    comp    value 0.
       01  ALPHAV01-LREC-ALPHA     redefines   ALPHAV01-LREC.
           05  VREC-LEN-1          pic X(2).
           05  VREC-LEN-2          pic X(2).

      * The following technique is used to create an ASCII and EBCDIC
      * SPACE character. This technique allows the program to execute
      * properly in an ASCII environment under Windows using
      * Micro Focus Net Express.
      * The program will also execute in an EBCDIC environment on the
      * Mainframe or on the PC using Micro Focus Mainframe Express.
       01  ASCII-EBCDIC-VALUE      pic 9(4)    comp    value 8256.
       01  ASCII-EBCDIC-ALPHA      redefines ASCII-EBCDIC-VALUE.
           05  ASC-SPACE-BYTE      pic X.
           05  EBC-SPACE-BYTE      pic X.
       01  SPACE-BYTE              pic X   value SPACE.
       01  COMPILE-MODE            pic X   value SPACE.


       01  TEXT-LENGTH             pic 9(5)    value 0.

       01  YES-BYTE                pic X        value 'Y'.
       01  NUMERIC-CHECK-FLAG      pic X        value 'Y'.

       01  PACK-10         pic X(10) value SPACES.
       01  UNPK-18         pic X(18) value SPACES.

       01  WORK-S-PACK-ALPHA.
           05  WORK-S-PACK-VALUE PIC S9(18)    COMP-3 value 0.

       01  WORK-S-UNPK-ALPHA.
           05  WORK-S-UNPK-VALUE PIC S9(18)           value 0.

       01  WORK-U-PACK-ALPHA.
           05  WORK-U-PACK-VALUE PIC 9(18)     COMP-3 value 0.

       01  WORK-U-UNPK-ALPHA.
           05  WORK-U-UNPK-VALUE PIC 9(18)            value 0.

       01  NON-NUMERIC-ERROR.
           05  filler pic X(29)  value 'Non-Numeric error or value is'.
           05  filler pic X(29)  value ' too great for result field. '.
           05  NN-ERROR-COUNT pic 9(9)   value 0.

       01  COMP-08         pic X(8)  value SPACES.
       01  UNCP-18         pic X(18) value SPACES.

       01  WORK-S-COMP-ALPHA.
           05  WORK-S-COMP-VALUE PIC S9(18)    COMP   value 0.

       01  WORK-S-UNCP-ALPHA.
           05  WORK-S-UNCP-VALUE PIC S9(18)           value 0.

       01  WORK-U-COMP-ALPHA.
           05  WORK-U-COMP-VALUE PIC 9(18)     COMP   value 0.

       01  WORK-U-UNCP-ALPHA.
           05  WORK-U-UNCP-VALUE PIC 9(18)            value 0.

       01  ALPHAV01-TOTAL.
           05  ALPHAV01-RDR  pic 9(9)    value 0.
           05  filler      pic X(3)    value ' - '.
           05  filler      pic X(23)   value 'Line count for ALPHAV01'.
       01  ALPHALS3-TOTAL.
           05  ALPHALS3-ADD  pic 9(9)    value 0.
           05  filler      pic X(3)    value ' - '.
           05  filler      pic X(23)   value 'Line count for ALPHALS3'.

      *****************************************************************
      * The following copy file contains the translation tables for   *
      * the ASCII and EBCDIC conversion. Sections of the tables may   *
      * also be used for case conversion.                             *
      *****************************************************************
       COPY ASCEBCB1.

      *****************************************************************
       PROCEDURE DIVISION.
           perform Z-POST-COPYRIGHT
           perform Z-GET-DATE-AND-TIME
           perform ALPHAV01-OPEN
           perform ALPHALS3-OPEN

           perform until ALPHAV01-STATUS not = '00'
               perform ALPHAV01-READ
               if  ALPHAV01-STATUS = '00'
                   add 1 to ALPHAV01-RDR
                   perform BUILD-OUTPUT-RECORD
                   perform ALPHALS3-WRITE
                   if  ALPHALS3-STATUS = '00'
                       add 1 to ALPHALS3-ADD
                   end-if
               end-if
           end-perform

           move ALPHAV01-TOTAL to MESSAGE-TEXT
           perform Z-DISPLAY-MESSAGE-TEXT

           move ALPHALS3-TOTAL to MESSAGE-TEXT
           perform Z-DISPLAY-MESSAGE-TEXT

           if  NN-ERROR-COUNT > 0
               move NON-NUMERIC-ERROR to MESSAGE-TEXT
               perform Z-DISPLAY-MESSAGE-TEXT
           end-if

           if  APPL-EOF
               move 'is Complete...' to MESSAGE-TEXT
           else
               move 'is ABENDING...' to MESSAGE-TEXT
           end-if
           perform Z-DISPLAY-MESSAGE-TEXT

           perform ALPHALS3-CLOSE
           perform ALPHAV01-CLOSE
           GOBACK.

      *****************************************************************
       BUILD-OUTPUT-RECORD.
      *>   TransMODE is A2E...
      *>   TransINIT process...
           move ALL x'20' to ALPHALS3-REC
      *>   TransLATE...
           move ALPHAV01-REC(00001:00080) to ALPHALS3-REC(00001:00080)
           inspect ALPHALS3-REC(00001:00080)
               converting E-INFO  to A-INFO
           exit.

      *****************************************************************
       CALCULATE-STRING-LENGTH.
           add 80 to ZERO giving TEXT-LENGTH
      *    if  ALPHAV01-RECORD(513:512) = all X'40'
      *        if  ALPHAV01-RECORD(257:768) = all X'40'
      *            add 256 to ZERO giving TEXT-LENGTH
      *        else
      *            add 512 to ZERO giving TEXT-LENGTH
      *        end-if
      *    else
      *        if  ALPHAV01-RECORD(769:256) = all X'40'
      *            add 768 to ZERO giving TEXT-LENGTH
      *        end-if
      *    end-if

           perform until TEXT-LENGTH = 0
                      or ALPHAV01-REC(TEXT-LENGTH:1) not = X'40'
               if  ALPHAV01-REC(TEXT-LENGTH:1) = X'40'
                   subtract 1 from TEXT-LENGTH
               end-if
           end-perform
           exit.

      *****************************************************************
      * I/O Routines for the INPUT File...                            *
      *****************************************************************
       ALPHAV01-READ.
           if  ALPHAV01-OPEN-FLAG = 'C'
               perform ALPHAV01-OPEN
           end-if
           move all x'40' to ALPHAV01-REC
           read ALPHAV01-FILE
           if  ALPHAV01-STATUS = '00'
               subtract APPL-RESULT from APPL-RESULT
           else
               if  ALPHAV01-STATUS = '10'
                   add 16 to ZERO giving APPL-RESULT
               else
                   add 12 to ZERO giving APPL-RESULT
               end-if
           end-if.
           if  APPL-AOK
               CONTINUE
           else
               if  APPL-EOF
                   move 'Y' to ALPHAV01-EOF
               else
                   move 'READ Failure with ALPHAV01' to MESSAGE-TEXT
                   perform Z-DISPLAY-MESSAGE-TEXT
                   move ALPHAV01-STATUS to IO-STATUS
                   perform Z-DISPLAY-IO-STATUS
                   perform Z-ABEND-PROGRAM
               end-if
           end-if
           exit.
      *---------------------------------------------------------------*
       ALPHAV01-OPEN.
           add 8 to ZERO giving APPL-RESULT.
           open INPUT ALPHAV01-FILE
           if  ALPHAV01-STATUS = '00'
               subtract APPL-RESULT from APPL-RESULT
               move 'O' to ALPHAV01-OPEN-FLAG
           else
               add 12 to ZERO giving APPL-RESULT
           end-if
           if  APPL-AOK
               CONTINUE
           else
               move 'OPEN Failure with ALPHAV01' to MESSAGE-TEXT
               perform Z-DISPLAY-MESSAGE-TEXT
               move ALPHAV01-STATUS to IO-STATUS
               perform Z-DISPLAY-IO-STATUS
               perform Z-ABEND-PROGRAM
           end-if
           exit.
      *---------------------------------------------------------------*
       ALPHAV01-CLOSE.
           add 8 to ZERO giving APPL-RESULT.
           close ALPHAV01-FILE
           if  ALPHAV01-STATUS = '00'
               subtract APPL-RESULT from APPL-RESULT
               move 'C' to ALPHAV01-OPEN-FLAG
           else
               add 12 to ZERO giving APPL-RESULT
           end-if
           if  APPL-AOK
               CONTINUE
           else
               move 'CLOSE Failure with ALPHAV01' to MESSAGE-TEXT
               perform Z-DISPLAY-MESSAGE-TEXT
               move ALPHAV01-STATUS to IO-STATUS
               perform Z-DISPLAY-IO-STATUS
               perform Z-ABEND-PROGRAM
           end-if
           exit.

      *****************************************************************
      * I/O Routines for the OUTPUT File...                           *
      *****************************************************************
       ALPHALS3-CLOSE.
           add 8 to ZERO giving APPL-RESULT.
           close ALPHALS3-FILE
           if  ALPHALS3-STATUS = '00'
               subtract APPL-RESULT from APPL-RESULT
           else
               add 12 to ZERO giving APPL-RESULT
           end-if
           if  APPL-AOK
               CONTINUE
           else
               move 'CLOSE Failure with ALPHALS3' to MESSAGE-TEXT
               perform Z-DISPLAY-MESSAGE-TEXT
               move ALPHALS3-STATUS to IO-STATUS
               perform Z-DISPLAY-IO-STATUS
               perform Z-ABEND-PROGRAM
           end-if
           exit.
      *---------------------------------------------------------------*
       ALPHALS3-WRITE.
           write ALPHALS3-REC
           if  ALPHALS3-STATUS = '00'
               subtract APPL-RESULT from APPL-RESULT
           else
               if  ALPHALS3-STATUS = '10'
                   add 16 to ZERO giving APPL-RESULT
               else
                   add 12 to ZERO giving APPL-RESULT
               end-if
           end-if
           if  APPL-AOK
               CONTINUE
           else
               move 'WRITE Failure with ALPHALS3' to MESSAGE-TEXT
               perform Z-DISPLAY-MESSAGE-TEXT
               move ALPHALS3-STATUS to IO-STATUS
               perform Z-DISPLAY-IO-STATUS
               perform Z-ABEND-PROGRAM
           end-if
           exit.
      *---------------------------------------------------------------*
       ALPHALS3-OPEN.
           add 8 to ZERO giving APPL-RESULT.
           open output ALPHALS3-FILE
           if  ALPHALS3-STATUS = '00'
               subtract APPL-RESULT from APPL-RESULT
               move 'O' to ALPHALS3-OPEN-FLAG
           else
               add 12 to ZERO giving APPL-RESULT
           end-if
           if  APPL-AOK
               CONTINUE
           else
               move 'OPEN Failure with ALPHALS3' to MESSAGE-TEXT
               perform Z-DISPLAY-MESSAGE-TEXT
               move ALPHALS3-STATUS to IO-STATUS
               perform Z-DISPLAY-IO-STATUS
               perform Z-ABEND-PROGRAM
           end-if
           exit.

      *****************************************************************
      * The following Z-ROUTINES provide administrative functions     *
      * for this program.                                             *
      *****************************************************************
      * ABEND the program, post a message to the console and issue    *
      * a STOP RUN.                                                   *
      *****************************************************************
       Z-ABEND-PROGRAM.
           if  MESSAGE-TEXT not = SPACES
               perform Z-DISPLAY-MESSAGE-TEXT
           end-if
           move 'PROGRAM-IS-ABENDING...'  to MESSAGE-TEXT
           perform Z-DISPLAY-MESSAGE-TEXT
           add 12 to ZERO giving RETURN-CODE
           STOP RUN.
      *    exit.

      *****************************************************************
      * Display CONSOLE messages...                                   *
      *****************************************************************
       Z-DISPLAY-MESSAGE-TEXT.
           if MESSAGE-TEXT-2 = SPACES
               display MESSAGE-BUFFER(1:79)
           else
               display MESSAGE-BUFFER
           end-if
           move all SPACES to MESSAGE-TEXT
           exit.

      *****************************************************************
      * Display the file status bytes. This routine will display as   *
      * four digits. If the full two byte file status is numeric it   *
      * will display as 00nn. If the 1st byte is a numeric nine (9)   *
      * the second byte will be treated as a binary number and will   *
      * display as 9nnn.                                              *
      *****************************************************************
       Z-DISPLAY-IO-STATUS.
           if  IO-STATUS not NUMERIC
           or  IO-STAT1 = '9'
               move IO-STAT1 to IO-STATUS-04(1:1)
               subtract TWO-BYTES-BINARY from TWO-BYTES-BINARY
               move IO-STAT2 to TWO-BYTES-RIGHT
               add TWO-BYTES-BINARY to ZERO giving IO-STATUS-0403
               move 'File Status is: nnnn' to MESSAGE-TEXT
               move IO-STATUS-04 to MESSAGE-TEXT(17:4)
               perform Z-DISPLAY-MESSAGE-TEXT
           else
               move '0000' to IO-STATUS-04
               move IO-STATUS to IO-STATUS-04(3:2)
               move 'File Status is: nnnn' to MESSAGE-TEXT
               move IO-STATUS-04 to MESSAGE-TEXT(17:4)
               perform Z-DISPLAY-MESSAGE-TEXT
           end-if
           exit.

      *****************************************************************
      * Get Date and Time                                             *
      *****************************************************************
       Z-GET-DATE-AND-TIME.
           accept SYSTEM-DATE from DATE YYYYMMDD
           accept SYSTEM-TIME from TIME

           move SYSTEM-DATE-YYYY to EDITED-DATE-YYYY
           move SYSTEM-DATE-MM   to EDITED-DATE-MM
           move SYSTEM-DATE-DD   to EDITED-DATE-DD

           move SYSTEM-TIME-HH to EDITED-TIME-HH
           move SYSTEM-TIME-MM to EDITED-TIME-MM
           move SYSTEM-TIME-SS to EDITED-TIME-SS
           move SYSTEM-TIME-00 to EDITED-TIME-00

           exit.

      *****************************************************************
       Z-POST-COPYRIGHT.
           display SIM-TITLE
           display SIM-COPYRIGHT
           exit.
      *****************************************************************
      *           This program was generated by SimoZAPS              *
      *             A product of SimoTime Technologies                *
      *        Our e-mail address is: helpdesk@simotime.com           *
      *     Also, visit our Web Site at http://www.simotime.com       *
      *                                                               *
      *  Generation Date: 2004-05-11  Generation Time: 23:12:36:66    *
      *     Program Name:             Generation Mode: ASCII          *
      *****************************************************************

Table of Contents Previous Section Next Section The COBOL Copy Files

The following are the COBOL copy files used by the program.

Table of Contents Previous Section Next Section COBOL Copy File, ASCEBCB1

The following (ASCEBCB1.cpy) is the source code for the copy file that defines an ASCII table and an EBCDIC table that are used for data conversion(between ASCII and EBCIDC) and case conversion (between upper and lower case).

      *****************************************************************
      *               AE9437B1.cpy - a COBOL Copy File                *
      *         Copyright (C) 1987-2018 SimoTime Technologies         *
      *                     All Rights Reserved                       *
      *              Provided by SimoTime Technologies                *
      *        Our e-mail address is: helpdesk@simotime.com           *
      *     Also, visit our Web Site at http://www.simotime.com       *
      *****************************************************************
      * The following tables are used by the INSPECT statement to do  *
      * the conversion between EBCDIC and ASCII.                      *
      *                                                               *
      *   inspect FIELD-NAME converting EBCDIC-INFO to ASCII-INFO     *
      *   inspect FIELD-NAME converting ASCII-INFO  to EBCDIC-INFO    *
      *                                                               *
      * The tables include the alphabet for upper and lower case, the *
      * digits 0-9, the special characters (US) and the alternate     *
      * codes for A, E, I, O, and U with the appropriate acute,       *
      * grave, umlaut, circumflex and tilde.                          *
      * To display the alternate codes the Courier New (Fixed) or     *
      * Times New Roman (Proportional) font should be used.           *
      *                                                               *
      * SimoZAPS contains four tables that may be used for various    *
      * Upper/Lower Case or EBCDIC/ASCII conversion requirements.     *
      * ASCEBCB1.CPY - includes a full character set for the alphabet *
      *                (upper/lower case), digit, special characters  *
      *                and alternate codes for characters with the    *
      *                acute, grave, umlaut, tilde and circumflex.    *
      *                Caution: this table does not convert the Y     *
      *                characters with an umlat.                      *
      * ASCEBCB2.CPY - includes the character set for the translation *
      *                between EBCDIC/ASCII of signed/unsigned,       *
      *                zoned-decimal, numeric fields.                 *
      * ASCEBCB3.CPY - includes the character set for the alternate   *
      *                codes with the acute, grave, umlaut, tilde and *
      *                circumflex. This is primarily used for case    *
      *                conversion.                                    *
      *                Note: this table converts the Y characters     *
      *                with an umlat, this will convert high-values   *
      *                X'FF' to X'DF'                                 *
      * ASCEBCB4.CPY - includes the character set for the alphabet    *
      *                (upper/lower case), digit, special characters. *
      *                This is primarily used in the US where the     *
      *                alternate codes may not be required.           *
      * ASCEBCB5.CPY - includes a full character set for the alphabet *
      *                (upper/lower case), digit, special characters  *
      *                and alternate codes for characters with the    *
      *                acute, grave, umlaut, tilde and circumflex.    *
      *                Caution: this table will convert the Y         *
      *                characters with an umlat.                      *
      *****************************************************************
      *
      *    ------------------------------------------------------------
       01  EBCDIC-DATA.
           05  FILLER pic X(16)
                          value X'000102030405060708090A0B0C0D0E0F'.    000-015
           05  FILLER pic X(16)
                          value X'101112131415161718191A1B1C1D1E1F'.    016-031
           05  FILLER pic X(16)
                          value X'202122232425262728292A2B2C2D2E2F'.    032-047
           05  FILLER pic X(16)
                          value X'303132333435363738393A3B3C3D3E3F'.    048-063
           05  FILLER pic X(16)
                          value X'404142434445464748494A4B4C4D4E4F'.    064-079
           05  FILLER pic X(16)
                          value X'505152535455565758595A5B5C5D5E5F'.    080=095
           05  FILLER pic X(16)
                          value X'606162636465666768696A6B6C6D6E6F'.    096-111
           05  FILLER pic X(16)
                          value X'707172737475767778797A7B7C7D7E7F'.    112-127
           05  FILLER pic X(16)
                          value X'808182838485868788898A8B8C8D8E8F'.    128-143
           05  FILLER pic X(16)
                          value X'909192939495969798999A9B9C9D9E9F'.    144-159
           05  FILLER pic X(16)
                          value X'A0A1A2A3A4A5A6A7A8A9AAABACADAEAF'.    160-175
           05  FILLER pic X(16)
                          value X'B0B1B2B3B4B5B6B7B8B9BABBBCBDBEBF'.    176-191
           05  FILLER pic X(16)
                          value X'C0C1C2C3C4C5C6C7C8C9CACBCCCDCECF'.    192-207
           05  FILLER pic X(16)
                          value X'D0D1D2D3D4D5D6D7D8D9DADBDCDDDEDF'.    208-223
           05  FILLER pic X(16)
                          value X'E0E1E2E3E4E5E6E7E8E9EAEBECEDEEEF'.    224-239
           05  FILLER pic X(16)
                          value X'F0F1F2F3F4F5F6F7F8F9FAFBFCFDFEFF'.    240-255

       01  E-INFO           redefines EBCDIC-DATA pic X(256).
       01  EBCDIC-TABLE     redefines EBCDIC-DATA.
           05  EBCDIC-BYTE  pic X     occurs 256 times.
      *
      *    ------------------------------------------------------------
       01  ASCII-DATA.
           05  FILLER pic X(16)
                          value X'000102039C09867F978D8E0B0C0D0E0F'.    000-015
           05  FILLER pic X(16)
                          value X'101112139D8508871819928F1C1D1E1F'.    016-031
           05  FILLER pic X(16)
                          value X'80818283840A171B88898A8B8C050607'.    032-047
           05  FILLER pic X(16)
                          value X'909116939495960498999A9B14159E1A'.    048-063
           05  FILLER pic X(16)
                          value X'20A0E2E4E0E1E3E5E7F1A22E3C282B7C'.    064-079
           05  FILLER pic X(16)
                          value X'26E9EAEBE8EDEEEFECDF21242A293BAC'.    080=095
           05  FILLER pic X(16)
                          value X'2D2FC2C4C0C1C3C5C7D1A62C255F3E3F'.    096-111
           05  FILLER pic X(16)
                          value X'F8C9CACBC8CDCECFCC603A2340273D22'.    112-127
           05  FILLER pic X(16)
                          value X'D8616263646566676869ABBBF0FDFEB1'.    128-143
           05  FILLER pic X(16)
                          value X'B06A6B6C6D6E6F707172AABAE6B8C6A4'.    144-159
           05  FILLER pic X(16)
                          value X'B57E737475767778797AA1BFD0DDDEAE'.    160-175
           05  FILLER pic X(16)
                          value X'5EA3A5B7A9A7B6BCBDBE5B5DAFA8B4D7'.    176-191
           05  FILLER pic X(16)
                          value X'7B414243444546474849ADF4F6F2F3F5'.    192-207
           05  FILLER pic X(16)
                          value X'7D4A4B4C4D4E4F505152B9FBFCF9FAFF'.    208-223
           05  FILLER pic X(16)
                          value X'5CF7535455565758595AB2D4D6D2D3D5'.    224-239
           05  FILLER pic X(16)
                          value X'30313233343536373839B3DBDCD9DAFF'.    240-255
       01  A-INFO           redefines ASCII-DATA pic X(256).
       01  ASCII-TABLE      redefines ASCII-DATA.
           05  ASCII-BYTE   pic X     occurs 256 times.
      *
      ***  AE0437B1 - End-of-Copy File - - - - - - - - - - - AE0437B1 *
      *****************************************************************
      *

Table of Contents Previous Section Next Section COBOL Copy File, PASSBSIO

The following (PASSBSIO.cpy) is the source code for the copy file that defines the data structure of the pass area used to call SIMOBSIO.

      *****************************************************************
      *                PASSBSIO is a COBOL Copy File                  *
      *     Data Structure or Pass Area used for calling SIMOBSIO.    *
      *         Copyright (C) 1987-2019 SimoTime Technologies         *
      *                     All Rights Reserved                       *
      *****************************************************************
      *              Provided by SimoTime Technologies                *
      *        Our e-mail address is: helpdesk@simotime.com           *
      *     Also, visit our Web Site at http://www.simotime.com       *
      *****************************************************************
      *
       01  PSIO-PASS-AREA.
           05  PSIO-REQUEST            pic X(8).
           05  PSIO-RETURN             pic 9(4).
           05  PSIO-FILENAME           pic X(256).
           05  PSIO-FILE-SIZE          pic 9(12).
           05  PSIO-OFFSET             pic 9(12).
           05  PSIO-LENGTH             pic 9(7).
           05  PSIO-MAX-SIZE           pic 9(7).
           05  PSIO-BUFFER             pic X(32760).
      *
      ***  PASSBSIO - End-of-Copy File - - - - - - - - - - - PASSBSIO *
      *****************************************************************
      *

Table of Contents Previous Section Next Section Summary

This suite of programs will do a record content and file format conversion in a single pass. This document may be used to assist as a tutorial for new programmers or as a quick reference for experienced programmers.

In the world of programming there are many ways to solve a problem. This documentation and software were developed and tested on systems that are configured for a SIMOTIME environment based on the hardware, operating systems, user requirements and security requirements. Therefore, adjustments may be needed to execute the jobs and programs when transferred to a system of a different architecture or configuration.

SIMOTIME Services has experience in moving or sharing data or application processing across a variety of systems. For additional information about SIMOTIME Services or Technologies please contact us using the information in the  Contact or Feedback  section of this document.

Table of Contents Previous Section Next Section Software Agreement and Disclaimer

Permission to use, copy, modify and distribute this software, documentation or training material for any purpose requires a fee to be paid to SimoTime Technologies. Once the fee is received by SimoTime the latest version of the software, documentation or training material will be delivered and a license will be granted for use within an enterprise, provided the SimoTime copyright notice appear on all copies of the software. The SimoTime name or Logo may not be used in any advertising or publicity pertaining to the use of the software without the written permission of SimoTime Technologies.

SimoTime Technologies makes no warranty or representations about the suitability of the software, documentation or learning material for any purpose. It is provided "AS IS" without any expressed or implied warranty, including the implied warranties of merchantability, fitness for a particular purpose and non-infringement. SimoTime Technologies shall not be liable for any direct, indirect, special or consequential damages resulting from the loss of use, data or projects, whether in an action of contract or tort, arising out of or in connection with the use or performance of this software, documentation or training material.

Table of Contents Previous Section Next Section Downloads and Links

This section includes links to documents with additional information that are beyond the scope and purpose of this document. The first sub-section requires an internet connection, the second sub-section references locally available documents.

Note: A SimoTime License is required for the items to be made available on a local server.

Table of Contents Previous Section Next Section Current Server or Internet Access

The following links may be to the current server or to the Internet.

Link to Internet   Link to Server   Explore How to FTP (using BINARY mode) a File with Variable Length Records from a Mainframe System to a Windows System and then convert the Mainframe format to a Micro Focus format. The mainline program will call the SIMOVREC and SIMOBSIO modules that are available from SimoTime in a separate package.

Link to Internet   Link to Server   Explore The ASCII and EBCDIC Translation Tables. These tables are provided for individuals that need to better understand the bit structures and differences of the encoding formats.

Link to Internet   Link to Server   Explore The File Status Return Codes that are used to interpret the results of accessing VSAM data sets and/or QSAM files.

Link to Internet   Link to Server   Explore the File Formats and various Numeric Formats being used in a multi-system complex consisting of Mainframe (z/OS), Linux, UNIX or Windows systems.

Table of Contents Previous Section Next Section Internet Access Required

The following links will require an internet connect.

This suite of programs and documentation is available for download. Link to an Evaluation zPAK Option that includes the program members, documentation and control files.

Explore The Micro Focus Web Site for more information about products (including Micro Focus COBOL) and services available from Micro Focus. This link requires an Internet Connection.

A good place to start is The SimoTime Home Page for access to white papers, program examples and product information. This link requires an Internet Connection

Table of Contents Previous Section Next Section Glossary of Terms

Link to Internet   Link to Server   Explore the Glossary of Terms for a list of terms and definitions used in this suite of documents and white papers.

Table of Contents Previous Section Next Section Contact or Feedback

This document was created and is maintained by SimoTime Technologies. If you have any questions, suggestions, comments or feedback please use the following contact information.

1. Send an e-mail to our helpdesk.
1.1. helpdesk@simotime.com.
2. Our telephone numbers are as follows.
2.1. 1 415 763-9430 office-helpdesk
2.2. 1 415 827-7045 mobile

 

We appreciate hearing from you.

Table of Contents Previous Section Next Section Company Overview

SimoTime Technologies was founded in 1987 and is a privately owned company. We specialize in the creation and deployment of business applications using new or existing technologies and services. We have a team of individuals that understand the broad range of technologies being used in today's environments. Our customers include small businesses using Internet technologies to corporations using very large mainframe systems.

Quite often, to reach larger markets or provide a higher level of service to existing customers it requires the newer Internet technologies to work in a complementary manner with existing corporate mainframe systems. We specialize in preparing applications and the associated data that are currently residing on a single platform to be distributed across a variety of platforms.

Preparing the application programs will require the transfer of source members that will be compiled and deployed on the target platform. The data will need to be transferred between the systems and may need to be converted and validated at various stages within the process. SimoTime has the technology, services and experience to assist in the application and data management tasks involved with doing business in a multi-system environment.

Whether you want to use the Internet to expand into new market segments or as a delivery vehicle for existing business functions simply give us a call or check the web site at http://www.simotime.com


Return-to-Top
CBLVLRC7, COBOL program for File Format Conversion
Copyright © 1987-2025
SimoTime Technologies and Services
All Rights Reserved
When technology complements business
http://www.simotime.com