dehranph
Sun Feb 05 07:06:01 CST 2006
hello jacky,
connection is resource extensive and as my personal practice I open
connection as late as possible and close it as early as possible. The
reason for this is scalability which measn you allow you application to
be used by as many users as possible.
look at it this way, if your server allows 10 concurrent connections
only and your code leaves those connections opened. If you code that on
Session_Start and Session_End, it means you only allow 10 connections
exclusive to 10 user sessions. It means in worst cases, other users may
not be able to connect and ur not fully utilizing your servers.
connection pooling plays important role here since you dnt have to
re-create existing connections if you are acessing the sama db server
and database.
regards,
rodel e. dagumampan
http://community.devpinoy.org/blogs/dehranph