How to use LIKE OR operator using cakephp & mysql

前端 未结 3 1914
后悔当初
后悔当初 2021-01-12 01:31

I am new to cakephp & don\'t know what is the syntax to use LIKE & OR operator in cakephp with mysql.

Can anyone help me? T

3条回答
  •  被撕碎了的回忆
    2021-01-12 02:06

    if you using where function then use this :-

    ->where(['Products.category_id'=>1, 'Products.name LIKE' =>'test%'])
    

    thanks

提交回复
热议问题