Splitting up MySQL resultset?

admin

Administrator
Staff member
Hey guys,

I am planning to build a site that will be powered by a MySQL database on the backend. I want to store a list of product categories in a MySQL table, and using a php page, output the contents of this category table.

When I do a "Select *" SQL statement, the entire resultset is pulled from the database. How can I split this resultset into "two parts" so that I can put one part into one table cell and the other part in another table cell?

This may be hard to explain, but for an example, check out:

<!-- m --><a class="postlink" href="http://www.onvia.ca/canada/products/index.cfm?task=ViewCategory&categoryID=30001">http://www.onvia.ca/canada/products/ind ... ryID=30001</a><!-- m -->

Onvia has all its product categories spread out into three columns. How do I do this with php?

Any help would be greatly appreciated!
 
Back
Top