iSQL Environment Variables
iSQL Environment Variables#
ALTIBASE_HOME#
ALTIBASE_HOME is the environment variable which must be configured in order to used iSQL.
Although it is automatically configured when the server is installed in general, but the user should directly configure since there might be a chance of conflict with the environment variables in the server.
ALTIBASE_PORT_NO#
This is the port number of the server to connect to. This can be specified either by using the -PORT option or in altibase.properties.
If no designated port number can be found (in descending order of precedence) in the -PORT option, in the environment variable ALTIBASE_PORT_NO, or in altibase.properties, a prompt to enter the port number will appear.
ALTIBASE_SSL_PORT_NO#
The port number of the server iSQL is to connect to on SSL/TLS.
The -PORT option, environment variables, ALTIBASE_SSL_PORT_NO, the properties in the altibase.properties file take priority in this order as the port number in SSL. On omission, the command prompt asks the user to enter the port number.
ALTIBASE_NLS_USE#
This is the character set used to display retrieved results to the user.
-
US7ASCII
-
KO16KSC5601
-
MS949
-
BIG5
-
GB231280
-
MS936
-
UTF8
-
SHIFTJIS
-
MS932
-
EUCJP
This can be set either using the -NLS_USE option or in altibase.properties.
If NLS_USE is not specified using the -NLS_USE option, the environment variable ALTIBASE_NLS_USE, or altibase.properties (in descending order of precedence), US7ASCII is used as the default character set.
ALTIBASE_NLS_NCHAR_LITERAL_REPLACE#
By default, iSQL converts an entire query string to the database character set before sending the data to the database. This behavior can be prevented for a given string literal by setting this property to 1 and placing the "N" character in front of the string literal.
A property setting of 1 instructs iSQL to search for the "N" character in front of every string literal. If the "N" character is found, iSQL sends the string to the database without converting it to the database character set. This is useful when it is desired to use NCHAR type data that are encoded differently from the database character set.
-
0: convert all strings to the database character set without checking for the "N" character
-
1: do not convert strings that are preceded by the "N" character to the database character set
Note: Setting this variable to 1 can be expensive in terms of usage of client resources.
ISQL_CONNECTION#
When Altibase is operated with a client-server arrangement, the user can select the client-server protocol that is suitable for the operating environment by setting environment variables. Altibase supports the TCP/IP, IPC, IPCDA, and Unix domain SSL socket protocols. The default protocol for communication with Altibase servers is TCP/IP.
- TCP
- UNIX
- IPC
- IPCDA
- SSL
- IB
Note that when using the IPC or IPCDA protocol the value of Altibase properties related to the IPC channel (IPC_CHANNEL_COUNT or IPCDA_CHANNEL_COUNT) must be considered.
The following example shows how to set the environment variable when using the IPC protocol:
CSH: setenv ISQL_CONNECTION IPC
SH: ISQL_CONNECTION=IPC; export ISQL_CONNECTION
Note: If the value set for the ISQL_CONNECTION environment variable is UNIX or IPC, and the remote server is specified for the -s option, a warning message that the setting for ISQL_CONNECTION has been ignored is output and iSQL connects to the remote server using TCP.
ISQL_BUFFER_SIZE#
The size of the buffer in which to store queries can be set using this environment variable.
CSH: setenv ISQL_BUFFER_SIZE 128000
SH: ISQL_BUFFER_SIZE = 128000; export ISQL_BUFFER_SIZE
ALTIBASE_DATE_FORMAT#
When retrieving Date type data using a SELECT statement, the environment variable ALTIBASE_DATE_FORMAT can be used to change the default date format, which is YYYY/MM/DD HH:MI:SS, to some other date format.
Ex) For Born, Korn, or Bash Shell
export ALTIBASE_DATE_FORMAT='DD-MON-YYYY'
ISQL_EDITOR#
This environment variable can be used to change the default editor (Ex: /bin/vi ).
CSH: setenv ISQL_EDITOR /usr/bin/ed
SH: ISQL_EDITOR=/usr/bin/ed; export ISQL_EDITOR
ALTIBASE_IPC_FILEPATH#
In a Unix environment, if a client and the server have different values for ALTIBASE_HOME, they will not be able to connect via IPC since they have different Unix domain socket paths. In this case, in order to be able to connect via IPC, it is necessary to set the ALTIBASE_IPC_FILEPATH environment variable or the -IPC-FILEPATH iSQL option to the $ALTIBASE_HOME/trc/cm-ipc file used by the server.
IPCDA_FILEPATH#
In a Unix environment, if a client and the server have different values for ALTIBASE_HOME, they will not be able to connect via IPCDA since they have different Unix domain socket paths. In this case, if IPCDA_FILEPATH environment variables or -IPCDA -FILEPATH is specified as a file of $ALTIBASE_HOME/trc/cm-ipcda in the server connection via IPCDA is possible because the server and client can use the identical socket file.
ALTIBASE_TIME_ZONE#
This environment variable sets the time zone of the client. If DB_TZ is specified for this option, the time zone is defaulted to that of the database server.
This environment variable can be set with time zone names like Asia/Seoul, abbreviations such as KST and UTC offset values as +09:00 are valid for specification.