Connection failing intermittently

  • I have an VB application written with VS2008 that has been running against a third party applications DB's on SQL2000 servers successfully for years, but when I updated it to use the new version running on SQL2008 servers it starts running and seems to work fine but then fails with :

    [Microsoft][SQL Server Native Client 10.0]Named Pipes Provider: Could not open a connection to SQL Server [2].

    If I debug the application in VS and when the error occurs hit Continue (sometimes twice) the application continues normally, though it will fail several times before I get all the way through. I have checked the final data once this happens and it is totally complete.

    The failure occurs on one or the other of two UPDATE statements for the two tables that are being populated with data extracted from other tables that are on different servers (some 2000, some 2008 during conv. period) different instances, and in different DB's (one for each of our stores). The output tables for the application have been moved from 2000 to one of the 2008 servers.

    I am unable to determine why the connections seem to be dropping as I only open the connection at the beginning of the routine and close once all data has been written. I have checked the logs on my local box, the SQL box (both SQL and system) and can find no indication of the problem.

    I don't know if this is a problem with the code, the server, or something else. I am attaching the relevant section of the code w/ passwords etc. changed but nothing else. If more of the code is required I would gladly update this. The two updated causing the failure are recordsets are the rsDistOut and rsTransOut in attached code.

    Can anyone help with what the problem might be or suggest how I can go about determining what it is? Any assistance would be greatly appreciated!


    If you don't stand for something, you'll fall for anything!,

    Don Urquhart

  • I have found one indication of a problem when I run this application.

    On the server that has the SQL2008 DB that I'm writting to, I notice that there is a high number of login/logoff events for my network user id during the period this application is running. The logon period always seems to be between 10 and 12 seconds until I see the logoff and the next logon is at most 2 seconds after the logoff with most being within a second.

    Could there be a timeout setting in either the SQL setup or the server itself that is causing the drops?


    If you don't stand for something, you'll fall for anything!,

    Don Urquhart

Viewing 2 posts - 1 through 1 (of 1 total)

You must be logged in to reply to this topic. Login to reply