SET NAMES

From InterBase
Jump to: navigation, search

Go Up to isql Command Reference


Specifies the active character set to use in database transactions.

SET NAMES [charset];
Argument Description

<charset>

Name of the active character set; default is NONE.

Description: SET NAMES specifies the character set to use for subsequent database connections in isql. It enables you to override the default character set for a database. To return to using the default character set, use SET NAMES with no argument.

Use SET NAMES before connecting to the database whose character set you want to specify. For a complete list of character sets recognized by InterBase, see the Language Reference.

Choice of character set limits possible collation orders to a subset of all available collation orders. Given a specific character set, a specific collation order can be specified when data is selected, inserted, or updated in a column.

Example: The following statement at the beginning of a script file indicates to set the active character set to ISO8859_1 for the subsequent database connection:

SET NAMES ISO8859_1;
CONNECT 'jupiter:/usr/InterBase/examples/employee.ib';
. . .