ASP Programming
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsProgramming Languages - MoreASP Programming

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
Stay one step ahead of the competition. Evaluate and give feedback on some of the hottest web development tools on the market today. Make your opinion heard! Click Here
  #1  
Old July 22nd, 2003, 06:19 AM
Silian's Avatar
Silian Silian is offline
Gogga
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jul 2003
Posts: 198 Silian User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 6
Question Stopping server side script after execution.

Problem: I have a few reports that grabs +- 27 000 records from a database, does a few calculations and queries on them, and then writes the results to a text file.

As you can imagine, this does take a while (half an hour if the server isn't busy) and hammers the servers resources.

I sometimes realise (after I've started the page) that I made an error in my code, or that another report is more important at the moment. The only way to stop the page if something like this happens, is to bounce the server (even closing my browser doesn't work) - which won't make me very popular

Is it possible (at all) to stop the execution of the page after it has been started? (I know that ASP is executed on the server, and only the results are sent through, but doesn't it have some sort of event handling?)

Any idees would be welcome. (even "it's not possible", then I can stop worrying abt it )

Reply With Quote
  #2  
Old July 22nd, 2003, 07:19 AM
WineIsGood's Avatar
WineIsGood WineIsGood is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jul 2003
Location: New York
Posts: 49 WineIsGood User rank is Private First Class (20 - 50 Reputation Level)WineIsGood User rank is Private First Class (20 - 50 Reputation Level) 
Time spent in forums: 7 m 51 sec
Reputation Power: 6
Not that I know of... the only way to do this would be to stop/restart the process. IISRESET in other words. If someone knows how to find an individual server process and kill it, I'd sure like to know. There is another alternative, however. You can kill the SQL job and that will halt the page. If you're using MS SQL Server, just look in Enterprise Manager for your running job. If there are so many jobs that it's hard to locate, then I suggest naming your connection so it's easy to find.
-Dave

Reply With Quote
  #3  
Old July 22nd, 2003, 07:23 AM
Silian's Avatar
Silian Silian is offline
Gogga
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jul 2003
Posts: 198 Silian User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 6
Thanks, I'll try that (Yes, I do use MS SQL server). I hope that someone won't kill me if I accidently stop their job

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming Languages - MoreASP Programming > Stopping server side script after execution.


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 5 hosted by Hostway