SDSZZCXX_Mapper.xml 6.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <!-- 核三框架升级自动生成mapper文件 -->
  3. <!-- SDSZZCXX表牵涉到的sql文件 -->
  4. <!DOCTYPE mapper
  5. PUBLIC "-//ibatis.apache.org//DTD Mapper 3.0//EN"
  6. "http://ibatis.apache.org/dtd/ibatis-3-mapper.dtd">
  7. <mapper namespace="SDSZZCXX">
  8. <!-- SDSZZCXX 全字段 -->
  9. <sql id="SDSZZCXX_COL">
  10. DZZZBZ,ORDERNO,SFBSBZ,SDSZID,YWLBID,ZLLBID,SDFS,
  11. FS,SFGDBZ,YJFS,FYJFS,CLSM,CLXS
  12. </sql>
  13. <!-- SDSZZCXX 选择字段 -->
  14. <sql id="SDSZZCXX_COLSEL">
  15. <trim suffixOverrides=",">
  16. <if test="DZZZBZ != null">
  17. DZZZBZ,
  18. </if>
  19. <if test="ORDERNO != null">
  20. ORDERNO,
  21. </if>
  22. <if test="SFBSBZ != null">
  23. SFBSBZ,
  24. </if>
  25. <if test="SDSZID != null">
  26. SDSZID,
  27. </if>
  28. <if test="YWLBID != null">
  29. YWLBID,
  30. </if>
  31. <if test="ZLLBID != null">
  32. ZLLBID,
  33. </if>
  34. <if test="SDFS != null">
  35. SDFS,
  36. </if>
  37. <if test="FS != null">
  38. FS,
  39. </if>
  40. <if test="SFGDBZ != null">
  41. SFGDBZ
  42. </if>
  43. </trim>
  44. </sql>
  45. <!-- SDSZZCXX 记录数 -->
  46. <select id="SDSZZCXX_CNT" parameterType="hashmap" resultType="long">
  47. select count(1)
  48. from SDSZZCXX
  49. <where>
  50. <if test="DZZZBZ != null">
  51. and DZZZBZ=#{DZZZBZ}
  52. </if>
  53. <if test="ORDERNO != null">
  54. and ORDERNO=#{ORDERNO}
  55. </if>
  56. <if test="SFBSBZ != null">
  57. and SFBSBZ=#{SFBSBZ}
  58. </if>
  59. <if test="SDSZID != null">
  60. and SDSZID=#{SDSZID}
  61. </if>
  62. <if test="YWLBID != null">
  63. and YWLBID=#{YWLBID}
  64. </if>
  65. <if test="ZLLBID != null">
  66. and ZLLBID=#{ZLLBID}
  67. </if>
  68. <if test="SDFS != null">
  69. and SDFS=#{SDFS}
  70. </if>
  71. <if test="FS != null">
  72. and FS=#{FS}
  73. </if>
  74. <if test="SFGDBZ != null">
  75. and SFGDBZ=#{SFGDBZ}
  76. </if>
  77. </where>
  78. </select>
  79. <!-- SDSZZCXX 全字段查询 -->
  80. <select id="SDSZZCXX_Q" parameterType="hashmap" resultType="hashmap">
  81. select
  82. <include refid="SDSZZCXX_COL" /> <!--引用前边定义的所有字段 -->
  83. from SDSZZCXX
  84. <where>
  85. <if test="DZZZBZ != null">
  86. and DZZZBZ=#{DZZZBZ}
  87. </if>
  88. <if test="ORDERNO != null">
  89. and ORDERNO=#{ORDERNO}
  90. </if>
  91. <if test="SFBSBZ != null">
  92. and SFBSBZ=#{SFBSBZ}
  93. </if>
  94. <if test="SDSZID != null">
  95. and SDSZID=#{SDSZID}
  96. </if>
  97. <if test="YWLBID != null">
  98. and YWLBID=#{YWLBID}
  99. </if>
  100. <if test="ZLLBID != null">
  101. and ZLLBID=#{ZLLBID}
  102. </if>
  103. <if test="SDFS != null">
  104. and SDFS=#{SDFS}
  105. </if>
  106. <if test="FS != null">
  107. and FS=#{FS}
  108. </if>
  109. <if test="SFGDBZ != null">
  110. and SFGDBZ=#{SFGDBZ}
  111. </if>
  112. <if test="SYDX != null">
  113. and SYDX like '%' || #{SYDX} || '%'
  114. </if>
  115. </where>
  116. </select>
  117. <!-- SDSZZCXX 选择查询 -->
  118. <select id="SDSZZCXX_QS" parameterType="hashmap" resultType="hashmap">
  119. select
  120. <include refid="SDSZZCXX_COLSEL" /> <!--引用前边定义的所有字段 -->
  121. from SDSZZCXX
  122. <where>
  123. <if test="DZZZBZ != null">
  124. and DZZZBZ=#{DZZZBZ}
  125. </if>
  126. <if test="ORDERNO != null">
  127. and ORDERNO=#{ORDERNO}
  128. </if>
  129. <if test="SFBSBZ != null">
  130. and SFBSBZ=#{SFBSBZ}
  131. </if>
  132. <if test="SDSZID != null">
  133. and SDSZID=#{SDSZID}
  134. </if>
  135. <if test="YWLBID != null">
  136. and YWLBID=#{YWLBID}
  137. </if>
  138. <if test="ZLLBID != null">
  139. and ZLLBID=#{ZLLBID}
  140. </if>
  141. <if test="SDFS != null">
  142. and SDFS=#{SDFS}
  143. </if>
  144. <if test="FS != null">
  145. and FS=#{FS}
  146. </if>
  147. <if test="SFGDBZ != null">
  148. and SFGDBZ=#{SFGDBZ}
  149. </if>
  150. </where>
  151. </select>
  152. <!-- SDSZZCXX 插入 -->
  153. <insert id="SDSZZCXX_I" parameterType="hashmap">
  154. insert into SDSZZCXX (
  155. DZZZBZ,ORDERNO,SFBSBZ,SDSZID,YWLBID,ZLLBID,SDFS,
  156. FS,SFGDBZ
  157. ) values (
  158. #{DZZZBZ},#{ORDERNO},#{SFBSBZ},#{SDSZID},#{YWLBID},#{ZLLBID},#{SDFS},
  159. #{FS},#{SFGDBZ}
  160. )
  161. </insert>
  162. <!-- SDSZZCXX 插入-类型映射 -->
  163. <insert id="SDSZZCXX_IT" parameterType="hashmap">
  164. insert into SDSZZCXX (
  165. DZZZBZ,ORDERNO,SFBSBZ,SDSZID,YWLBID,ZLLBID,SDFS,
  166. FS,SFGDBZ
  167. ) values (
  168. #{DZZZBZ ,javaType=string,jdbcType=VARCHAR},#{ORDERNO ,javaType=long,jdbcType=NUMERIC},
  169. #{SFBSBZ ,javaType=string,jdbcType=VARCHAR},#{SDSZID ,javaType=long,jdbcType=NUMERIC},#{YWLBID ,javaType=long,jdbcType=NUMERIC},
  170. #{ZLLBID ,javaType=long,jdbcType=NUMERIC},#{SDFS ,javaType=string,jdbcType=VARCHAR},#{FS ,javaType=long,jdbcType=NUMERIC},
  171. #{SFGDBZ ,javaType=string,jdbcType=VARCHAR}
  172. )
  173. </insert>
  174. <!-- SDSZZCXX 选择字段插入 -->
  175. <insert id="SDSZZCXX_IS" parameterType="hashmap">
  176. insert into SDSZZCXX (
  177. <trim suffixOverrides=",">
  178. <if test="DZZZBZ != null">DZZZBZ,</if>
  179. <if test="ORDERNO != null">ORDERNO,</if>
  180. <if test="SFBSBZ != null">SFBSBZ,</if>
  181. <if test="SDSZID != null">SDSZID,</if>
  182. <if test="YWLBID != null">YWLBID,</if>
  183. <if test="ZLLBID != null">ZLLBID,</if>
  184. <if test="SDFS != null">SDFS,</if>
  185. <if test="FS != null">FS,</if>
  186. <if test="SFGDBZ != null">SFGDBZ,</if>
  187. </trim>
  188. ) values (
  189. <trim suffixOverrides=",">
  190. <if test="DZZZBZ != null">#{DZZZBZ},</if>
  191. <if test="ORDERNO != null">#{ORDERNO},</if>
  192. <if test="SFBSBZ != null">#{SFBSBZ},</if>
  193. <if test="SDSZID != null">#{SDSZID},</if>
  194. <if test="YWLBID != null">#{YWLBID},</if>
  195. <if test="ZLLBID != null">#{ZLLBID},</if>
  196. <if test="SDFS != null">#{SDFS},</if>
  197. <if test="FS != null">#{FS},</if>
  198. <if test="SFGDBZ != null">#{SFGDBZ},</if>
  199. </trim>
  200. )
  201. </insert>
  202. <!-- SDSZZCXX 修改 -->
  203. <update id="SDSZZCXX_U" parameterType="hashmap">
  204. update SDSZZCXX
  205. set
  206. DZZZBZ= #{DZZZBZ},ORDERNO= #{ORDERNO},SFBSBZ= #{SFBSBZ},
  207. SDSZID= #{SDSZID},YWLBID= #{YWLBID},ZLLBID= #{ZLLBID},SDFS= #{SDFS},
  208. FS= #{FS},SFGDBZ= #{SFGDBZ}
  209. where
  210. SDSZID = #{SDSZID}
  211. </update>
  212. <!-- SDSZZCXX 选择修改 -->
  213. <update id="SDSZZCXX_US" parameterType="hashmap">
  214. update SDSZZCXX
  215. set
  216. <trim suffixOverrides=",">
  217. <if test="DZZZBZ != null">DZZZBZ=#{DZZZBZ},</if>
  218. <if test="ORDERNO != null">ORDERNO=#{ORDERNO},</if>
  219. <if test="SFBSBZ != null">SFBSBZ=#{SFBSBZ},</if>
  220. <if test="SDSZID != null">SDSZID=#{SDSZID},</if>
  221. <if test="YWLBID != null">YWLBID=#{YWLBID},</if>
  222. <if test="ZLLBID != null">ZLLBID=#{ZLLBID},</if>
  223. <if test="SDFS != null">SDFS=#{SDFS},</if>
  224. <if test="FS != null">FS=#{FS},</if>
  225. <if test="SFGDBZ != null">SFGDBZ=#{SFGDBZ},</if>
  226. </trim>
  227. where
  228. SDSZID = #{SDSZID}
  229. </update>
  230. <!-- SDSZZCXX 删除 -->
  231. <delete id="SDSZZCXX_D" parameterType="hashmap">
  232. delete from SDSZZCXX
  233. <where>
  234. SDSZID = #{SDSZID}
  235. </where>
  236. </delete>
  237. </mapper>