[eluser]zovar[/eluser]
CI user guide says that we can use custom strings in $this->db->where():
Code:
$where = "name='Joe' AND status='boss' OR status='active'";
$this->db->where($where);
My string is as follows
Code:
$where = " tag='test' OR tag='test1' ";
$this->db->select('id')->from('tags')->where($where);
i get the following error
Code:
A Database Error Occurred
Error Number: 1054
Unknown column 'tag='test'' in 'where clause'
UPDATE `notes` SET `title` = 'title' WHERE `tag='test'` OR tag='test1' AND `id` = '13'
as you can seen the first where statement gets escaped...