February 9, 2008 at 6:21 pm
We have a nagging issue here in our application side, which I was trying to troubleshoot and reach no where. Can I have your valuable inputs for resolving/understanding the root cause of the issue?
3709-The connection cannot be used to perform this operation. It is either closed or invalid in this context
This error is not coming regularly (twice it happened and after the program is running successfully with out any problem). Problem having exe is running every 2 minutes interval.
Most of the sites saying this is something related to code written in the application but if that is the case why this error is not happening continuously? The problem having exe is running past 4 months with 2 minutes interval and suddenly thrown this error.
I found one MS site describing about this error but not able to find any fixes for this issue (http://support.microsoft.com/kb/839428). We are on the process of upgrading the operating system with SP2; will this help us to resolve this issue? Please advice.
Details
Windows 2003 with SP1,MDAC 2.8,SQL 2005 with SP1,VB Application
February 10, 2008 at 2:47 am
figure out in what application query sequence the error occurs !
Then provide some connection details and the exact cmd with its
properties.
Start sqlprofiler to capture the load. If your programmes followed the guidelines,
you should be able to filter base on the provided application name.
If the the error occurs, it will be visible in the trace data, if not your error
is raised elsewhere.
Johan
Learn to play, play to learn !
Dont drive faster than your guardian angel can fly ...
but keeping both feet on the ground wont get you anywhere :w00t:
- How to post Performance Problems
- How to post data/code to get the best help[/url]
- How to prevent a sore throat after hours of presenting ppt
press F1 for solution, press shift+F1 for urgent solution 😀
Need a bit of Powershell? How about this
Who am I ? Sometimes this is me but most of the time this is me
February 11, 2008 at 2:21 pm
Have run into this problem a few times when using VB in the application and found it to be due to:
1. On some path such as
IF This THEN
Call Sub_1 ( ........)
ELSE
Call Sub_2 (........)
ENDIF
one of the subs is not used very often(say Sub_2) and it closes the connection, so when the code invokes Sub_1 the error occurs.
Solved my problem by inserting code before each call to a command object to invoke a stored or dynamic procedure:
IF Connection.State <> adStateOpen Then
Connection.open
EndIf
Command.ActiveConnection = Connection
Hope this might help
January 13, 2012 at 7:16 am
You can also get this error if using MS Access as the database, and the database is open/locked by an instance of MS Access.
I know this is SQL Server Central, but...
January 14, 2012 at 4:17 am
Posted Sunday, February 10, 2008 6:51 AM
Viewing 5 posts - 1 through 4 (of 4 total)
You must be logged in to reply to this topic. Login to reply