Server Guide

Creating files for the workstation simulation system

When testing your application on the workstation, you must produce files that reflect the data sets your application will access on OS/390. There are several ways to create a file for testing, including writing to an empty file with data that mirrors the OS/390 data set, re-creating the data set on the workstation, and downloading the data set to the workstation. Of these, downloading the data set from OS/390 to the workstation involves the least amount of work and allows your program to access the exact same data on the workstation as it will be accessing on OS/390.

Downloading data sets to the workstation

The way your program uses downloaded data sets on the workstation depends on what type of data set you have downloaded. There are different procedures for VSAM data sets, fixed PDS members or sequential data sets, and variable PDS members or sequential data sets. Note that when you are using data sets downloaded from OS/390, you must set the correct values for data conversion either using the COBOL or C parser or from your application. For more information on C or COBOL parsers in VisualAge Smalltalk, refer to the VisualAge User's Guide. If you decide to set the correct values for data conversion from your application, send the messages bigEndian: and codePage: to the object.

Using VSAM data sets on the workstation

If you want to use the OS/390 VSAM data set on the workstation, follow these steps:

  1. On OS/390, use the REPRO command to copy the VSAM data set into a sequential data set.
  2. Download the sequential data set as binary to the workstation.
  3. Allocate a Btrieve file using either CICS or Btrieve SDK. If this is a KSDS file, ensure that the key specification for the Btrieve file matches the key specification of the VSAM file you are converting. Also make sure that the record length and record format values are identical. See Allocating VSAM files on the workstation for more information.
  4. Create an empty file for the Btrieve file you just allocated. You can use the CICS command CECI SET FILE(filename) CLOSED and CECI SET FILE(filename) OPEN RESET to create an empty file.
  5. In the resource association file, create two entries, one for the downloaded sequential file and one for the empty Btrieve file.
  6. Start VisualAge Smalltalk Server. From a Transcript window or a browser, execute one of the following conversion tools, based on the type of VSAM file you are converting:

    The seqFileID is the fileid for the downloaded sequential file as specified in the resource association file, and the vsamFileID is the fileid for the Btrieve file as specified in the resource association file. Each of these classes answers an OrderedCollection. For KSDS files, it is a collection of keys; for RRDS files, it is a collection of relative record numbers; for ESDS files, it is a collection of relative byte addresses.

    You can also convert VSAM files to sequential files, with the intention of uploading the file to OS/390 as a binary file and using the REPRO command to copy the sequential file into a preallocated VSAM data set. The following tools enable you to convert VSAM ESDS, KSDS, and RRDS files into sequential files on the workstation:

    Whenever you use either the tools that convert a VSAM file to a sequential file or the tools that convert a sequential file to a VSAM file, ensure that the file ids for both the VSAM file and the sequential file are properly specified in the resource association file.

Downloading a fixed PDS member or sequential file

If you want to use an OS/390 PDS member or sequential data set whose records are fixed, you can simply download the PDS member or sequential data set as binary to the workstation. Before you access the file on the workstation, ensure that the resource association file is properly specified, including the RECFM parameter, which must be specified as F or FB.

Downloading a variable PDS member or sequential file

If you want to use an OS/390 PDS member or sequential file whose records are variable, follow these steps:

  1. Edit member ABT.V4R5M0.SABTJLIB(ABTBCONV).
  2. There are two parameters available for converting variable files. If you intend to download the variable file for use on the workstation, use PARM='MVSTOPC'; if you are uploading a variable file from the workstation for use on OS/390, use PARM='PCTOMVS'.
  3. Provide data set names for the INFILE (the data set you want converted) and for the OUTFILE (the pre-allocated data set into which you want the converted data placed). When you are converting from OS/390 to the workstation, the OUTFILE must have an LRECL two bytes longer than the LRECL of the INFILE. When you are converting from the workstation to OS/390, the OUTFILE must have an LRECL two bytes fewer than the LRECL of the INFILE.
  4. Download the converted data set as binary to the workstation. You can also upload variable files from the workstation to OS/390.

Before you access the file on the workstation, ensure that the resource association file is properly specified, including the RECFM parameter, which must be specified as V or VB.


[ Top of Page | Previous Page | Next Page | Table of Contents | Index ]