*SQLTABLEDB (SETMODE)


PLBCMP Only, 9.5

*SQLTABLEDB={dbname}

 

The *SQLTABLEDB list control defines the name of a database connection from the Sun_Sqlio_Databases system table that is the default connection for accessing application data tables.

 

{dbname} is a valid database name.

Note:

  1. The {dbname} parameter is processed to determine the appropriate connection information that is required to make a connection to a database engine that contains the application SQL data tables used for SQLIO.

  2. The {dbname} parameter can be specified as 'Default' to reset to the runtime default database as initially loaded using the runtime INI file settings. Also, the {dbname} parameter can be a user defined database name that has been configured in the current runtime database. If a user defined database name is specified, this database name must exist in the current runtime database table named 'Sun_Sqlio_Database'.

  3.  

    Example using runtime Default:

     

           SETMODE *SQLTABLEDB="Default"

     

    Example using user defined Database Connection name:

     

           SETMODE *SQLTABLEDB="MySqlioTables"

     

  4. The {dbname} parameter can be specified as a connection string that includes all of the information required to make a direct connection to a database engine that has the SQLIO application data tables. In this case, the {dbname} parameter string can be specified using keywords with assigned string data that can optionally include single or double quote characters.

  5.  

    Format of SETMODE *SQLTABLEDB={dbname} connection string:

     

             Name=<string>

             Host=<string>

             User=<string>

             Pass=<string>

             Conn=<string>

             Ext=<string>

             Flags=<dnum>

             Driver=<dnum>

             SqlType=<dnum>

     

    The description of the *SQLTABLEDB={dbname} SQLIO connection string keywords can be found in the PL/B Language Reference manual under the section named SQLIO Schema File Format in the <Database> Schema Record' descriptions.

     

    Example:

     

    DbSqlIoTables INIT "Name=SqlDevSpot,":

                         "Host='DBADO;;DSN=SqlIoDev',":

                         "Driver=2,":

                         "SqlType=2"

    .

                  SETMODE *SQLTABLEDB=DbSqlIoTables

     

  6. When a SETMODE *SQLTABLEDB instruction is executed with a user defined {dbname}, a reference to the connection data is created and exists until the runtime is terminated. In addition, if a second instruction references this {dbname} parameter database name, the original connection information is used.

 

 

See Also: List Controls (SETMODE), SETMODE

 



PL/B Language Reference *SQLSCHEMADB (SETMODE) *SRVBUFMODE (SETMODE)