Timeout Troubles when I execute a sql quey.

  • Thread starter Thread starter Don Juan
  • Start date Start date
D

Don Juan

Hi all (vb)
I worked with querys and they worked fine, but now I need to retrieve a lot
of data, when I launch the query it stoped with this error:
---
Timeout expired. The timeout period elapsed prior to completion of the
operation or the server is not responding.
---
I use a DataSet object, here I put my query. This objects takes the
settings from the web.config file, in the web.config file I added this:
---
Connect Timeout=0
---
Even, I tried with several numbers but the response error still.

How can I repair this problem?

Thanks in advanced.
 
Hi,

http://msdn.microsoft.com/en-us/library/system.data.sqlclient.sqlcommand.commandtimeout(VS.80).aspx

The time in seconds to wait for the command to execute. The default is
30 seconds.

A value of 0 indications no limit, and should be avoided in a
CommandTimeout because an attempt to execute a command will wait
indefinitely.

CommandTimeout has no effect when the command is executed against a
context connection (a SqlConnection opened with "context
connection=true" in the connection string).

Best of luck

Munna

www.munna.shatkotha.com
www.munna.shatkotha.com/blog
www.shatkotha.com
 
Back
Top