Combining `where` and `like` statements by using the CI activerecords

前端 未结 6 2249
一个人的身影
一个人的身影 2021-01-06 18:48

To cut a long story short: Is it possible and if it is - how can I build a query that looks somewhat like this one

SELECT * FROM a
    WHERE row = 1 AND 
            


        
6条回答
  •  清酒与你
    2021-01-06 19:25

    I also having problem with or_where so i simply make my custom query like

    $this->db->query("SELECT * FROM `a` WHERE `row`=1 AND (CONDITION1 OR CONDITION2)")
    

提交回复
热议问题