I have a database table with site configurations and want to setup so that the list of rows needed will be put in first, then queried.
Example
$ConfigDao->queryadd('sitename');
$ConfigDao->queryadd('newscount');
$ConfigDao->queryadd('somethingelse');
// this would get sitename, newscount, and somethingelse in one query
$array = $ConfigDao->performquery();
I figured this method would be the best way to reduce queries. But where should I place functions like queryadd()? Should it be on a layer on top of the ConfigDao or just put it all inside? I'm just looking for common practice. Or if you can explain the benefit of your recommendation, even better.
Thanks