Creating File Descriptions Using AUTOIMS

In this section:

AUTOIMS is an automated procedure that creates a Master File and FOCPSB for an IMS data source. This procedure operates in three phases:

Note: AUTOIMS does not support secondary indexes.

For detailed information about the COBOL FD Translator, see the COBOL FD Translator User's Manual and Installation Guide.


Top of page

x
AUTOIMS Prerequisites

Before you can execute the AUTOIMS procedure, the following prerequisites must be met:

AUTOIMS is installed during FOCUS installation. No additional installation steps are needed.


Top of page

x
Invoking AUTOIMS

In this section:

How to:

Reference:

AUTOIMS can only be invoked interactively in a FOCUS session. The CLIST that starts the session must allocate the following ddnames:

DDNAME

Allocated to the ...

FOCLIB

FOCUS product load library

USERLIB

COBOL FD Translator load library

MASTER

PDS that contains Master Files

FOCEXEC

PDS that contains FOCUS procedures

ERRORS

PDS that contains Information Builders error messages

TRF

PDS that contains windows displayed by AUTOIMS that list and let you select members to use in the AUTOIMS procedure

HOLDMAST

PDS that contains HOLD Master Files



Example: Editing the Sample CLIST for AUTOIMS

Before executing this CLIST, edit it to conform to the standards at your site:

PROC 0  CONTROL NOLIST NOMSG NOFLUSH NOSYM END(ENDO)              
ALLOC F(FOCLIB)   DA('prefix.FOCLIB.LOAD') SHR REUSE       
ALLOC F(USERLIB)  DA('prefix.CTF30.LOAD' +              
                     'prefix.FUSELIB.LOAD') SHR REUSE      
ALLOC F(MASTER)   DA('prefix.MASTER.DATA')  SHR REUSE      
ALLOC F(FOCEXEC)  DA('prefix.FOCEXEC.DATA') SHR REUSE     
ALLOC F(ERRORS)   DA('prefix.ERRORS.DATA') SHR REUSE      
ALLOC F(TRF)      DA('prefix.TRF.DATA') SHR REUSE     
ALLOC F(HOLDMAST) DA('user.HOLDMAST.DATA') SHR REUSE  
CALL 'prefix.FOCLIB.LOAD(FOCUS)'                          
EXIT                                                      

where:

prefix

Is the high-level qualifier for your FOCUS production data sets.

user

Is the high-level qualifier for the HOLDMAST data set. You must have authority to create new members in this data set.

Note: You are also required to have authority to create members in the data sets that will receive the Master Files and FOCPSBs created by AUTOIMS. You enter the names of these data sets on the first window displayed by AUTOIMS.



x
Procedure: How to Start the AUTOIMS Procedure and Log the Parameters
  1. From the FOCUS prompt, issue the following command:
    EX AUTOIMS

    The AUTOIMS Main Menu displays:

  2. In this window, supply the name of the PSB and the data sets AUTOIMS requires.

    Once the correct information is entered, you can log it to a file so that it will display automatically in subsequent executions of AUTOIMS.

  3. Press Enter to proceed. AUTOIMS displays a message to indicate that it is processing your menu selections.


x
Reference: Required Data Set Names for AUTOIMS

AUTOIMS requires the following data sets:

If the default data set names are not the ones you need, type the correct names over them.



x
Procedure: How to Select the PSB Name

If you know the PSB name you want AUTOIMS to use, you can enter it directly in the window.

You can also select the PSB name from the PSBLIB:

  1. With the cursor on the PSB name line of the AUTOIMS Main Menu, press PF5.

    The Member List window displays:

  2. Page down until the cursor is under the PSB you need, and press Enter.

    The PSB is entered on the PSB name line:

    You can view the member list for any of the data sets listed on the Main Menu by placing the cursor under the data set name and pressing PF5. You can then:

    • Select a member and open it for editing in TED by pressing PF6.
    • Close the Member List window without making a selection by pressing PF3.


x
Procedure: How to Save Default AUTOIMS Parameters

