com.inet.tds.SQLException and Opta 2000 driver

From: Cathy (cathywigzell_at_yahoo.co.uk)
Date: 02/11/04


Date: 11 Feb 2004 08:09:33 -0800

I'm using the Opta 2000 driver to access a remote MS SQL database. If
the connection to the remote database has been lost (e.g. the server
it's on may have been rebooted) then the driver throws a
com.inet.tds.SQLException with the message 'Connection reset by peer:
socket write error'. The SQLException has a private member variable,
a, with a declared type of Throwable but a concrete type of
SocketException. It would be very useful to get hold of the
SocketException. For example,

if ( exception.a instanceof SocketException )
{
    // try to open a new connection to the database
}

How can I
a) get hold of com.inet.tds.SQLExcpetion.a, or
b) use an alternative method to determine that the connection should
be reopened?

Many thanks for your help,
Cathy



Relevant Pages

  • Re: asynchronous socket communication
    ... | This class is taking care of sending strings to LED display. ... | When connection is established OnClientConnect method is called to call ... | private void OnClientConnect ...
    (microsoft.public.dotnet.languages.csharp)
  • RE: An existing connection was forcibly closed by the remote host
    ... When the connection is attempted the IIS server returns the ... > An existing connection was forcibly closed by the remote host ... > [SocketException: An existing connection was forcibly closed by the ... > endReceivalIfException, Boolean readSession, Boolean ...
    (microsoft.public.dotnet.framework)
  • Microsoft Office 2003 Web Components Error #27043
    ... I have an HTML webpage that uses Office 2003 webcomponents to display a ... pivot table of data populated from an SQL Database. ... webpage from Internet Explorer or Outlook 2003 and I'm plugged into a network ... connection), it works through Internet Explorer but not through Outlook. ...
    (microsoft.public.outlook.program_vba)
  • Re: Linked Tables
    ... You can save User ID & and Password with linked table connection string. ... I note that the Access database does not seem to use an ODBC connection to ... up an ODBC connection to the SQL database and linked the table to the SQL ... Password (ODBC set up with SQL authenticatiion). ...
    (microsoft.public.access.devtoolkits)
  • RE: Unable to connect to SQL remotely through SqlConnection???
    ... SqlConnection sqlConn2 = null; ... it can easily access the remote SQL database. ... This are the connection strings that I've tried, ...
    (microsoft.public.dotnet.languages.csharp)