in reply to Printing Categories from SQL search

Make it a job for the database, don't transfer tons of data that you don't need:

SELECT DISTINCT category FROM table WHERE other_column=? AND yet_anoth +er_column=?

(DISTINCT automatically removes duplicates.)

Alexander

--
Today I will gladly share my knowledge and experience, for there are no sweeter words than "I told you so". ;-)