AUTOIMS can save the data set names and the PSB name you enter on the Main Menu. In future executions, these values will display as the default values on the AUTOIMS Main Menu.

  1. When the information you want to log is displayed on the main window, press PF4.

    The parameters are saved in the Parameter Log file, which is member IMS$PRM in the FOCPSB data set. The first time you press PF4, AUTOIMS creates the log file. If you press PF4 again, AUTOIMS updates the file with the values currently displayed:



x
AUTOIMS Master File Generation Window

When all of the necessary information is displayed on the Main Menu window, press Enter. The Master File Generation window displays.

Note that the FOCPSB name is the name from the last time you logged parameters. The FOCPSB created at the end of AUTOIMS processing will have the correct name for the IMS PSB referenced.



x
Procedure: How to Enter Information on the AUTOIMS Master File Generation Window
  1. Enter a name for the new Master File in the MFD NAME column.
  2. Enter the name of the COBOL FD for each segment listed. On the following screen, the Master File name is DI210307 and the COBOL FD names are the same as the segment names. Note that it is a requirement of the COBOL FD Translator that each segment in the DBD have a separate COBOL FD:

  3. Press Enter.

    If AUTOIMS detects a problem, such as a Master File name that already exists, it places a message in the ERROR/WARNING column. In the following example, the Master File name already exists:

    • To ignore the warning and overwrite the existing Master File, Press PF5.
    • To supply a new name, type over the Master File name and press Enter.

    If the PSB has more than one PCB, you must enter a Master File name for each PCB and supply COBOL FD names for each segment in all of the PCBs. If the PSB contains non-database PCBs, they will be handled automatically by AUTOIMS.

    The following is an example of a PSB that contains two database PCBs:

    Two Master File names are entered, and a COBOL FD name is supplied for each segment in both PCBs. Note that AUTOIMS processing time increases as the number of PCBs increases.



x
COBOL FD Translator Options Window

Next AUTOIMS displays the COBOL FD Translator Options window:

In many cases the default options are sufficient. However, some situations require changes to these defaults. For a detailed discussion of the options, refer to the COBOL FD Translator User's Manual and Installation Guide.

When you press Enter, AUTOIMS displays a message indicating that it is processing your request.



x
Completing AUTOIMS Processing

The Main Menu displays with a completion message when AUTOIMS finishes processing:



x
Reference: AUTOIMS Main Menu PF Keys

Several PF key actions are available from the Main Menu:

PF Key

Action

PF1

Displays a help file.

PF3

Exits from the active window.

PF4

Updates the parameter log file with the names entered on the Main Menu.

PF5

Opens a Member List window for the selected data set.

PF6

Opens a member from the Member List window for editing or viewing in TED.

PF9

Opens the file that contains the parameter list passed by AUTOIMS to the COBOL FD Translator.

PF12

Displays a report about the Master File creation process, including detailed descriptions of the fields inserted.

Note that PF10 and PF11 are used by the COBOL FD Translator and do not supply useful information regarding AUTOIMS.



x
Accessing the Generated Master File and FOCPSB

You can list data set members and open them in TED directly from the AUTOIMS Main Menu.



