If you have a sql statement that takes HOURS - then you need to spend some time fixing your database! You should be able to do complicated multi-table joins on tables having millions of rows in only a fraction of a second. Maybe you need a better indexing strategy?
But if it can't be fixed - then it sounds like you're trying to "web-ify" an app that just isn't well suited for the web. Consider setting up a batch process system instead. The web app will let users submit a job request. Once a job is created, they can go do something else. Later, they can return to check on the status of their job (pending, running, completed, failed, etc.). This way all the web app has to do is write a line of text into a "todo" list. You can setup a cron job to check the list every 15 minutes or so and begin processing any new jobs that it finds. You can add a "kill job" button the the "check status page", etc.
In other words, it sounds like this isn't the kind of job you do in "real time", even if you're sitting at a mysql prompt - so don't try to make it "real time" via a web interface.
In reply to Re: Perl and Apache… Process keeps running.
by scorpio17
in thread Perl and Apache… Process keeps running.
by clintonm9
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |