Timeout Troubles when I execute a sql quey.

Discussion in 'ASP .Net' started by Don Juan, Jun 24, 2008.

  1. Don Juan

    Don Juan Guest

    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.
    Don Juan, Jun 24, 2008
    #1
    1. Advertising

  2. Don Juan

    Munna Guest

    Munna, Jun 24, 2008
    #2
    1. Advertising

  3. Don Juan

    Nobody Guest

    Sounds more like a command timeout then a connect timeout to me.

    "Don Juan" <> wrote in message
    news:...
    > 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.
    Nobody, Jun 24, 2008
    #3
  4. Don Juan

    Munna Guest

    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
    Munna, Jun 24, 2008
    #4
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. ravi
    Replies:
    1
    Views:
    244
    bruce barker
    Apr 19, 2008
  2. ravi
    Replies:
    1
    Views:
    251
    Lloyd Sheen
    Apr 19, 2008
  3. dave
    Replies:
    2
    Views:
    1,931
    daveh551
    Dec 4, 2008
  4. Savas Ates
    Replies:
    1
    Views:
    276
    Patrice
    Aug 17, 2004
  5. Mark Probert

    Timeout::timeout and Socket timeout

    Mark Probert, Oct 6, 2004, in forum: Ruby
    Replies:
    1
    Views:
    1,279
    Brian Candler
    Oct 6, 2004
Loading...

Share This Page