Page 1 of 1

Behind the Scenes Querying (HELP ME!)

Posted: Fri Jul 01, 2005 5:01 pm
by bwv2
I'm having a little issue with querying a large table. I need to extract some data that corresponds to the user's coordinates. When they enter the coordinates, the query is sent to a mysql database and picks out some info from a table.

Trouble is that my table is about 7.5 million fields, so it takes a couple of minutes to obtain the result.

I haven't finished the application yet, but I want to know if the user can immediately continue as soon as they press "submit" and have the query happening behind the scenes as they continue on filling out additional information. I won't need the actual variables generated by the query until a couple of pages down the line, so I can spare the time for the query. I just don't want the page to be loading for 3 minutes while it's happening. Will this work, or is there something else I have to do to get the "behind the scenes" query to happen?

Thanks.

Posted: Fri Jul 01, 2005 5:20 pm
by Burrito
you could use a hidden iframe or some such, but it'd be tough to have their experience continue on the same page.

Posted: Sat Jul 02, 2005 4:52 am
by djot
I would use sessions or cookie, store the information that session_xy has started the db-query. Later on, while the user is browsing other pages you may check, whether the users db-query has already finished and fetch the relavant information then.