November 23, 2006 at 1:29 pm
Hi folks -
I'm using MDAC 2.62.7400.1 (as reported by the MDAC detection utility). I'm performing a database restore using the following command delivered to the ODBC driver:
RESTORE DATABASE [test] FROM DISK = 'test.bkp' WITH REPLACE
...which works about 50% of the time. The 50% of the time it doesn't work, it returns a "Timeout expired" message, but only after about fifteen to eighteen seconds or so, then leaves the database in a 'is being restored' state, and unusable. When the restore works ok, it takes just a few seconds longer. Is this timeout fixable by increasing some value somewhere? I've changed the setting in the ODBC connection page from its default of thirty seconds but this has not stopped the timeout (possibly because the timeout occurs before the default 30 seconds anyway). And if so, what SQL command do I need to issue to increase it, as this needs to be done programatically. I've been through the docs, but haven't seen anything related to increasing general timeouts (rather than lock timeouts). I'm using MFC with Visual C++ 6.0. The exact error message is "Timeout expired\nState:S1T00,Native:0,Origin:[Microsoft][ODBC SQL Server Driver]".
Much thanks for help that anybody can provide with this. FWIW, I'm on a client site a long way from home, where this issue is rapidly turning into an acrimonious show-stopper.
November 24, 2006 at 9:00 am
Can you try updating the MDAC version (the latest is something like 2.8)? That might solve the issue.
-SQLBill
November 24, 2006 at 5:27 pm
Did you check if someone was using this database?
November 25, 2006 at 11:37 am
Any reason why you're not connecting with Query Analyzer?
Viewing 4 posts - 1 through 4 (of 4 total)
You must be logged in to reply to this topic. Login to reply