在mybatis中构建带有sql in查询的mapper语法
在mapper中编写带有sql in语法的sql时,需要注意不能直接以字符串”in(…)”的形式将语句贴在sql中,需要以list集合的形式遍历出来,具体的表达方式如下:
1 | <select id="selectAllServiceByServiceType" resultMap="BaseResultMap2" parameterType="java.util.List"> |
在mapper中编写带有sql in语法的sql时,需要注意不能直接以字符串”in(…)”的形式将语句贴在sql中,需要以list集合的形式遍历出来,具体的表达方式如下:
1 | <select id="selectAllServiceByServiceType" resultMap="BaseResultMap2" parameterType="java.util.List"> |
Update your browser to view this website correctly.&npsb;Update my browser now