cancel
Showing results for 
Search instead for 
Did you mean: 

Defining ODBC Settings in connection string?

2,279

I'm wanting to know whether we can define these ODBC settings as part of a connection string or as connection properties:

  1. "Microsoft applications (Keys in SQLStatistics)"
  2. Delphi applications
  3. Delay AutoCommit until statement close

We are researching whether we can connect to an SQL Anywhere database without first having to define a ODBC DSN as this will make maintenance and support a bit easier especially in a multi-tenant environment.

I have read through the document at http://dcx.sybase.com/index.html#sa160/en/sacshelp/config-odbc-page.html however it does not go into further detail about each option.

Accepted Solutions (1)

Accepted Solutions (1)

VolkerBarth
Contributor

Have you already tried to do so (as part of the research:))?

I don't know whether these entries are accepted as connection parameters or should be specified as part of the InitString connection parameter but you can get the according property names and settings simply by looking at the ODBC DSN entry:

KeysInSQLStatistics=YES
Delphi=NO
LazyAutocommit=YES

Update: According to Graeme, the answer is you can use those entries as optional connection parameters.

FWIW, they are also documented and explained here (as part of the DBDSN utility):

ODBC connection parameters

graeme_perrow
Advisor
Advisor

I converted this to an answer since it contains the correct answer to the question, and now we can upvote it. Note that you can get a list of all supported connection parameters using dbdsn -cl.

0 Kudos

Thanks @Volker. We had suspected it may be the case, but just wanted to confirm it - which Graeme has done.

Answers (0)