17 4 3 DBID DBUT DBII and DBIT Parameters

LANSA Technical

17.4.3 DBID, DBUT, DBII and DBIT Parameters

You use the DBID= (Database/Source Identifier) parameter with the X_RUN command to nominate the name of the database/source to which you wish to connect your application.

There are two database identifier parameters:

DBID

User Database Identifier. This is the database where your application tables reside (e.g. CUSTMST).

DBII

Internal/Repository Database Identifier. This is the database where the Visual LANSA dictionary/repository resides (e.g. LX_F03 - Field Definitions).

 

DBII= defaults to the same value as DBID=, so if they are the same you do not need to specify DBII.

Database Type

DBID= and DBII= have parameters DBUT and DBIT to indicate the type of database being used.

Note: If DBID= and DBII= are different, and if the special values *ANY, *NONE, *AS400 or *OTHER are not being used, then the DBID and DBII must have identical Visual LANSA repository and object definitions. For example: DBII=LX_LANSA, DBID=LX_USER, DBIT=MSSQLS (if provided, DBUT must be the same as DBIT), both LX_LANSA and LX_USER contain the same LANSA object definitions. Therefore, whenever an object is added or modified, it needs to be exported to other database.

The parameters DBIT and DBUT must specify the same type of database. For example DBIT=MSSQLS and DBUT=MSSQLS. It would NOT be valid to use this: DBIT=MSSQLS and DBUT=SQLANYWHERE.

DBUT

The type of user database specified in the DBID=parameter. The default values are:
MSSQLS for Windows
ODBCORACLE for Linux.

DBIT

The type of dictionary/repository database specified in the DBII= parameter. If the DBII= parameter is not supplied, the DBUT database type will be used.
The default values are:
MSSQLS for Windows
ODBCORACLE for Linux.

 

The DBUT= and DBIT= values are important because they link the database/source named in the DBID= and DBII= to the database characteristics.

The database characteristics are defined in the "x_dbmenv.dat" (Database Environment Definition File) which is described in The X_DBMENV.DAT File.

The ability to link the database/source that you specify (in, say, DBID=) to a database type (specified in DBUT=) is vital.

For example, if you specify DBUT=MSSQLS then the entire set of error messages/return codes issued by the DBMS is different to when you specify DBUT=SQLANYWHERE. These DBMS specific variations are defined in the "x_dbmenv.dat" file.

Special Values DBID=*NONE and DBII=*NONE

Visual LANSA supports the use of special values *NONE in the DBID= and DBII= parameters.

The special value *NONE indicates that no local (or connected server) database is available to the Visual LANSA application(s).

By using this option, Visual LANSA applications can be made to execute without the need to have any form of SQL/ODBC style database installed/available locally.

When using DBID=*NONE all process, function and file level security checking is disabled.

If you use *NONE with DBID or DBII, you will also use the XQ files which are described in 17.7 The .XQ* Files.

Normally you would only use this option on end user PCs or when testing an application.

To use any form of Visual LANSA or Visual LANSA development facility you must have an accessible repository database.

Special Value DBID=*ANY, DBID=*AS400 or DBID=*OTHER

Visual LANSA supports the use of special value *ANY, *AS400 or *OTHER in the DBID= parameter.

These special values indicate that no local (or connected server) database is available to the Visual LANSA application(s) and that the first function or component invoked should automatically connect to a specified server.

When using DBID=*ANY, *AS400 or *OTHER you will use the .xq* files described in 17.7 The .XQ* Files as well as a series of PSxx= parameter values that define the characteristics of the PS (Primary Server) that you wish to automatically connect to. Refer to 17.4.12 PSxx Server Parameters for the PSXX parameter requirements.

Using DBID=*ANY, AS400 or *OTHER is exactly the same as using DBID=*NONE, except that you will get an automatic connection to a nominated server system.

By using this option, Visual LANSA applications can be made to execute without the need to have any form of SQL/ODBC style database installed/available locally.

Normally you would only use this option on end user PCs or when testing an application. When using Visual LANSA for development, you must have an accessible repository database.

Valid DBID= and DBII= Parameter Settings and Recommendations

These are the valid and recommended DBID= and DBII= settings for various client (Windows)/server environments:

Environment

Comments

DBID=

DBII=

Full Client/Server to a Server:

All applications work directly to the Server DBMS and no local DBMS is required/available.

*ANY
*AS400 *OTHER

*NONE

Mixed Client/Server:

Most applications work directly to the Server's DBMS and limited local DBMS access is required.

<name>

*NONE

Heavily Client side:

Most applications work directly to the local DBMS and limited or no Server DBMS access is required.

<name>

*NONE