Queries
Posted: Sat Feb 11, 2006 10:27 am
Say, I have events table in my db. All events have name, date and type. I need to present the data this way: a separate table is displayed for each date requested. In each table, all events for that particular date should be visible, grouped by their type. These groups must be separated in some way (doesn't matter in what way).
What do you think would be the best way to fetch and display the data in the view I described? Should I use a single resultset (includes all data for all requested days), or would it be better to use more resultsets (say, one for each date)? Should I use a multidimensional array ($events[$date][$type][$event]) to put the data from resultset(s) for easy HTML output?
Any ideas are welcome.
What do you think would be the best way to fetch and display the data in the view I described? Should I use a single resultset (includes all data for all requested days), or would it be better to use more resultsets (say, one for each date)? Should I use a multidimensional array ($events[$date][$type][$event]) to put the data from resultset(s) for easy HTML output?
Any ideas are welcome.