时间:2021-07-01 10:21:17 帮助过:3人阅读
但是若果用到了动态sql就不能再像上面那样写了,应该写成
@Select("<script>" + "SELECT * FROM main_order left outer join sub_order on main_order.order_no=sub_order.main_order_no " + "<where>" + " <if test=\"mainOrderNo != null \">and main_order.order_no=#{mainOrderNo}</if>"+ "</where>" + "</script>")
mybatis注解开发,动态sql
标签:ati sql pre 直接 list color test out 不能