473,795 Members | 2,929 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Handle stored procedure timeout from ASP

I have an ASP page calling a stored procedure. I have set the connection and
command timeouts and I have error checking so I can trap a timeout from the
stored proc (as detailed here)
http://www.eggheadcafe.com/PrintSear...asp?LINKID=142

This works if the stored proc just contains a "WAITFOR DELAY", but doesn't
seem to throw an error when the stored proc contains long-running sql. Anyone
have any ideas?
Jul 22 '05 #1
2 4778
I dont know an answer for your specific question but here is a side note.
If the request is going to exceed the standard timeout settings you will
want to rethink your process. In otherwords if the process takes that long
dont use it in a request system.

--
Curt Christianson
Site & Scripts: http://www.Darkfalz.com
Blog: http://blog.Darkfalz.com
"Gary Homewood" <Gary Ho******@discus sions.microsoft .com> wrote in message
news:F6******** *************** ***********@mic rosoft.com...
I have an ASP page calling a stored procedure. I have set the connection
and
command timeouts and I have error checking so I can trap a timeout from
the
stored proc (as detailed here)
http://www.eggheadcafe.com/PrintSear...asp?LINKID=142

This works if the stored proc just contains a "WAITFOR DELAY", but doesn't
seem to throw an error when the stored proc contains long-running sql.
Anyone
have any ideas?

Jul 22 '05 #2
Thanks for the response, and I agree that it may not be the best architecture
to call a long-running stored procedure from ASP, but I'd still like to know
why I can't catch the timeout.
"Curt_C [MVP]" wrote:
I dont know an answer for your specific question but here is a side note.
If the request is going to exceed the standard timeout settings you will
want to rethink your process. In otherwords if the process takes that long
dont use it in a request system.

--
Curt Christianson
Site & Scripts: http://www.Darkfalz.com
Blog: http://blog.Darkfalz.com
"Gary Homewood" <Gary Ho******@discus sions.microsoft .com> wrote in message
news:F6******** *************** ***********@mic rosoft.com...
I have an ASP page calling a stored procedure. I have set the connection
and
command timeouts and I have error checking so I can trap a timeout from
the
stored proc (as detailed here)
http://www.eggheadcafe.com/PrintSear...asp?LINKID=142

This works if the stored proc just contains a "WAITFOR DELAY", but doesn't
seem to throw an error when the stored proc contains long-running sql.
Anyone
have any ideas?


Jul 22 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
6235
by: deprins | last post by:
Hello, I have wrote a stored procedure but its real slow. Its activated by a button on web page but its takes to long to process and the web server gives a timeout message after 5 minutes. Is there anyway to speed up this stored procedure? What am I doing wrong here? ------------------------------------------------------------------------------
1
12211
by: Ville Huovinen | last post by:
Platform: Windows 2003 Server (MS SQL Server 2003 SP3) Language: C# Problem: My stored procedures times out randomly, some proces works fine when using them from C#, and some generate SqlException which states that the server has timed out. The problem isn't in server, neither in stored procedures because they work fine in Sql Server's enterprise manager, but when calling from code they are slow and take about 60 seconds before...
1
2552
by: Crazy Cat | last post by:
I'm calling several SQL Server 2005 stored procedures from Visual Basic 2005. I've got one stored procedure that locks up at the same point everytime, but if I copy the stored procedure from the SQL Profiler trace and paste it into SQL Server Management Studio it runs fine -- I even tried setting the timeout in Visual Studio to unlimited to see if the procedure would ever complete and it doesn't. What the hell is going on? Here is the...
1
13671
by: deepdata | last post by:
Hi, I am trying to fetch data from db2 (express version) database by calling stored procedure. I have tried to use both cursor and for loop but still i am getting error. --======Start procedure============= Create PROCEDURE get_timedout_scripts (
7
9717
by: Siv | last post by:
Hi, I have a stored procedure that I want to execute and then wait in a loop showing a timer whilst it completes and then carry on once I get notification that it has completed. The main reason for this being to stop the user thinking the application has frozen when in fact it is just waiting for a long SP to complete. Another reason for doing it like this is that I also have had a problem in the past where the SP takes longer than the...
2
7281
by: drolfe | last post by:
See below the code for details about the scenario. ------------------------------------------------------------------------------------ Public WithEvents conADS As New SqlConnection("Data Source=server;Initial Catalog=db;Persist Security Info=True;User ID=username;Password=password;Connection Timeout=0;") Public runBoardPostings As New SqlCommand("EXEC . @PREV2_PERIOD_START = @prev2Begin, @PREV2_PERIOD_END = @prev2End,...
2
1827
by: rokslide | last post by:
Hi all, I have a web application which (until a few weeks ago) was running fine. Now, periodically, a stored procedure will stop responding and timeout when called via the web application. The stored procedure varies (eg. so far this problem has happened twice and it has been a different stored proc each time) and if the stored procedure is executed in the query analyzer it executes without a problem and within a second. Looking at...
3
3174
by: Racerx | last post by:
Hi All: I use db2 v8 fp 14 on Aix. I am facing problems with a stored procedure that is causing a lot of locks and also goes in the lock wait state ending up hanging the application. Tried using the UR isolation mode but it did not help. Can some one please suggest me how to debug this problem and any
0
1065
by: TimSki | last post by:
Hi, For some reason, every 2/3 days a stored procedure on my database will start to timeout during operation. The load is normal and the indexes have been recently ( a few days ago) rebuilt. To solve the timeout i drop and then recreate the stored procedure in question. This always fixes the problem and then 2/3 days later it reoccurs. I really don't understand why thei happens, do SPs become fragmented like indexes over time and suffer...
0
9522
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10448
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10217
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10167
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9046
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7544
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5440
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5566
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4114
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.