8. Setting Environment Variables : Customization of Query Runtime Environment : DBNAME_SQL_INIT
Share this page                  
This variable applies to the line-based SQL Terminal Monitor only. DBNAME_SQL_INIT points to SET statements within a file that are executed whenever this Vector environment variable takes effect.
DBNAME_SQL_INIT affects users who connect to the database specified by DBNAME through the SQL Terminal Monitor. If set globally, it affects all users of DBNAME. If set interactively or locally, it affects only this user.
Global setting is with ingsetenv, or locally in the user’s .login, .profile, or .cshrc file.
Setting the DBNAME_SQL_INIT environment variable is equivalent to executing \filename in the SQL Terminal Monitor each time you connect to DBNAME.
To define the Vector environment variable DBNAME_SQL_INIT
Use the following command syntax at the operating system prompt:
For example:
MYDB_SQL_INIT=/usr/george/mystartfile export MYDB_SQL_INIT
where DBNAME is the name of the database and must be in uppercase.
The initialization file contains lines in the following format:
Multiple SET statements must be separated with a semicolon (;). The entire file must end with “\g”.