Hey, I have been screwing around with this code for around a day and am hitting a wall, any help would be appreciated. Basically, I am working on a site that queries the DB for companies and the plans the company is offering, the DB is quite big (a few thousand records in each of the 20 tables) The parameters are taken from the client in the form of a search box and usually gives around 1000 results per query, they results are then displayed like this: company 1 [] plan [] plan [] plan [] plan company 2 [] plan [] plan [] plan company 3 [] plan company 4 [] plan [] plan So far, no problems (even though the code and the design are mixed together in the page) but so far the code is getting the results grouping via $cno, which results in the lowest being displayed first which gives the first companies who joined an edge as they are always getting displayed. Heres the kicker, he wants to have the same display as above....but randomly from the DB *while still* having pagination.. so new joined companies too get displayed and not shoved at the end of the results. To see the code used presently (stripped down to a few lines) : http://jappz.com/testing.phpp To see the output from the above : http://jappz.com/testing.html Any suggestions, classes, code, links or general help would be appreciated. Thanks, Ryan -- No virus found in this outgoing message. Checked by AVG Anti-Virus. Version: 7.0.308 / Virus Database: 266.11.6 - Release Date: 5/6/2005 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php