Biny icon indicating copy to clipboard operation
Biny copied to clipboard

请问,'not like' 要怎么写。

Open 3DMXM opened this issue 3 years ago • 2 comments

因为需要,要筛选“不包含某些字符”的数据,要用到not like来进行操作,发现好像不支持。。。

3DMXM avatar Apr 08 '21 03:04 3DMXM

是的 not like api里是没做支持,也不建议使用, 如果一定要用,可以参考sql模板 http://www.billge.cc/#dao-command

$result = $this->userDAO->filter(array('id'=>10))
    ->select("select * from :table WHERE :where and `column` not like `%xxx%`;");

billge1205 avatar Apr 08 '21 04:04 billge1205

not like 现在支持了,同时也支持了regexp,用法跟其他运算符一致,参考文档 http://www.billge.cc/#dao-extracts

billge1205 avatar Apr 15 '21 02:04 billge1205