ADO Connection

G

Guest

When establishing an ADO connection when should I use

Set cn = CurrentProject.Connection

vs

cnn.Open "Provider=sqloledb;" & _
"Data Source=yourServerName;" & _
"Initial Catalog=yourDatabaseName;" & _
"Integrated Security=SSPI"

My app is Access (front-end) and SQL Server (back-end)

Thanks!
 
G

Guest

If your tables are linked then use the CurrentProject.Connection one. If
they are not, you will need to use the other.
--
Bob Larson
Access World Forums Super Moderator
Utter Access VIP
Tutorials at http://www.btabdevelopment.com
__________________________________
If my post was helpful to you, please rate the post.
 
G

Guest

Yes, my tables are linked. Are there any performance
advantages/disadvantages of using one method vs. the other? Thanks.
 
G

Guest

I cannot answer with absolute assuredness but I do believe that the linked
tables will work better for you since a connection is already open and JET
can help in the management of things.
--
Bob Larson
Access World Forums Super Moderator
Utter Access VIP
Tutorials at http://www.btabdevelopment.com
__________________________________
If my post was helpful to you, please rate the post.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top