The full benefits of LANSA's centralized Repository will be achieved if certain standards are adopted and rigorously enforced. These include:
Using a centralized Repository may extend the design phase of a project but this will easily outweigh the benefits achieved during the development and maintenance phases.
Consistency in validity checking, error messages and the names used on screens and reports and provides immeasurable benefits to end users.
Some suggested guidelines for the definition of fields stored in the repository are as follows:
should be Part
Part Number Status ==========> Status
XXX XXX
XXX XXX
XXX XXX
Part Customer
Number Number Date Due
Part Number
Cust Number
Date Due
Input attributes should not normally be specified. The system default attributes should be correct for most fields.
In SAA/CUA compliant partitions the following input attributes should always be specified (in addition to any system default attributes):
PBEN | Panel body normal input field. For normal or non-significant fields (e.g. Zip Code). |
PBEE | Panel body emphasized input field. For important, significant or key fields (e.g. Customer Number). |
Output attributes should not normally be specified. The system default attributes should be correct for most fields.
In SAA/CUA compliant partitions the following output attributes should always be specified (in addition to any system default attributes):
PBCN | Panel body normal output field. For normal or non-significant fields (e.g. Zip Code). |
PBCE | Panel body emphasized output field. For important, significant or key fields (e.g. Customer Number). |
An edit code or edit word should be provided for every numeric field defined in the dictionary. A suggested basic standard for edit code usage is:
Y | For any form of date field. |
4 | For numeric fields that will never be negative. |
M | For numeric fields that may be negative. |
Using a standard layout for all HELP text produces a consistency across your entire application. End users will become familiar and comfortable with the layout used.
This point should be emphasized to programmers used to "external" field definitions only being available when they use a file actually containing the field. In LANSA any field defined in the repository can be used in any RDML function.
Some of the advantages of using the LANSA repository for more than just defining the fields (or elements) which make up the records of files in the database are:
When working with fields, you should be aware of the following:
Some system variables have fixed values because they have no real meaning outside of an IBM i context. For example:
*JOBD is always QBATCH |
*CPU_NUMBER is always 0 |
*GUIDEVICE is always Y |
*OUTQNAME is always QPRINT |
*OUTQLIB is always QGPL |
*MSGQNAME is always the job name |
*MSGQLIB is always QGPL |
*GROUP_OWNER is always *USRPRF |