Server options changed by ODBC

The SQL Anywhere ODBC driver sets some temporary server options when connecting to a SQL Anywhere database. The following options are set as indicated.

  • date_format   yyyy-mm-dd

  • date_order   ymd

  • isolation_level   based on the SQL_ATTR_TXN_ISOLATION/SA_SQL_ATTR_TXN_ISOLATION attribute setting of SQLSetConnectAttr. The following options are available.
    SQL_TXN_READ_UNCOMMITTED
    SQL_TXN_READ_COMMITTED
    SQL_TXN_REPEATABLE_READ
    SQL_TXN_SERIALIZABLE
    SA_SQL_TXN_SNAPSHOT
    SA_SQL_TXN_STATEMENT_SNAPSHOT
    SA_SQL_TXN_READONLY_STATEMENT_SNAPSHOT

    For more information, see Choosing ODBC transaction isolation level.

  • time_format   hh:nn:ss

  • timestamp_format   yyyy-mm-dd hh:nn:ss.ssssss

  • timestamp_with_time_zone_format   yyyy-mm-dd hh:nn:ss.ssssss +hh:nn

To restore the default option setting, execute a SET statement. Here is an example of a statement that will reset the timestamp_format option.

set temporary option timestamp_format =