Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.

SQL Anywhere 11.0.1 » SQL Anywhere Server - Database Administration » Administering Your Database » SQL Anywhere graphical administration tools » Using Interactive SQL » Interactive SQL options


isql_escape_character option [Interactive SQL]

Controls the escape character used in place of unprintable characters in data exported to text files.

Allowed values

Any single character


A backslash ( \ )


When Interactive SQL exports strings that contain unprintable characters (such as a carriage return), it converts each unprintable character into a hexadecimal format and precedes it with an escape character. The character you specify for this setting is used in the output if your OUTPUT statement does not contain an ESCAPE CHARACTER clause. This setting is used only if you are exporting to an text file.

See also

Create a table that contains one string value with an embedded carriage return (denoted by the "\n" in the INSERT statement). Then export the data to c:\escape.txt with a # sign as the escape character.

CREATE TABLE escape_test( text varchar(10 ) );
INSERT INTO escape_test VALUES( 'one\ntwo' );
SET OPTION isql_escape_character='#';
SELECT * FROM escape_test;
OUTPUT TO c:\escape.txt FORMAT TEXT;

This code places the following data in escape.txt:


The pound sign (#) is the escape character and x0A is the hexadecimal equivalent of the \n character.

The start and end characters (in this case, single quotation marks) depend on the isql_quote setting.