Welcome Guest, Not a member yet? Register   Sign In
where is ignored when like is used
#1

[eluser]freshface[/eluser]
Hey

When i do something like this:
Code:
$prev_max = $this->db->select_max('slug')->like('slug',$slug,'after')->where('language_id',LANG_ID)->get('pages')->row()->slug;

The where is ignored, how can i solve this?
#2

[eluser]pistolPete[/eluser]
Are you sure the WHERE condition is not included in the generated SQL?
Please post the output of
Code:
echo ($this->db->last_query());
#3

[eluser]freshface[/eluser]
Found it, i applied the where on the wrong query.




Theme © iAndrew 2016 - Forum software by © MyBB