Results 1 to 5 of 5
Thread: Connection
- 03-14-2010, 12:25 PM #1
Member
- Join Date
- Mar 2010
- Posts
- 3
- Rep Power
- 0
Connection
Dears ,
i have an application witch connect to the SQLserver DB every 10 Second
so my question is which is the best from the below options :
1 ) open a new connection every 10 second and close it after finish
2 ) Open the connection when the application open and close only when the app close
so i am waiting for your repy
thanks
- 03-15-2010, 01:16 AM #2
2 ) Open the connection when the application open and close only when the app close
- 03-15-2010, 08:38 AM #3
Member
- Join Date
- Mar 2010
- Posts
- 3
- Rep Power
- 0
Thank you for Reply but may i ask why the second is better than the first?
- 03-15-2010, 10:02 AM #4
Database connections are costly and it hits the performance if u keep it open for long.
Ramya:cool:
- 03-15-2010, 12:04 PM #5
Member
- Join Date
- Mar 2010
- Posts
- 3
- Rep Power
- 0
Similar Threads
-
connection to database
By buston01 in forum JDBCReplies: 4Last Post: 02-21-2010, 01:32 AM -
we implement connection pooling ourselves, but why it always out of connection ?
By zengqingyi12 in forum JDBCReplies: 7Last Post: 10-20-2009, 10:34 AM -
TCP Connection
By Blacknight in forum New To JavaReplies: 3Last Post: 06-04-2009, 01:02 PM -
Keep my TCP connection alive
By eggmanpete in forum Advanced JavaReplies: 4Last Post: 03-02-2009, 06:11 AM -
no connection
By even in forum JDBCReplies: 15Last Post: 01-02-2008, 01:50 PM


LinkBack URL
About LinkBacks
Reply With Quote
Bookmarks