Controls the default string used for separating values in data exported to text files.
String
A comma (,)
Controls the default string used for separating (or delimiting) values in data exported to text files. If an OUTPUT statement does not contain a DELIMITED BY clause, the value of this setting is used.
The first example sets the field separator to a colon in the data exported to c:\Employees.txt.
SET OPTION isql_field_separator=':'; SELECT Surname, GivenName FROM Employees WHERE EmployeeID < 150; OUTPUT TO c:\Employees.txt FORMAT TEXT; |
This code places the following data in Employees.txt:
'Whitney': 'Fran' 'Cobb':'Matthew' 'Chin':'Philip' 'Jordan':'Julie' |
The start and end characters (in this case, single quotation marks) depend on the isql_quote setting.
The next example sets the field separator to a tab in the data exported to c:\Employees.txt.
SET OPTION isql_field_separator='\t'; SELECT Surname, GivenName FROM Employees WHERE EmployeeID < 150; OUTPUT TO c:\Employees.txt FORMAT TEXT; |
This code places the following data in Employees.txt:
Surname GivenName 'Whitney' 'Fran' 'Cobb' 'Matthew' 'Chin' 'Philip' 'Jordan' 'Julie' |
The start and end characters (in this case, single quotation marks) depend on the isql_quote setting. The escape character (in this case the backslash) depends on the isql_escape_character setting.
Discuss this page in DocCommentXchange. Send feedback about this page using email. |
Copyright © 2009, iAnywhere Solutions, Inc. - SQL Anywhere 11.0.1 |