Administrator Guide : Using solidDB® data management tools : solidDB® Export (solexp) : Starting solidDB® Export (solexp)
  
Starting solidDB® Export (solexp)
Start solidDB® Export with the command solexp, followed by argument options.
If you start solidDB® Export without any arguments, a summary of the arguments with a brief description is displayed.
The syntax for starting solexp is:
solexp [options] [network_name] username [password] {tablename | *}
where
options can be:
Option syntax
Description
-c dir
Change working directory
-C catalogname
Set the default catalog from where data is read from or written to
-e sql_string
Execute SQL string for export
-f filename
Execute SQL string from file for export
-l filename
Write log entries to this file
-L filename
Append log entries to this file
-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.
See Using solidDB® tools with Unicode for more information.
-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.
-o filename
Write exported data to this file
This option can be used only when exporting the data of a single table.
The default data and control file name is the same as the exported table name (<tablename>.dat and <tablename>.ctr).
-p
Preserve case of schema and table names
-s schema_name
Use only this schema for export
-S
Create SQL insert into clauses
-A
Add attribute names to insert clause
-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.
See Using solidDB® tools with Unicode for more information.
-x pwdfile: filename
Read password from the file
-h, -?
Help = Usage
network_name is the network name of a solidDB® server that you are connected to. The given network name must be enclosed in quotation marks. For more information, see Managing network connections. Logical data source names can also be used with the solidDB® tools.
username is required to identify the user and to determine the authorization level of the user authorization. Without appropriate rights, command execution is denied.
password is the password of the user for accessing the database. The password is mandatory, if the password is not read from a file (defined with option -x pwdfile: filename), or optional, if the password is read from a file.
tablename or * is mandatory. The symbol * can be used to export all tables with one command. However, it cannot be used as a wildcard. In some environments you might need to escape the * with double quotation marks ("*").
Note The -t tablename (Export table) option is still supported in order to keep old scripts valid.
Example
solexp -CMyCatalog -sMySchema -ofile.dat "tcp 1315" MyID My_pwd MyTable
Error messages
When there is an error in the command line entry, solexp gives you a list of the possible syntax options as a result. Check your entries on the command line.
Username, password and table name are always expected: For example, with the command
solexp "tcp 1315" dba dba
you may receive a SOLID Communication Error 21306. This is because there was no server listening to the environment-dependent default. In this case, solexp assumes: "tcp 1315" is the username, dba is the password, and dba is the table name. In this case, the correct command is, for example:
solexp "tcp 1315" dba dba myTable
If you omit the name of the schema, you may get a message saying that the specified table could not be found. The solexp program cannot find the table if it does not know which schema to look in.
See also
solidDB® Export (solexp)