CustomeraddressMapper.xml 8.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
  3. <mapper namespace="com.usoftchina.saas.document.mapper.CustomeraddressMapper">
  4. <resultMap id="BaseResultMap" type="com.usoftchina.saas.document.entities.Customeraddress">
  5. <id column="ca_id" jdbcType="INTEGER" property="id" />
  6. <result column="ca_cuid" jdbcType="INTEGER" property="ca_cuid" />
  7. <result column="ca_detno" jdbcType="INTEGER" property="ca_detno" />
  8. <result column="ca_person" jdbcType="VARCHAR" property="ca_person" />
  9. <result column="ca_phone" jdbcType="INTEGER" property="ca_phone" />
  10. <result column="ca_default" jdbcType="INTEGER" property="ca_default" />
  11. <result column="companyid" jdbcType="INTEGER" property="companyId" />
  12. <result column="updaterid" jdbcType="INTEGER" property="updaterId" />
  13. <result column="updatetime" jdbcType="TIMESTAMP" property="updateTime" />
  14. <result column="ca_text1" jdbcType="VARCHAR" property="ca_text1" />
  15. <result column="ca_text2" jdbcType="VARCHAR" property="ca_text2" />
  16. <result column="ca_text3" jdbcType="VARCHAR" property="ca_text3" />
  17. <result column="ca_text4" jdbcType="VARCHAR" property="ca_text4" />
  18. <result column="ca_text5" jdbcType="VARCHAR" property="ca_text5" />
  19. </resultMap>
  20. <resultMap extends="BaseResultMap" id="ResultMapWithBLOBs" type="com.usoftchina.saas.document.entities.Customeraddress">
  21. <result column="ca_address" jdbcType="LONGVARCHAR" property="ca_address" />
  22. </resultMap>
  23. <sql id="Base_Column_List">
  24. ca_id, ca_cuid, ca_detno, ca_person, ca_phone, ca_default, companyid, updaterid,
  25. updatetime, ca_text1, ca_text2, ca_text3, ca_text4, ca_text5
  26. </sql>
  27. <sql id="Blob_Column_List">
  28. ca_address
  29. </sql>
  30. <select id="selectByPrimaryKey" parameterType="java.lang.Integer" resultMap="ResultMapWithBLOBs">
  31. select
  32. <include refid="Base_Column_List" />
  33. ,
  34. <include refid="Blob_Column_List" />
  35. from customeraddress
  36. where ca_id = #{ca_id,jdbcType=INTEGER}
  37. </select>
  38. <delete id="deleteByPrimaryKey" parameterType="java.lang.Integer">
  39. delete from customeraddress
  40. where ca_id = #{ca_id,jdbcType=INTEGER}
  41. </delete>
  42. <insert id="insert" parameterType="com.usoftchina.saas.document.entities.Customeraddress">
  43. insert into customeraddress (ca_id, ca_cuid, ca_detno,
  44. ca_person, ca_phone, ca_default,
  45. companyid, updaterid, updatetime,
  46. ca_text1, ca_text2, ca_text3,
  47. ca_text4, ca_text5, ca_address
  48. )
  49. values (#{ca_id,jdbcType=INTEGER}, #{ca_cuid,jdbcType=INTEGER}, #{ca_detno,jdbcType=INTEGER},
  50. #{ca_person,jdbcType=VARCHAR}, #{ca_phone,jdbcType=INTEGER}, #{ca_default,jdbcType=INTEGER},
  51. #{companyid,jdbcType=INTEGER}, #{updaterid,jdbcType=INTEGER}, #{updatetime,jdbcType=TIMESTAMP},
  52. #{ca_text1,jdbcType=VARCHAR}, #{ca_text2,jdbcType=VARCHAR}, #{ca_text3,jdbcType=VARCHAR},
  53. #{ca_text4,jdbcType=VARCHAR}, #{ca_text5,jdbcType=VARCHAR}, #{ca_address,jdbcType=LONGVARCHAR}
  54. )
  55. </insert>
  56. <insert id="insertSelective" parameterType="com.usoftchina.saas.document.entities.Customeraddress">
  57. insert into customeraddress
  58. <trim prefix="(" suffix=")" suffixOverrides=",">
  59. <if test="ca_id != null">
  60. ca_id,
  61. </if>
  62. <if test="ca_cuid != null">
  63. ca_cuid,
  64. </if>
  65. <if test="ca_detno != null">
  66. ca_detno,
  67. </if>
  68. <if test="ca_person != null">
  69. ca_person,
  70. </if>
  71. <if test="ca_phone != null">
  72. ca_phone,
  73. </if>
  74. <if test="ca_default != null">
  75. ca_default,
  76. </if>
  77. <if test="companyid != null">
  78. companyid,
  79. </if>
  80. <if test="updaterid != null">
  81. updaterid,
  82. </if>
  83. <if test="updatetime != null">
  84. updatetime,
  85. </if>
  86. <if test="ca_text1 != null">
  87. ca_text1,
  88. </if>
  89. <if test="ca_text2 != null">
  90. ca_text2,
  91. </if>
  92. <if test="ca_text3 != null">
  93. ca_text3,
  94. </if>
  95. <if test="ca_text4 != null">
  96. ca_text4,
  97. </if>
  98. <if test="ca_text5 != null">
  99. ca_text5,
  100. </if>
  101. <if test="ca_address != null">
  102. ca_address,
  103. </if>
  104. </trim>
  105. <trim prefix="values (" suffix=")" suffixOverrides=",">
  106. <if test="ca_id != null">
  107. #{ca_id,jdbcType=INTEGER},
  108. </if>
  109. <if test="ca_cuid != null">
  110. #{ca_cuid,jdbcType=INTEGER},
  111. </if>
  112. <if test="ca_detno != null">
  113. #{ca_detno,jdbcType=INTEGER},
  114. </if>
  115. <if test="ca_person != null">
  116. #{ca_person,jdbcType=VARCHAR},
  117. </if>
  118. <if test="ca_phone != null">
  119. #{ca_phone,jdbcType=INTEGER},
  120. </if>
  121. <if test="ca_default != null">
  122. #{ca_default,jdbcType=INTEGER},
  123. </if>
  124. <if test="companyid != null">
  125. #{companyid,jdbcType=INTEGER},
  126. </if>
  127. <if test="updaterid != null">
  128. #{updaterid,jdbcType=INTEGER},
  129. </if>
  130. <if test="updatetime != null">
  131. #{updatetime,jdbcType=TIMESTAMP},
  132. </if>
  133. <if test="ca_text1 != null">
  134. #{ca_text1,jdbcType=VARCHAR},
  135. </if>
  136. <if test="ca_text2 != null">
  137. #{ca_text2,jdbcType=VARCHAR},
  138. </if>
  139. <if test="ca_text3 != null">
  140. #{ca_text3,jdbcType=VARCHAR},
  141. </if>
  142. <if test="ca_text4 != null">
  143. #{ca_text4,jdbcType=VARCHAR},
  144. </if>
  145. <if test="ca_text5 != null">
  146. #{ca_text5,jdbcType=VARCHAR},
  147. </if>
  148. <if test="ca_address != null">
  149. #{ca_address,jdbcType=LONGVARCHAR},
  150. </if>
  151. </trim>
  152. </insert>
  153. <update id="updateByPrimaryKeySelective" parameterType="com.usoftchina.saas.document.entities.Customeraddress">
  154. update customeraddress
  155. <set>
  156. <if test="ca_cuid != null">
  157. ca_cuid = #{ca_cuid,jdbcType=INTEGER},
  158. </if>
  159. <if test="ca_detno != null">
  160. ca_detno = #{ca_detno,jdbcType=INTEGER},
  161. </if>
  162. <if test="ca_person != null">
  163. ca_person = #{ca_person,jdbcType=VARCHAR},
  164. </if>
  165. <if test="ca_phone != null">
  166. ca_phone = #{ca_phone,jdbcType=INTEGER},
  167. </if>
  168. <if test="ca_default != null">
  169. ca_default = #{ca_default,jdbcType=INTEGER},
  170. </if>
  171. <if test="companyid != null">
  172. companyid = #{companyid,jdbcType=INTEGER},
  173. </if>
  174. <if test="updaterid != null">
  175. updaterid = #{updaterid,jdbcType=INTEGER},
  176. </if>
  177. <if test="updatetime != null">
  178. updatetime = #{updatetime,jdbcType=TIMESTAMP},
  179. </if>
  180. <if test="ca_text1 != null">
  181. ca_text1 = #{ca_text1,jdbcType=VARCHAR},
  182. </if>
  183. <if test="ca_text2 != null">
  184. ca_text2 = #{ca_text2,jdbcType=VARCHAR},
  185. </if>
  186. <if test="ca_text3 != null">
  187. ca_text3 = #{ca_text3,jdbcType=VARCHAR},
  188. </if>
  189. <if test="ca_text4 != null">
  190. ca_text4 = #{ca_text4,jdbcType=VARCHAR},
  191. </if>
  192. <if test="ca_text5 != null">
  193. ca_text5 = #{ca_text5,jdbcType=VARCHAR},
  194. </if>
  195. <if test="ca_address != null">
  196. ca_address = #{ca_address,jdbcType=LONGVARCHAR},
  197. </if>
  198. </set>
  199. where ca_id = #{ca_id,jdbcType=INTEGER}
  200. </update>
  201. <update id="updateByPrimaryKeyWithBLOBs" parameterType="com.usoftchina.saas.document.entities.Customeraddress">
  202. update customeraddress
  203. set ca_cuid = #{ca_cuid,jdbcType=INTEGER},
  204. ca_detno = #{ca_detno,jdbcType=INTEGER},
  205. ca_person = #{ca_person,jdbcType=VARCHAR},
  206. ca_phone = #{ca_phone,jdbcType=INTEGER},
  207. ca_default = #{ca_default,jdbcType=INTEGER},
  208. companyid = #{companyid,jdbcType=INTEGER},
  209. updaterid = #{updaterid,jdbcType=INTEGER},
  210. updatetime = #{updatetime,jdbcType=TIMESTAMP},
  211. ca_text1 = #{ca_text1,jdbcType=VARCHAR},
  212. ca_text2 = #{ca_text2,jdbcType=VARCHAR},
  213. ca_text3 = #{ca_text3,jdbcType=VARCHAR},
  214. ca_text4 = #{ca_text4,jdbcType=VARCHAR},
  215. ca_text5 = #{ca_text5,jdbcType=VARCHAR},
  216. ca_address = #{ca_address,jdbcType=LONGVARCHAR}
  217. where ca_id = #{ca_id,jdbcType=INTEGER}
  218. </update>
  219. <update id="updateByPrimaryKey" parameterType="com.usoftchina.saas.document.entities.Customeraddress">
  220. update customeraddress
  221. set ca_cuid = #{ca_cuid,jdbcType=INTEGER},
  222. ca_detno = #{ca_detno,jdbcType=INTEGER},
  223. ca_person = #{ca_person,jdbcType=VARCHAR},
  224. ca_phone = #{ca_phone,jdbcType=INTEGER},
  225. ca_default = #{ca_default,jdbcType=INTEGER},
  226. companyid = #{companyid,jdbcType=INTEGER},
  227. updaterid = #{updaterid,jdbcType=INTEGER},
  228. updatetime = #{updatetime,jdbcType=TIMESTAMP},
  229. ca_text1 = #{ca_text1,jdbcType=VARCHAR},
  230. ca_text2 = #{ca_text2,jdbcType=VARCHAR},
  231. ca_text3 = #{ca_text3,jdbcType=VARCHAR},
  232. ca_text4 = #{ca_text4,jdbcType=VARCHAR},
  233. ca_text5 = #{ca_text5,jdbcType=VARCHAR}
  234. where ca_id = #{ca_id,jdbcType=INTEGER}
  235. </update>
  236. </mapper>