Option syntax
|
Description
|
---|---|
-a
|
Autocommit every statement
|
-c dir
|
Change working directory
|
-e sql-string
|
Execute the specified SQL string
If you use this option, you can only use the -a option (autocommit) issue to commit work.
|
-f filename
|
Execute SQL strings from the specified file
Use this option to execute SQL statements programmatically from a script.
|
-o filename
|
Write result set to the specified file
|
-O filename
|
Append result set to the specified file
|
-S schema_name
|
Use only the specified schema
|
-C catalog_name
|
Use only the specified catalog
|
-t
|
Print execution time per command
|
-tt
|
Print the time of prepare, execute, and fetch operations per command
|
-2
|
Creates two connections to the database
You can switch between the two connections with the command switch.
|
-u
|
▪In Unicode databases (General.InternalCharEncoding=UTF8), expect the data in character and wide character data type columns to be encoded in UTF-8.
▪In partial Unicode databases (General.InternalCharEncoding=Raw), expect the data in wide character data type columns to be encoded in UTF-8. Data in character data type columns is not converted.
|
-m
|
▪In Unicode databases (General.InternalCharEncoding=UTF8), expect the data in character and wide character data type columns to be encoded in the console’s locale/codepage, despite the settings in the server-side and client-side character data binding parameters.
▪In partial Unicode databases (General.InternalCharEncoding=Raw), expect the data in wide character data type columns to be encoded in the console’s locale/codepage, despite the settings in the server-side and client-side character data binding parameters. Data in character data type columns is not converted.
|
-M locale_name
|
▪In Unicode databases (General.InternalCharEncoding=UTF8), expect the data in character and wide character data type columns to be encoded in the specified locale/codepage.
▪In partial Unicode databases (General.InternalCharEncoding=Raw), expect the data in wide character data type columns to be encoded in the specified locale/codepage. Data in character data type columns is not converted.
The format of locale_name depends on the operating system.
For example, in Linux environments, the locale name for the code page GB18030 in Chinese/China is zh_CN.gb18030.
In Windows environments, the locale name for Latin1 code page in Finnish/Finland is fin_fin.1252.
|
-h, -?
|
Help = Usage
|
-x onlyresults
|
Print only the rows of the result set
The SQL statement for which the rows are printed must be given using the -e sql-string option.
solsql -x onlyresults -e "SELECT * FROM customerid" "tcp 2315" dba dba
|
-x pwdfile: filename
|
Read password from the file specified with filename
|
-x stoponerror
|
This option forces a shutdown of solsql immediately when an error is detected.
|
-x returnerroronexit
|
This option displays return codes for SQL errors and user raised procedure errors. The possible return codes are:
▪Code 60: the execution of an SQL statement fails
▪Code 61: a procedure call returns an error
If several SQL statements or procedure calls fail during the execution of an SQL script, the returned code is that of the first failure.
|
-x outputsql
|
This option prints out the executed SQL commands instead of only printing out the results of each operation.
|