MyBatis Plus條件構造器QueryWrapper對應常用SQL語法說明


函數  說明  SQL語法

eq   等於   =

ne   不等於  <>

gt   大於   >

lt   小於   <

ge   大於等於   >=

le   小於等於   <=

or   或者   or

and   並且   and

like   模糊查詢包含s   like %s%

notLike   模糊查詢不包含s   not like %s%

likeLeft   左匹配模糊查詢   like %s

likeRight   右匹配模糊查詢   like s%

between   在v1到v2之間   between v1 and v2

notBetween   不在v1到v2之間   not between v1 and v2

isNull   是否為空   is null

isNotNull   是否不為空   is not null

in   field在[a, b, c]之中   field in (a, b, c)

notIn   field不在在[a, b, c]之中   field not in (a, b, c)

orderByAsc   升序排序   order by field asc

orderByDesc   降序排序   order by field desc

groupBy   分組   group by

having   分組過濾   having

 


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM