X-Git-Url: http://git.kpe.io/?p=clsql.git;a=blobdiff_plain;f=doc%2Fappendix.xml;fp=doc%2Fappendix.xml;h=da94765270690e8b7576c0a34e5d5171ea373025;hp=1fdbed0961cc581db0e248cdca7f3a995e1221e3;hb=212ad16663baf5d75f63dd3e5b613c701c996d2f;hpb=200e73473d48ee3b574484ecd6a38790ba4fc732 diff --git a/doc/appendix.xml b/doc/appendix.xml index 1fdbed0..da94765 100644 --- a/doc/appendix.xml +++ b/doc/appendix.xml @@ -438,7 +438,7 @@ This file can contain forms to set site-specific paths as well as change Connection Specification Syntax of connection-spec - (dsn user password) + (dsn user password &key connection-string) Description of connection-spec @@ -463,6 +463,15 @@ This file can contain forms to set site-specific paths as well as change use for authentication. + + connection-string + + Raw connection string passed to the underlying + ODBC driver. Allows bypassing creating a DSN on the + server. + + + @@ -478,6 +487,26 @@ This file can contain forms to set site-specific paths as well as change + Connect Examples + + +;; assumes a "mssql" DSN is configured on the lisp host, specifying database server +;; and database name. +> (clsql:connect '("mssql" "database-user" "database-password") + :database-type :odbc) +=> #<CLSQL-ODBC:ODBC-DATABASE mssql/database-user OPEN {100756D123}> + +;; no DSN on the lisp host, specify connection information via :connection-string +> (clsql:connect '("friendly-server-name" "friendly-username" "" + :connection-string "DRIVER={FreeTDS};SERVER=mssql-server;DATABASE=database-name;UID=database-user;PWD=database-password;PORT=1433;TDS_Version=8.0;APP=clsql") + :database-type :odbc) +=> #<CLSQL-ODBC:ODBC-DATABASE friendly-server-name/friendly-username OPEN {100756D123}> + + The friendly-server-name + and friendly-username are only used when + printing the connection object to a stream. + +