Home > Archive > MS SQL Server New Users > March 2006 > Misleading Exception?









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Misleading Exception?
Chris Arnold

2006-03-07, 11:24 am

Hi All,

I have a SqlCommand object that is altering the value of a column on 1
record in a table in SQL Server 2000.

This table has a number of triggers on it.

I am getting a System.Data.SqlClient.SqlException (Timed Out) when calling
this.

The CommandTimeout is set to 360 but the exception occurs well before that.

Q. Is this a misleading exception? What could be causing it? Am I
creating a weird sort of lock somewhere and this is the only exception it
can think to throw?

Many thanks,

Chris


Mike Hodgson

2006-03-07, 8:24 pm

Personally, I would take the T-SQL code in the SqlCommand object and try
running that batch in Query Analyzer. If any error messages are
returned from the server they should be displayed in their entirety in
the QA results window (or the "messages" window if you're using the
results grid). If it works fine and no errors are returned then the
error is probably not coming from the server but more likely a transport
layer between the client & the server.

--
*mike hodgson*
http://sqlnerd.blogspot.com



Chris Arnold wrote:

>Hi All,
>
>I have a SqlCommand object that is altering the value of a column on 1
>record in a table in SQL Server 2000.
>
>This table has a number of triggers on it.
>
>I am getting a System.Data.SqlClient.SqlException (Timed Out) when calling
>this.
>
>The CommandTimeout is set to 360 but the exception occurs well before that.
>
>Q. Is this a misleading exception? What could be causing it? Am I
>creating a weird sort of lock somewhere and this is the only exception it
>can think to throw?
>
>Many thanks,
>
>Chris
>
>
>
>


Sponsored Links





Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive | Programming forum archive

Copyright 2008 droptable.com