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.
Author |
Topic |
olibara
Yak Posting Veteran
94 Posts |
Posted - 2015-04-19 : 06:46:47
|
HelloI'm testing a Mobile Application (Windows CE) The application is sending information on a SQL server 2008 DatabaseBut in case of connexion failure I switch to Off-Line modeTo do that I'm detecting the ADO exception when connecting to DBBut I need to reduce the attempt time by using the Connexion Timeout parameter in the connexion stringBut it does not work as expectedWhen NO connexion TimeOut is specified, it takes +/- 20 seconds before to get an exception (the documentation is talking about a default setting of 15 seconds)When I specify a TimeOut of 1, it takes about 10 seconds before to get the ExceptionSo I can say that this parameter have an effect anyway but it does not gives the expected result (15 seconds or 1 seconds)Any Idea ?Thanks for your Help |
|
SwePeso
Patron Saint of Lost Yaks
30421 Posts |
Posted - 2015-04-19 : 13:34:32
|
Show us your full connection string. Microsoft SQL Server MVP, MCT, MCSE, MCSA, MCP, MCITP, MCTS, MCDBA |
|
|
olibara
Yak Posting Veteran
94 Posts |
Posted - 2015-04-20 : 01:09:32
|
Thank for your replyBut I find the answer But the connection string will not helpIn fact setting the time out in the connexion string just define the MINIMUM time out for connexion to the DatabaseNOT the time spent to try to establish a connexion to the Network !For my purpose I need to step down to test network connectivity |
|
|
SwePeso
Patron Saint of Lost Yaks
30421 Posts |
|
olibara
Yak Posting Veteran
94 Posts |
Posted - 2015-04-22 : 13:42:15
|
Thank you Swepeso20+ Year and one more day and we can still learn !http://improve.dk/controlling-sqlconnection-timeouts/But I should have say MAXIMUM time of active connexion to the database And as I said this not include the time spended to detect networkSo for this matter, the connexion Timeout will parameter not help |
|
|
|
|
|
|
|