You are here: Re: ADO.NET Timeout Exception - I have tried everything « MsSQL Server « IT news, forums, messages
Re: ADO.NET Timeout Exception - I have tried everything

Posted by Erland Sommarskog on 05/19/06 00:57

(sorcerdon@gmail.com) writes:
> Im a creating a data set and populating it with a call to a store proc.
>
> Its a complex stored proc with the end result as an insert to a temp
> table. Then I do a select from the temp table - in the store proc.
>
>
> I get the following sqlException error on the following line:
> DataAdapterName.Fill(DataSetName, "TableName")
>
>
> The error is:
> Timeout expired. The timeout period elapsed prior to completion of the
> operation or the server is not responding.

How long time does take before you get the error? Since you say
that you've set the command timeout to 500, I expect it to take
three minutes, but I want to verify.

> If I use a DataReader with the same storeProc, it works fine.

Since DataAdapter.Fill more or less is just a wrapper on ExecuteReader,
this is funky. (Then again, that sounds like you have a workaround.)

I get the feeling that there is a blocking issue lurking here. When
you run DataAdapter.Fill and are waiting for it to timeout, run sp_who
from Query Analyzer and look for non-zero values in the Blk column.
In such case the spid in the Blk column blocks the spid on this row.

--
Erland Sommarskog, SQL Server MVP, esquel@sommarskog.se

Books Online for SQL Server 2005 at
http://www.microsoft.com/technet/prodtechnol/sql/2005/downloads/books.mspx
Books Online for SQL Server 2000 at
http://www.microsoft.com/sql/prodinfo/previousversions/books.mspx

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация