sql some query in codeigniter code example Example: raw query in codeigniter $query = $db->query('YOUR QUERY HERE');