Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 Windows Services and SQL Connection best practice?

Author  Topic 

phrankbooth
Posting Yak Master

162 Posts

Posted - 2007-12-26 : 11:39:44
When doing DB tasks from a Windows Service is it better to keep a connection open during the life of the service or is it better to open a connection every time you want to do something on the DB?

--Thanks

--PhB

spirit1
Cybernetic Yak Master

11752 Posts

Posted - 2007-12-26 : 13:42:12
open-close each time. connection pooling works anyway.

_______________________________________________
Causing trouble since 1980
blog: http://weblogs.sqlteam.com/mladenp
SSMS Add-in that does a few things: www.ssmstoolspack.com <- new version out
Go to Top of Page
   

- Advertisement -