1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.brilliance.isc.mda.dao.LsmMapper">
<resultMap id="BaseResultMap" type="com.brilliance.isc.bo.Lsm">
<result property="inr" column="inr" jdbcType="VARCHAR"/>
<result property="lsrinr" column="lsrinr" jdbcType="VARCHAR"/>
<result property="trninr" column="trninr" jdbcType="VARCHAR"/>
<result property="cbeinr" column="cbeinr" jdbcType="VARCHAR"/>
<result property="lsmflg" column="lsmflg" jdbcType="VARCHAR"/>
<result property="matdat" column="matdat" jdbcType="DATE"/>
<result property="cur" column="cur" jdbcType="VARCHAR"/>
<result property="amt" column="amt" jdbcType="DECIMAL"/>
</resultMap>
<sql id="Base_Column_List">
inr,lsrinr,trninr,cbeinr,lsmflg,matdat,cur,amt
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from lsm
where inr = #{inr,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey">
delete from lsm
where inr = #{inr,jdbcType=VARCHAR}
</delete>
<insert id="insert">
insert into lsm (<include refid="Base_Column_List" />)
<trim prefix="values (" suffix=")" suffixOverrides=",">
#{inr,jdbcType=VARCHAR},
#{lsrinr,jdbcType=VARCHAR},
#{trninr,jdbcType=VARCHAR},
#{cbeinr,jdbcType=VARCHAR},
#{lsmflg,jdbcType=VARCHAR},
#{matdat,jdbcType=DATE},
#{cur,jdbcType=VARCHAR},
#{amt,jdbcType=DECIMAL},
</trim>
</insert>
<insert id="insertSelective">
insert into lsm
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="inr != null">inr,</if>
<if test="lsrinr != null">lsrinr,</if>
<if test="trninr != null">trninr,</if>
<if test="cbeinr != null">cbeinr,</if>
<if test="lsmflg != null">lsmflg,</if>
<if test="matdat != null">matdat,</if>
<if test="cur != null">cur,</if>
<if test="amt != null">amt,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="inr != null">#{inr,jdbcType=VARCHAR}, </if>
<if test="lsrinr != null">#{lsrinr,jdbcType=VARCHAR}, </if>
<if test="trninr != null">#{trninr,jdbcType=VARCHAR}, </if>
<if test="cbeinr != null">#{cbeinr,jdbcType=VARCHAR}, </if>
<if test="lsmflg != null">#{lsmflg,jdbcType=VARCHAR}, </if>
<if test="matdat != null">#{matdat,jdbcType=DATE}, </if>
<if test="cur != null">#{cur,jdbcType=VARCHAR}, </if>
<if test="amt != null">#{amt,jdbcType=DECIMAL}, </if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective">
update lsm
<set>
<if test="lsrinr != null">lsrinr = #{lsrinr,jdbcType=VARCHAR},</if>
<if test="trninr != null">trninr = #{trninr,jdbcType=VARCHAR},</if>
<if test="cbeinr != null">cbeinr = #{cbeinr,jdbcType=VARCHAR},</if>
<if test="lsmflg != null">lsmflg = #{lsmflg,jdbcType=VARCHAR},</if>
<if test="matdat != null">matdat = #{matdat,jdbcType=DATE},</if>
<if test="cur != null">cur = #{cur,jdbcType=VARCHAR},</if>
<if test="amt != null">amt = #{amt,jdbcType=DECIMAL},</if>
</set>
where inr = #{inr,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey">
update lsm
<set>
lsrinr = #{lsrinr,jdbcType=VARCHAR},
trninr = #{trninr,jdbcType=VARCHAR},
cbeinr = #{cbeinr,jdbcType=VARCHAR},
lsmflg = #{lsmflg,jdbcType=VARCHAR},
matdat = #{matdat,jdbcType=DATE},
cur = #{cur,jdbcType=VARCHAR},
amt = #{amt,jdbcType=DECIMAL},
</set>
where inr = #{inr,jdbcType=VARCHAR}
</update>
<delete id="deleteByIds">
delete from act where inr in
<foreach item="item" index="index" collection="collection" open="(" separator="," close=")">
#{item}
</foreach>
</delete>
<update id="dyncUpdate">
update lsm
<set>
<if test="module.lsrinr != null">lsrinr = #{module.lsrinr,jdbcType=VARCHAR},</if>
<if test="module.trninr != null">trninr = #{module.trninr,jdbcType=VARCHAR},</if>
<if test="module.cbeinr != null">cbeinr = #{module.cbeinr,jdbcType=VARCHAR},</if>
<if test="module.lsmflg != null">lsmflg = #{module.lsmflg,jdbcType=VARCHAR},</if>
<if test="module.matdat != null">matdat = #{module.matdat,jdbcType=DATE},</if>
<if test="module.cur != null">cur = #{module.cur,jdbcType=VARCHAR},</if>
<if test="module.amt != null">amt = #{module.amt,jdbcType=DECIMAL},</if>
</set>
${conditions}
</update>
<delete id="dyncDelete">
${sql}
</delete>
<select id="dyncRead" resultMap="BaseResultMap">
${sql}
</select>
<select id="getLsmByCbeinr" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from lsm
where cbeinr = #{cbeinr,jdbcType=VARCHAR}
</select>
</mapper>