x
Procedure: How to Access the Generated Master File and FOCPSB
  1. Place the cursor under the name of the data set whose members you want to list and press PF5.

    The Member List window displays. It lists the members of the Master Target data set.

  2. To open a member in TED, place the cursor under the member name and press PF6.

    The following example shows the Master File just created by AUTOIMS, member DI210307 in the Master Target PDS:

    $$$ CREATED BY AUTOIMS ON 03/07/01 AT 15.29.22 BY PMSSAE                  
    $$$ FROM PSB : DI21PSB   DBD: DI21PART GEN DATE: 12/09/98 08.36610        
    $$$ IN PSBLIB: IMS.V6R1M0.DBT.PSBLIB                                      
    $$$ IN DBDLIB: IMS.V6R1M0.DBT.DBDLIB                                      
    FILENAME=DI211229,SUFFIX=IMS,$                                            
     SEGNAME=PARTROOT,SEGTYPE=S2,PARENT=        ,$                            
      GROUP=PARTROOT_IO            ,ALIAS=            ,A50     ,A050,$ 
      FIELD=PARTKEY                ,ALIAS=PARTKEY.KEY ,A17     ,A017,$ 
      FIELD=FILLER                 ,ALIAS=            ,A33     ,A033,$ 
     SEGNAME=STANINFO,SEGTYPE=S2,PARENT=PARTROOT,$                            
      GROUP=STANINFO_IO            ,ALIAS=            ,A85     ,A085,$ 
      FIELD=STANKEY                ,ALIAS=STANKEY.KEY ,A2      ,A002,$ 
      FIELD=FILLER                 ,ALIAS=            ,A83     ,A083,$ 
     SEGNAME=STOKSTAT,SEGTYPE=S2,PARENT=PARTROOT,$                            
      GROUP=STOKSTAT_IO            ,ALIAS=            ,A140    ,A140,$ 
      FIELD=STOCKEY                ,ALIAS=STOCKEY.KEY ,A16     ,A016,$ 
      FIELD=FILLER                 ,ALIAS=            ,A124    ,A124,$ 
     SEGNAME=CYCCOUNT,SEGTYPE=S2,PARENT=STOKSTAT,$                            
      GROUP=CYCCOUNT_IO            ,ALIAS=            ,A25     ,A025,$ 
      FIELD=CYCCKEY                ,ALIAS=CYCLKEY.KEY ,A2      ,A002,$
      FIELD=FILLER                 ,ALIAS=            ,A23     ,A023,$
     SEGNAME=BACKORDR,SEGTYPE=S2,PARENT=STOKSTAT,$                           
      GROUP=BACKORDR_IO            ,ALIAS=            ,A75     ,A075,$
      FIELD=BACKKEY                ,ALIAS=BACKKEY.KEY ,A10     ,A010,$
      FIELD=FILLER                 ,ALIAS=            ,A65     ,A065,$

    The following example shows the FOCPSB just created by AUTOIMS, member DI21PSB in the FOCPSB Target PDS. Note that the name of the FOCPSB is the same as the name of the PSB, and the PCBNAME attribute supplies the name of the Master File:

    FOCPSB=EXTENDED,$            PSBNAME=DI21PSB                       
    PCBNAME=DI210307,PCBTYPE=DB  ,$ 0001 DI21PART                      

    Warning: Comments (lines starting with the dollar sign) are not supported in the FOCPSB.

    You can edit the file if necessary, then:

    • To close it without editing, press PF3.
    • To close it and save any edits you made, type FILE on the command line and press Enter.

    To close the Member List window, press PF3.



x
Procedure: How to Create a New Member from the AUTOIMS Main Menu
  1. With the member list for one of the main menu data sets open, press PF9.

    The following window displays:

  2. Enter a name for the new member and press Enter.


x
Generated Master File

In the generated Master File:

  • The FILENAME value is the name of the Master File.
  • The SUFFIX is IMS.
  • The segment names are the segment names from the IMS PSB.
  • The group names are the level 01 names from the COBOL FD.
  • Key field and search field names are taken from the IMS DBD. These are the only fields that have ALIAS values in the generated Master File. Names for other fields are taken from the COBOL FD.

AUTOIMS supports a field name of up to 66 characters for the POSITION=fieldname attribute instead of truncating the field name to 12 characters.

AUTOIMS calls another procedure (AUTOIMSX) to check the POSITION field if and when it is created to make sure the length of the field is the exact length it should be. Two Master Files, AUTOIN and CTFIN, are required in doing this. These Master Files must be included in the Master Target PDS library. If they are not in this library, the following message displays and the Master File is not generated:

(FOC361) POSITION FIELD IS NOT IN THE PARENT SEGMENT: 

Format conversions are described in the COBOL FD Translator for User's Manual and Installation Guide.



x
Reference: Using the Generated Master File

You may need to manually edit the generated Master File in the following situations:

  • There are too many segments (because of REDEFINES and OCCURS segments).
  • There are multiple record types. You need to identify the RECTYPE field and the associated values.
  • There are OCCURS segments and you want to add the ORDER field to the description.
  • You want to add ALIAS values to fields that are not key or search fields.
  • There are embedded REDEFINES declarations.
  • To edit date formats and format options.

Information Builders