참고링크 [Bottom] [Top]
Carl Prothman : Connection String http://www.carlprothman.net/Default.aspx?tabid=81
ADO Connection String Samples http://www.codemaker.co.uk/it/tips/ado_conn.htm
Using Connection String Keywords with SQL Native Client http://msdn2.microsoft.com/ko-kr/library/ms130822.aspx
ConnectionStrings.com http://www.connectionstrings.com
How to connect to SQL Server 2005 http://www.connectionstrings.com/?carrier=sqlserver2005
SQL Server connection strings http://www.sqlstrings.com/SQL-Server-connection-strings.htm
Educate yourself about .NET SQL Server connection string syntax http://articles.techrepublic.com.com/5100-10878_11-6084879.html
SQL Native Client 를 위한 Connection String [Bottom] [Top]
SQL Server 2005 부터 사용되고 있는 SQL Native Client 를 사용하기 위한 연결 문자열(Connection String)에 대하여 정리한다. 자세한 사항은 참고링크를 참고한다.
OLE DB Provider Connection String Keywords [Bottom] [Top]
The following table describes the keywords that may be used with DBPROP_INIT_PROVIDERSTRING.
Keyword
Initialization property
Description
Addr
SSPROP_INIT_NETWORKADDRESS
Synonym for "Address."
Address
SSPROP_INIT_NETWORKADDRESS
The network address of an instance of SQL Server in the organization.
APP
SSPROP_INIT_APPNAME
The string identifying the application.
AttachDBFileName
SSPROP_INIT_FILENAME
The name of the primary file (include the full path name) of an attachable database. To use AttachDBFileName, you must also specify the database name with the provider string Database keyword. If the database was previously attached, SQL Server does not reattach it (it uses the attached database as the default for the connection).
Auto Translate
SSPROP_INIT_AUTOTRANSLATE
Synonym for "AutoTranslate."
AutoTranslate
SSPROP_INIT_AUTOTRANSLATE
Configures OEM/ANSI character translation. Recognized values are "yes" and "no."
Database
DBPROP_INIT_CATALOG
The database name.
DataTypeCompatibility
SSPROP_INIT_DATATYPECOMPATIBILITY
Specifies the mode of data type handling to use. Recognized values are "0" for provider data types and "80" for SQL Server 2000 data types.
Encrypt
SSPROP_INIT_ENCRYPT
Specifies whether data should be encrypted before sending it over the network. Possible values are "yes" and "no." The default value is "no."
FailoverPartner
SSPROP_INIT_FAILOVERPARTNER
The name of the failover server used for database mirroring.
Language
SSPROPT_INIT_CURRENTLANGUAGE
The SQL Server language.
MarsConn
SSPROP_INIT_MARSCONNECTION
Enables or disables multiple active result sets (MARS) on the connection if the server is SQL Server 2005 or later. Recognized values are "yes" and "no." The default is "no."
Net
SSPROP_INIT_NETWORKLIBRARY
Synonym for "Network."
Network
SSPROP_INIT_NETWORKLIBRARY
The network library used to establish a connection to an instance of SQL Server in the organization.
Network Library
SSPROP_INIT_NETWORKLIBRARY
Synonym for "Network."
PacketSize
SSPROP_INIT_PACKETSIZE
Network packet size. The default is 4096.
PersistSensitive
DBPROP_AUTH_PERSIST_SENSITIVE_AUTHINFO
Accepts the strings "yes" and "no" as values. When "no," the data source object is not allowed to persist sensitive authentication information
PWD
DBPROP_AUTH_PASSWORD
The SQL Server login password.
Server
DBPROP_INIT_DATASOURCE
The name of an instance of SQL Server in the organization.
Timeout
DBPROP_INIT_TIMEOUT
The amount of time (in seconds) to wait for data source initialization to complete.
Trusted_Connection
DBPROP_AUTH_INTEGRATED
When "yes," instructs the SQL Native Client OLE DB provider to use Windows Authentication Mode for login validation. Otherwise instructs the SQL Native Client OLE DB provider to use a SQL Server username and password for login validation, and the UID and PWD keywords must be specified.
TrustServerCertificate
SSPROP_INIT_TRUST_SERVER_CERTIFICATE
Accepts the strings "yes" and "no" as values. The default value is "no," which means that the server certificate will be validated.
UID
DBPROP_AUTH_USERID
The SQL Server login name.
UseProcForPrepare
SSPROP_INIT_USEPROCFORPREP
This keyword is deprecated, and its setting is ignored by the SQL Native Client OLE DB Provider.
WSID
SSPROP_INIT_WSID
The workstation identifier.
The following table describes the keywords that may be used with IDataInitialize::GetDataSource:
Keyword
Initialization property
Description
Application Name
SSPROP_INIT_APPNAME
The string identifying the application.
Auto Translate
SSPROP_INIT_AUTOTRANSLATE
Synonym for "AutoTranslate."
AutoTranslate
SSPROP_INIT_AUTOTRANSLATE
Configures OEM/ANSI character translation. Recognized values are "true" and "false."
Connect Timeout
DBPROP_INIT_TIMEOUT
The amount of time (in seconds) to wait for data source initialization to complete.
Current Language
SSPROPT_INIT_CURRENTLANGUAGE
The SQL Server language name.
Data Source
DBPROP_INIT_DATASOURCE
The name of an instance of SQL Server in the organization.
DataTypeCompatibility
SSPROP_INIT_DATATYPECOMPATIBILITY
Specifies the mode of data type handling to use. Recognized values are "0" for provider data types and "80" for SQL Server 2000 data types.
Failover Partner
SSPROP_INIT_FAILOVERPARTNER
The name of the failover server used for database mirroring.
Initial Catalog
DBPROP_INIT_CATALOG
The database name.
Initial File Name
SSPROP_INIT_FILENAME
The name of the primary file (include the full path name) of an attachable database. To use AttachDBFileName, you must also specify the database name with the provider string DATABASE keyword. If the database was previously attached, SQL Server does not reattach it (it uses the attached database as the default for the connection).
Integrated Security
DBPROP_AUTH_INTEGRATED
Accepts the value "SSPI" for Windows Authentication.
MARS Connection
SSPROP_INIT_MARSCONNECTION
Enables or disables multiple active result sets (MARS) on the connection if the server is SQL Server 2005 or later. Recognized values are "true" and "false." The default is "false."
Network Address
SSPROP_INIT_NETWORKADDRESS
The network address of an instance of SQL Server in the organization.
Network Library
SSPROP_INIT_NETWORKLIBRARY
The network library used to establish a connection to an instance of SQL Server in the organization.
Packet Size
SSPROP_INIT_PACKETSIZE
Network packet size. The default is 4096.
Password
DBPROP_AUTH_PASSWORD
The SQL Server login password.
Persist Security Info
DBPROP_AUTH_PERSIST_SENSITIVE_AUTHINFO
Accepts the strings "true" and "false" as values. When "false," the data source object is not allowed to persist sensitive authentication information
Provider
For SQL Native Client, this should be "SQLNCLI."
Trust Server Certificate
SSPROP_INIT_TRUST_SERVER_CERTIFICATE
Accepts the strings "true" and "false" as values. The default value is "false," which means that the server certificate will be validated.
Use Encryption for Data
SSPROP_INIT_ENCRYPT
Specifies whether data should be encrypted before sending it over the network. Possible values are "true" and "false." The default value is "false."
User ID
DBPROP_AUTH_USERID
The SQL Server login name.
Workstation ID
SSPROP_INIT_WSID
The workstation identifier.
