sql的查询多次in 操作的导致查询数据为空

 
通过if else的方式解决
     <choose>
            <when test="site==5">
                and p.is_default=1
                and p.payment_method in('1','7','8','12','13','14')
            </when>
            <otherwise>
                and p.payment_method in('7','8')
            </otherwise>
        </choose>

  

posted @ 2022-04-27 20:53  三号小玩家  阅读(156)  评论(0)    收藏  举报
Title
三号小玩家的 Mail: 17612457115@163.com, 联系QQ: 1359720840 微信: QQ1359720840