Controls the escape character used in place of unprintable characters in data exported to text files.
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.
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.
|Envoyer votre avis sur cette page par email.||Copyright © 2009, iAnywhere Solutions, Inc. - SQL Anywhere 11.0.1|