[eluser]soprabaixar1[/eluser]
Cache is good when it happens many actions in the database (insert, delete, update), and is not the case.
I decided a little better than the previous form, this time I do not need to create a variable "$query2" going all the information again, just enjoy the variable $query and a line do I make the call with the values refernte to "limit" of course it still does not consider ideal.
The two temporary solution was as follows:
Code:
...
$query = $this->orderby(..., ...);
$query = $this->like(..., ...);
$query = $this->get(...');
$config['total_rows'] = $query->num_rows();
$query = $this->get(..., ..., ...);
$data['results'] = $query->result();
...