You are here: LANSA for i User Guide > 3. Files > 3.4 Create a New File Definition > 3.4.1 Specify the New File Name

3.4.1 Specify the New File Name

When the option to create a new file definition has been chosen from the file control menu this screen is displayed. It requests that the name and description of the file to be created are input:

 

 CRTFILE                  Create New File Definition                   

                                                                       

 New file name . . . . . . . __________                                

 Library of residence  . . . __________                                

 Description . . . . . . . . ________________________________________  

 Initial public access . . . NORMAL    NORMAL, ALL, NONE               

 To be maintained by . . . . LANSA     LANSA,  OTHER                   

                                                                       

 Copy file definition  . . . __________                                

   residing in library . . . __________                                

                                                                       

                                                                       

                                                                       

 Fnn=Help  Fnn=Exit  Fnn=Cancel  Fnn=Messages                          

                                                                       

 

 

 

After details requested by this screen have been supplied, the file definition menu will be displayed. This allows the specification of the various components of the file definition (i.e. fields, validation rules, access routes, etc).

New File Name

Specifies the name by which the new file is to be known. Must be a valid object name. This name was once restricted to a maximum length of 8 characters but can now be 9 or 10 characters long. It is strongly recommended that 9 and 10 character file names be unique in their first 8 characters. This retains uniqueness in the formation of the $$ file name used in making the file operational and importing.

Combination of file name and library name must be unique. The use of the same file name in different libraries is possible using LANSA. However it is strongly recommended that this procedure is NOT used. Instead it is better to install multiple LANSA systems to service different environments such as development and production. Refer to the Installing LANSA on IBM i Guide for more details.

Library of Residence

Specifies the library in which the new file is to reside. The library specified must exist and the user must be authorized to use it. This is checked by LANSA. When the library name is combined with the file name it must form a unique name for the file.

Avoid creating files that reside in your IBM i "current" library.

This parameter can be pre-filled to a default library value as specified in the current partition's definition.

Description

Specifies the description that is to be associated with this file. This is important as it is more often used than the file name when selecting the file for use in some way. A brief description must be specified.

Initial Public Access

Specifies what access other users are to be given to the file initially. The access to the file can be changed at any time later using the option available on the housekeeping menu. Mandatory. Pre-filled to NORMAL. Allowable values are:

NORMAL

Other users can read, add, change and delete records that are stored in this file, but they cannot modify the definition of the file in any way.

ALL

Other users can read, add, change and delete records that are stored in this file. In addition they can modify or delete the definition of the file.

NONE

Other users cannot access records stored in this file nor can they review or modify the definition of the file.

To Be Maintained By

Specifies who is to create and maintain this file definition. Prefilled to LANSA. Allowable values are:

LANSA

Indicates that the actual physical and logical files that result from this file definition are to be maintained (i.e. created, changed and deleted) by the LANSA system. If this option is used the file must not already exist in the library specified.

OTHER

Indicates that the actual physical and logical files associated with this file definition are to be maintained (i.e. created, changed and deleted) by some OTHER system or mechanism. If this option is used the file must already exist in the library specified.

Use this option when you wish to load the definition of an existing file into LANSA, thus making the file accessible through LANSA, but do not wish to have LANSA responsible for the setup and maintenance of the associated physical and logical files.

If this option is used it is possible to use the facility "Load definition of file not maintained by LANSA" from the file definition menu to automatically load the definition of associated physical and logical into the LANSA system. Refer elsewhere for more information about this facility.

 

Note: You must specify *OTHER_DATETIME and *OTHER_VARCHAR options if the OTHER files that you want to made known to LANSA contain:

For more information about these options, refer to OTHER file I/O modules in Compile and Edit Settings in the Review System Settings.

Copy File Named

Optional. Specifies the name of a file definition to be copied to create the definition of this new file. Copied details can be modified from the file definition menu.

Residing in Library

Optional. Specifies the library in which the file definition that is to be copied is located.