long running query...

Discussion in 'ASP .Net' started by eNathan, Oct 28, 2003.

  1. eNathan

    eNathan Guest

    I'm sure this has been discussed before...

    I have a query that moves a large amount of data from one db to another and
    takes between 20-25 seconds. This causes a timeout error. With ADO.NET &
    ASP.NET, how can I fire a stored procedure and let it run asynchronously? I
    don't care to wait for it to finish.
    By the way I'm using the Data Access Application Block. TIA
     
    eNathan, Oct 28, 2003
    #1
    1. Advertisements

  2. eNathan

    Anton Sommer Guest

    Check this out



    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As
    System.EventArgs) Handles Button1.Click

    Dim NewThread As Thread = New Thread(AddressOf GeneratePrimeNumbers)

    ' sets priority

    NewThread.Priority = ThreadPriority.Lowest

    ' executes thread

    NewThread.Start()

    Response.Redirect("results1.aspx")

    'Dim conn As OleDb.OleDbConnection

    End Sub

    Public Sub GeneratePrimeNumbers()

    What ever code that takes a long time

    End Sub

    "eNathan" <> schrieb im Newsbeitrag
    news:#...
    > I'm sure this has been discussed before...
    >
    > I have a query that moves a large amount of data from one db to another

    and
    > takes between 20-25 seconds. This causes a timeout error. With ADO.NET &
    > ASP.NET, how can I fire a stored procedure and let it run asynchronously?

    I
    > don't care to wait for it to finish.
    > By the way I'm using the Data Access Application Block. TIA
    >
    >
     
    Anton Sommer, Oct 28, 2003
    #2
    1. Advertisements

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. Gershon
    Replies:
    2
    Views:
    784
  2. George Marsaglia

    Assigning unsigned long to unsigned long long

    George Marsaglia, Jul 8, 2003, in forum: C Programming
    Replies:
    1
    Views:
    970
    Eric Sosman
    Jul 8, 2003
  3. Daniel Rudy

    unsigned long long int to long double

    Daniel Rudy, Sep 19, 2005, in forum: C Programming
    Replies:
    5
    Views:
    1,576
    Peter Shaggy Haywood
    Sep 20, 2005
  4. Mathieu Dutour

    long long and long

    Mathieu Dutour, Jul 17, 2007, in forum: C Programming
    Replies:
    4
    Views:
    696
    santosh
    Jul 24, 2007
  5. Bart C

    Use of Long and Long Long

    Bart C, Jan 9, 2008, in forum: C Programming
    Replies:
    27
    Views:
    1,239
    Peter Nilsson
    Jan 15, 2008
  6. veryhotsausage
    Replies:
    1
    Views:
    2,352
    veryhotsausage
    Jul 4, 2008
  7. Oliver Graeser
    Replies:
    10
    Views:
    818
    Oliver Graeser
    Sep 26, 2008
  8. Replies:
    5
    Views:
    414
    ara.t.howard
    Nov 6, 2007
Loading...