Thursday, March 22, 2012

Connection pool needed?

From what I understand, some database drivers provide automatic database pooling, in the sense that when an application closes a connection, it is not dropped until after a certain timeout. If the same, or another application, request a connection then the "pooled" one is returned.

What's the situation with C#, .NET Compact Edition and SQLce? Is it a performance hit to open and close a connection, or is some kind of automatic pooling in effect?

Thanks.

Martin

SQL CE is a single user database, so I find that having a single connection during the lifetime of your application is best. There is some overhead in opening and closing connections.

No comments:

Post a Comment