[eluser]champs[/eluser]
The AR class is just a fancy string builder. For example:
Code:
<?php
$this->db->select('DISTINCT foo.bar, baz.field1, baz.field2');
$this->db->from('footable AS foo');
$this->db->join('baztable AS baz', 'foo.bar=baz.bip');
$this->db->where('baz.importantvalue', 123);
// and even....
$this->db->orderby('RAND()');
?>