Re: What is the most efficient way to store SELECT results

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Many sites just requery the database on each page and just return the
relevant results. If you are using mysql, you can use LIMIT in your
query to restrict the results for a specific "page". You can also do
something in similar in Oracle using nested queries and row ids.

If the query is slow, you could cache the results in a temporary table
keyed on the user's session id.

-Roberto


Robert Palmer wrote:
> I'm not I was clear in my question. A query returns 1,000 rows from the
> table. I want to store the entire result of that query in order to be
> able to create separate pages to return the results rather than all on
> one page "e.g. Page 1 2 3 4 ... ". Not sure if it's important but I'm
> using persistent connections.
> 
> ben@xxxxxxxxxxxxxxxxxxxxxx wrote:
>> Robert wrote:
>>> I want to store the results of a SELECT query in order to be able to
>>> page through those results and allow the user to select one, see it
>>> in more details and then return to the original list of results.
>>> What's the usual technique for doing this?
>>>
>> place a get variable after the query as it is listed in some table in
>> html, then the link for the entry will be identifying the data such
>> that a second handler page or second query can funish the additional
>> data ;-)
>>

-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [PHP Users]     [Postgresql Discussion]     [Kernel Newbies]     [Postgresql]     [Yosemite News]

  Powered by Linux