|
|
|
| |
Driver=
{SQL Server};
Server=
myServerAddress;
Database=
myDataBase;
Uid=
myUsername;
Pwd=
myPassword;
| |
| COPY TO CLIPBOARD |
|
| |
Driver=
{SQL Server};
Server=
myServerAddress;
Database=
myDataBase;
Trusted_Connection=
Yes;
| |
| COPY TO CLIPBOARD |
|
This one is a bit tricky. First you need to set the connection object's Prompt property to adPromptAlways. Then use the connection string to connect to the database. | |
oConn.Properties("Prompt") = adPromptAlways
Driver=
{SQL Server};
Server=
myServerAddress;
Database=
myDataBase;
| |
| COPY TO CLIPBOARD |
|
|
|
| |
Provider=
sqloledb;
Data Source=
myServerAddress;
Initial Catalog=
myDataBase;
User Id=
myUsername;
Password=
myPassword;
| |
| COPY TO CLIPBOARD |
|
| |
Provider=
sqloledb;
Data Source=
myServerAddress;
Initial Catalog=
myDataBase;
Integrated Security=
SSPI;
| |
Use serverName/instanceName as Data Source to use a specific SQL Server instance. Please note that the multiple SQL Server instances feature is available only from SQL Server version 2000 and not in any previous versions. | | COPY TO CLIPBOARD |
|
This one is a bit tricky. First set the connection object's Provider property to "sqloledb". Thereafter set the connection object's Prompt property to adPromptAlways. Then use the connection string to connect to the database. | |
oConn.Provider = "sqloledb" oConn.Properties("Prompt") = adPromptAlways
Data Source=
myServerAddress;
Initial Catalog=
myDataBase;
| |
| COPY TO CLIPBOARD |
|
| |
Provider=
sqloledb;
Data Source=
190.190.200.100,1433;
Network Library=
DBMSSOCN;
Initial Catalog=
myDataBase;
User ID=
myUsername;
Password=
myPassword;
| |
| COPY TO CLIPBOARD |
|
|
|
| |
Data Source=
myServerAddress;
Initial Catalog=
myDataBase;
User Id=
myUsername;
Password=
myPassword;
| |
| COPY TO CLIPBOARD |
|
This connection string produce the same result as the previous one. The reason to include it is to point out that some connection string keywords have many equivalents. | |
Server=
myServerAddress;
Database=
myDataBase;
User ID=
myUsername;
Password=
myPassword;
Trusted_Connection=
False;
| |
| COPY TO CLIPBOARD |
|
| |
Data Source=
myServerAddress;
Initial Catalog=
myDataBase;
Integrated Security=
SSPI;
| |
| COPY TO CLIPBOARD |
|
This connection string produce the same result as the previous one. The reason to include it is to point out that some connection string keywords have many equivalents. | |
Server=
myServerAddress;
Database=
myDataBase;
Trusted_Connection=
True;
| |
Use serverName/instanceName as Data Source to use a specific SQL Server instance. Please note that the multiple SQL Server instances feature is available only from SQL Server version 2000 and not in any previous versions. | | COPY TO CLIPBOARD |
|
| |
Data Source=
190.190.200.100,1433;
Network Library=
DBMSSOCN;
Initial Catalog=
myDataBase;
User ID=
myUsername;
Password=
myPassword;
| |
| COPY TO CLIPBOARD |
|
| |
Server=
myServerAddress;
Database=
myDataBase;
User ID=
myUsername;
Password=
myPassword;
Trusted_Connection=
False;
Packet Size=
4096;
| |
| COPY TO CLIPBOARD |
|
|
|
| |
Provider=
MSDataShape;
Data Provider=
SQLOLEDB;
Data Source=
myServerAddress;
Initial Catalog=
myDataBase;
User ID=
myUsername;
Password=
myPassword;
| |
| COPY TO CLIPBOARD |