[eluser]GeXus[/eluser]
Hey guys, I've been handling my queries like this:
Code:
function getSomething(){
$query = $this->db->query("QUERY");
return ($query->result_array()) ? $query->result_array() : false;
}
By doing it this way (checking if its true first, then returning it) cause the query to be run twice? Would it be better to store the query in a variable, then do the check on that variable?