MyBatis动态SQL示例
if
1 | <select id="list" parameterType="map" resultMap="BlogResult"> |
choose、when、otherwise
1 | <select id="findActiveBlogLike" |
trim、where、set
1 | <trim prefix="WHERE" prefixOverrides="AND |OR "> |
foreach
1 | <select id="selectPostIn" resultType="domain.blog.Post"> |
script
1 | @Update({"<script> |
bind
1 | <select id="selectBlogsLike" resultType="Blog"> |
本博客所有文章除特别声明外,均采用 CC BY-NC-SA 4.0 许可协议。转载请注明来自 LeDao's Blog!
评论