I'm building a reporting application that creates html report output based on running stored procs or SQL queries or even a combination. Most of the results are to be displayed in tabular format. In this situation is it wise to build a generic query object that would run the query/stored proc passed in and create a matrix data structure to represent the resultset. Something like an Arraylist of ArrayList would be sufficient to hold the resultset. All items in the matrix would be String values as this is how result page will be created. The alternative to this is creating a pojo class and all associated classes to represent each query being run! By doing this a single presentation page could be built giving the same look and feel for each tabular report.
Any pointers are appreciated.