Commit 68b42aaa authored by zhouleilei's avatar zhouleilei

国产化替代-瀚高数据库替换MySQL --修改utc和hisen服务兼容瀚高数据库

parent ca01a407
...@@ -34,10 +34,10 @@ ...@@ -34,10 +34,10 @@
where id = #{id,jdbcType=INTEGER} where id = #{id,jdbcType=INTEGER}
</delete> </delete>
<insert id="insert" parameterType="net.wanji.web.entity.TBaseAreaInfo"> <insert id="insert" parameterType="net.wanji.web.entity.TBaseAreaInfo">
insert into t_base_area_info (id, code, name, insert into t_base_area_info (code, name,
type, parent_code, location, type, parent_code, location,
gmt_create, gmt_modified, polylines) gmt_create, gmt_modified, polylines)
values (#{id,jdbcType=INTEGER}, #{code,jdbcType=INTEGER}, #{name,jdbcType=VARCHAR}, values (#{code,jdbcType=INTEGER}, #{name,jdbcType=VARCHAR},
#{type,jdbcType=TINYINT}, #{parentCode,jdbcType=INTEGER}, #{location,jdbcType=VARCHAR}, #{type,jdbcType=TINYINT}, #{parentCode,jdbcType=INTEGER}, #{location,jdbcType=VARCHAR},
#{gmtCreate,jdbcType=TIMESTAMP}, #{gmtModified,jdbcType=TIMESTAMP}, #{polylines,jdbcType=LONGVARCHAR}) #{gmtCreate,jdbcType=TIMESTAMP}, #{gmtModified,jdbcType=TIMESTAMP}, #{polylines,jdbcType=LONGVARCHAR})
</insert> </insert>
......
...@@ -29,7 +29,7 @@ ...@@ -29,7 +29,7 @@
</resultMap> </resultMap>
<sql id="Base_Column_List"> <sql id="Base_Column_List">
id, cross_id, scheme_id, dir_type, turn_type, offset, ring_no, phase_no, phase_order_id, ori_green_time, id, cross_id, scheme_id, dir_type, turn_type, "offset", ring_no, phase_no, phase_order_id, ori_green_time,
opt_time, opt_type, opt_reason, start_time, end_time, is_relation, relation_cross_id, opt_result, opt_result_desc, opt_time, opt_type, opt_reason, start_time, end_time, is_relation, relation_cross_id, opt_result, opt_result_desc,
data_batch_time, restore_result, data_extend data_batch_time, restore_result, data_extend
</sql> </sql>
...@@ -71,7 +71,7 @@ ...@@ -71,7 +71,7 @@
</select> </select>
<insert id="insertOne" parameterType="net.wanji.opt.po.base.CrossSchemeOptLogPO"> <insert id="insertOne" parameterType="net.wanji.opt.po.base.CrossSchemeOptLogPO">
insert into t_base_cross_scheme_opt_log (cross_id, scheme_id, dir_type, turn_type, offset, ring_no, phase_no, insert into t_base_cross_scheme_opt_log (cross_id, scheme_id, dir_type, turn_type, "offset", ring_no, phase_no,
phase_order_id, ori_green_time, opt_time, opt_type, opt_reason, phase_order_id, ori_green_time, opt_time, opt_type, opt_reason,
start_time, start_time,
end_time, is_relation, relation_cross_id, opt_result, opt_result_desc, end_time, is_relation, relation_cross_id, opt_result, opt_result_desc,
...@@ -83,7 +83,7 @@ ...@@ -83,7 +83,7 @@
<insert id="insertBatch" parameterType="net.wanji.opt.po.base.CrossSchemeOptLogPO"> <insert id="insertBatch" parameterType="net.wanji.opt.po.base.CrossSchemeOptLogPO">
insert into t_base_cross_scheme_opt_log insert into t_base_cross_scheme_opt_log
(cross_id, scheme_id, dir_type, turn_type, offset, ring_no, phase_no, (cross_id, scheme_id, dir_type, turn_type, "offset", ring_no, phase_no,
phase_order_id, ori_green_time, opt_time, opt_type, opt_reason, phase_order_id, ori_green_time, opt_time, opt_type, opt_reason,
start_time, end_time, is_relation, relation_cross_id, opt_result, opt_result_desc, start_time, end_time, is_relation, relation_cross_id, opt_result, opt_result_desc,
data_batch_time, restore_result, data_extend) data_batch_time, restore_result, data_extend)
......
...@@ -19,7 +19,7 @@ ...@@ -19,7 +19,7 @@
</resultMap> </resultMap>
<sql id="baseColumnList"> <sql id="baseColumnList">
id,scheme_no,name,cross_id,cycle,coord_phase,offset,source,is_deleted,status,gmt_create,gmt_modified id,scheme_no,name,cross_id,cycle,coord_phase,"offset",source,is_deleted,status,gmt_create,gmt_modified
</sql> </sql>
<!-- 查询方案基础信息列表 --> <!-- 查询方案基础信息列表 -->
...@@ -31,7 +31,7 @@ ...@@ -31,7 +31,7 @@
cross_id, cross_id,
cycle, cycle,
coord_phase, coord_phase,
offset "offset"
from from
t_base_cross_scheme t_base_cross_scheme
where 1=1 where 1=1
...@@ -47,7 +47,7 @@ ...@@ -47,7 +47,7 @@
</select> </select>
<insert id="insertBatch" keyProperty="id" useGeneratedKeys="true"> <insert id="insertBatch" keyProperty="id" useGeneratedKeys="true">
insert into t_base_cross_scheme(scheme_no,name,cross_id,cycle,coord_phase,offset,source,is_deleted,status) insert into t_base_cross_scheme(scheme_no,name,cross_id,cycle,coord_phase,"offset",source,is_deleted,status)
values values
<foreach collection="entities" item="entity" separator=","> <foreach collection="entities" item="entity" separator=",">
(#{entity.schemeNo},#{entity.name},#{entity.crossId},#{entity.cycle},#{entity.coordPhase},#{entity.offset},#{entity.source},#{entity.isDeleted},#{entity.status}) (#{entity.schemeNo},#{entity.name},#{entity.crossId},#{entity.cycle},#{entity.coordPhase},#{entity.offset},#{entity.source},#{entity.isDeleted},#{entity.status})
...@@ -55,7 +55,7 @@ ...@@ -55,7 +55,7 @@
</insert> </insert>
<insert id="insertOne"> <insert id="insertOne">
insert into t_base_cross_scheme(scheme_no,name,cross_id,cycle,coord_phase,offset,source,is_deleted,status) insert into t_base_cross_scheme(scheme_no,name,cross_id,cycle,coord_phase,"offset",source,is_deleted,status)
values (#{schemeNo},#{name},#{crossId},#{cycle},#{coordPhase},#{offset},#{source},#{isDeleted},#{status}) values (#{schemeNo},#{name},#{crossId},#{cycle},#{coordPhase},#{offset},#{source},#{isDeleted},#{status})
</insert> </insert>
...@@ -79,7 +79,7 @@ ...@@ -79,7 +79,7 @@
coord_phase = #{coordPhase}, coord_phase = #{coordPhase},
</if> </if>
<if test="offset != null and offset != ''"> <if test="offset != null and offset != ''">
offset = #{offset}, "offset" = #{offset},
</if> </if>
<if test="source != null and source != ''"> <if test="source != null and source != ''">
source = #{source}, source = #{source},
...@@ -118,7 +118,7 @@ ...@@ -118,7 +118,7 @@
<select id="selectByCrossId" resultMap="BaseResultMap"> <select id="selectByCrossId" resultMap="BaseResultMap">
select select
id,scheme_no,name,cross_id,cycle,coord_phase,offset,source,is_deleted,status,gmt_create,gmt_modified id,scheme_no,name,cross_id,cycle,coord_phase,"offset",source,is_deleted,status,gmt_create,gmt_modified
from t_base_cross_scheme from t_base_cross_scheme
where cross_id = #{crossId} where cross_id = #{crossId}
</select> </select>
...@@ -130,14 +130,14 @@ ...@@ -130,14 +130,14 @@
<select id="selectByCrossIdAndSchemeName" resultMap="BaseResultMap"> <select id="selectByCrossIdAndSchemeName" resultMap="BaseResultMap">
select select
id,scheme_no,name,cross_id,cycle,coord_phase,offset,source,is_deleted,status,gmt_create,gmt_modified id,scheme_no,name,cross_id,cycle,coord_phase,"offset",source,is_deleted,status,gmt_create,gmt_modified
from t_base_cross_scheme from t_base_cross_scheme
where cross_id = #{crossId} and name = #{schemeName} where cross_id = #{crossId} and name = #{schemeName}
</select> </select>
<select id="selectById" resultType="net.wanji.databus.dao.entity.BaseCrossSchemePO"> <select id="selectById" resultType="net.wanji.databus.dao.entity.BaseCrossSchemePO">
select select
id,scheme_no,name,cross_id,cycle,coord_phase,offset,source,is_deleted,status,gmt_create,gmt_modified id,scheme_no,name,cross_id,cycle,coord_phase,"offset",source,is_deleted,status,gmt_create,gmt_modified
from t_base_cross_scheme from t_base_cross_scheme
where id = #{id} where id = #{id}
</select> </select>
...@@ -157,7 +157,7 @@ ...@@ -157,7 +157,7 @@
<select id="selectByCrossIdAndSchemeNo" resultType="net.wanji.databus.dao.entity.BaseCrossSchemePO"> <select id="selectByCrossIdAndSchemeNo" resultType="net.wanji.databus.dao.entity.BaseCrossSchemePO">
select select
id,scheme_no,name,cross_id,cycle,coord_phase,offset,source,is_deleted,status,gmt_create,gmt_modified id,scheme_no,name,cross_id,cycle,coord_phase,"offset",source,is_deleted,status,gmt_create,gmt_modified
from t_base_cross_scheme from t_base_cross_scheme
where cross_id = #{crossId} and scheme_no = #{schemeNo} where cross_id = #{crossId} and scheme_no = #{schemeNo}
</select> </select>
...@@ -175,13 +175,13 @@ ...@@ -175,13 +175,13 @@
<select id="selectAll" resultType="net.wanji.databus.dao.entity.BaseCrossSchemePO"> <select id="selectAll" resultType="net.wanji.databus.dao.entity.BaseCrossSchemePO">
select select
id,scheme_no,name,cross_id,cycle,coord_phase,offset,source,is_deleted,status,gmt_create,gmt_modified id,scheme_no,name,cross_id,cycle,coord_phase,"offset",source,is_deleted,status,gmt_create,gmt_modified
from t_base_cross_scheme from t_base_cross_scheme
</select> </select>
<select id="selectByCrossIdAndSchemeId" resultType="net.wanji.databus.dao.entity.BaseCrossSchemePO"> <select id="selectByCrossIdAndSchemeId" resultType="net.wanji.databus.dao.entity.BaseCrossSchemePO">
select select
id,scheme_no,name,cross_id,cycle,coord_phase,offset,source,is_deleted,status,gmt_create,gmt_modified id,scheme_no,name,cross_id,cycle,coord_phase,"offset",source,is_deleted,status,gmt_create,gmt_modified
from t_base_cross_scheme from t_base_cross_scheme
where cross_id = #{crossId} and id = #{schemeId} where cross_id = #{crossId} and id = #{schemeId}
</select> </select>
...@@ -228,7 +228,7 @@ ...@@ -228,7 +228,7 @@
scheme.scheme_no AS schemeId, scheme.scheme_no AS schemeId,
scheme.`name` AS name, scheme.`name` AS name,
scheme.cycle AS cycle, scheme.cycle AS cycle,
scheme.`offset` AS offset, scheme."offset" AS offset,
section.control_mode AS controlMode section.control_mode AS controlMode
FROM FROM
t_cross_schedules schedules t_cross_schedules schedules
...@@ -256,7 +256,7 @@ ...@@ -256,7 +256,7 @@
</select> </select>
<select id="selectSchemeByParams" resultType="net.wanji.databus.dao.entity.BaseCrossSchemePO"> <select id="selectSchemeByParams" resultType="net.wanji.databus.dao.entity.BaseCrossSchemePO">
SELECT SELECT
scheme.id AS id,scheme.scheme_no AS schemeNo,scheme.name AS name,scheme.cross_id AS crossId,scheme.cycle AS cycle,scheme.coord_phase AS coordPhase,scheme.offset AS offset,scheme.source AS source,scheme.is_deleted AS isDeleted,scheme.status AS status,scheme.gmt_create AS gmtCreate,scheme.gmt_modified AS gmtModified scheme.id AS id,scheme.scheme_no AS schemeNo,scheme.name AS name,scheme.cross_id AS crossId,scheme.cycle AS cycle,scheme.coord_phase AS coordPhase,scheme."offset" AS offset,scheme.source AS source,scheme.is_deleted AS isDeleted,scheme.status AS status,scheme.gmt_create AS gmtCreate,scheme.gmt_modified AS gmtModified
FROM FROM
t_cross_schedules schedules t_cross_schedules schedules
LEFT JOIN t_cross_section section ON section.cross_id = schedules.cross_id LEFT JOIN t_cross_section section ON section.cross_id = schedules.cross_id
...@@ -277,7 +277,7 @@ ...@@ -277,7 +277,7 @@
) )
) )
) )
AND TO_CHAR( #{queryTime}, 'HH24:MI' ) BETWEEN TO_CHAR( CAST( section.start_time AS TIME ), 'HH24:MI' ) AND TO_CHAR( CAST( #{queryTime} AS TIME ), 'HH24:MI' ) BETWEEN TO_CHAR( CAST( section.start_time AS TIME ), 'HH24:MI' )
AND TO_CHAR( CAST( section.end_time AS TIME ), 'HH24:MI' ) AND TO_CHAR( CAST( section.end_time AS TIME ), 'HH24:MI' )
ORDER BY schedules.special_date, TO_CHAR( CAST( section.end_time AS TIME ), 'HH24:MI' ),schedules.special_date DESC LIMIT 1 ORDER BY schedules.special_date, TO_CHAR( CAST( section.end_time AS TIME ), 'HH24:MI' ),schedules.special_date DESC LIMIT 1
......
...@@ -15,8 +15,8 @@ ...@@ -15,8 +15,8 @@
</resultMap> </resultMap>
<insert id="insertOne" keyProperty="id" useGeneratedKeys="true"> <insert id="insertOne" keyProperty="id" useGeneratedKeys="true">
insert into t_cross_lights(id,lights_no,name,type,dir,turn,cross_id,in_out_type) insert into t_cross_lights(lights_no,name,type,dir,turn,cross_id,in_out_type)
values (#{id},#{lightsNo},#{name},#{type},#{dir},#{turn},#{crossId},#{inOutType}) values (#{lightsNo},#{name},#{type},#{dir},#{turn},#{crossId},#{inOutType})
</insert> </insert>
<delete id="deleteOne"> <delete id="deleteOne">
......
...@@ -12,10 +12,10 @@ ...@@ -12,10 +12,10 @@
<!-- 批量新增数据 --> <!-- 批量新增数据 -->
<insert id="insertBatch" keyProperty="id" useGeneratedKeys="true"> <insert id="insertBatch" keyProperty="id" useGeneratedKeys="true">
insert into t_cross_phase_lights(id,lights_id,phase_id,cross_id) insert into t_cross_phase_lights(lights_id,phase_id,cross_id)
values values
<foreach collection="entities" item="entity" separator=","> <foreach collection="entities" item="entity" separator=",">
(#{entity.id},#{entity.lightsId},#{entity.phaseId},#{entity.crossId}) (#{entity.lightsId},#{entity.phaseId},#{entity.crossId})
</foreach> </foreach>
</insert> </insert>
......
...@@ -32,16 +32,16 @@ ...@@ -32,16 +32,16 @@
</sql> </sql>
<insert id="insertOne" keyProperty="id" useGeneratedKeys="true"> <insert id="insertOne" keyProperty="id" useGeneratedKeys="true">
insert into t_cross_phase(id,phase_no,name,sort,cross_id,plan_id,ring_no,group_no,phase_type,control_mode,phase_time,green_time,green_flash_time,ped_flash_time,yellow_time,yellow_flash_time,red_time,red_flash_time,min_green_time,max_green_time) insert into t_cross_phase(phase_no,name,sort,cross_id,plan_id,ring_no,group_no,phase_type,control_mode,phase_time,green_time,green_flash_time,ped_flash_time,yellow_time,yellow_flash_time,red_time,red_flash_time,min_green_time,max_green_time)
values (#{id},#{phaseNo},#{name},#{sort},#{crossId},#{planId},#{ringNo},#{groupNo},#{phaseType},#{controlMode},#{phaseTime},#{greenTime},#{greenFlashTime},#{pedFlashTime},#{yellowTime},#{yellowFlashTime},#{redTime},#{redFlashTime},#{minGreenTime},#{maxGreenTime}) values (#{phaseNo},#{name},#{sort},#{crossId},#{planId},#{ringNo},#{groupNo},#{phaseType},#{controlMode},#{phaseTime},#{greenTime},#{greenFlashTime},#{pedFlashTime},#{yellowTime},#{yellowFlashTime},#{redTime},#{redFlashTime},#{minGreenTime},#{maxGreenTime})
</insert> </insert>
<insert id="insertBatch" keyProperty="id" useGeneratedKeys="true"> <insert id="insertBatch" keyProperty="id" useGeneratedKeys="true">
insert into t_cross_phase(id,phase_no,name,sort,cross_id,plan_id,ring_no,control_mode,phase_time,green_time, insert into t_cross_phase(phase_no,name,sort,cross_id,plan_id,ring_no,control_mode,phase_time,green_time,
green_flash_time,ped_flash_time,yellow_time,red_time,min_green_time,max_green_time) green_flash_time,ped_flash_time,yellow_time,red_time,min_green_time,max_green_time)
values values
<foreach collection="entities" item="entity" separator=","> <foreach collection="entities" item="entity" separator=",">
(#{entity.id},#{entity.phaseNo},#{entity.name},#{entity.sort},#{entity.crossId},#{entity.planId},#{entity.ringNo}, (#{entity.phaseNo},#{entity.name},#{entity.sort},#{entity.crossId},#{entity.planId},#{entity.ringNo},
#{entity.controlMode},#{entity.phaseTime},#{entity.greenTime},#{entity.greenFlashTime},#{entity.pedFlashTime}, #{entity.controlMode},#{entity.phaseTime},#{entity.greenTime},#{entity.greenFlashTime},#{entity.pedFlashTime},
#{entity.yellowTime},#{entity.redTime},#{entity.minGreenTime},#{entity.maxGreenTime}) #{entity.yellowTime},#{entity.redTime},#{entity.minGreenTime},#{entity.maxGreenTime})
</foreach> </foreach>
...@@ -73,12 +73,12 @@ ...@@ -73,12 +73,12 @@
<select id="selectIdsByPhaseNo" resultType="java.lang.Integer"> <select id="selectIdsByPhaseNo" resultType="java.lang.Integer">
select id from t_cross_phase select id from t_cross_phase
where cross_id = #{crossId} and phase_no = #{phaseNo} where cross_id = #{crossId} and phase_no = CAST(#{phaseNo} AS VARCHAR)
</select> </select>
<select id="selectPhaseId" resultType="java.lang.Integer"> <select id="selectPhaseId" resultType="java.lang.Integer">
select id from t_cross_phase select id from t_cross_phase
where cross_id = #{crossId} and plan_id = #{schemeId} and phase_no = #{phaseNo} where cross_id = #{crossId} and plan_id = #{schemeId} and phase_no = CAST(#{phaseNo} AS VARCHAR)
</select> </select>
<select id="selectByCrossId" resultMap="BaseResultMap"> <select id="selectByCrossId" resultMap="BaseResultMap">
......
...@@ -12,27 +12,27 @@ ...@@ -12,27 +12,27 @@
<!--新增数据--> <!--新增数据-->
<insert id="insertOne" keyProperty="id" useGeneratedKeys="true"> <insert id="insertOne" keyProperty="id" useGeneratedKeys="true">
insert into t_cross_plan(id,plan_no,name,cross_id) insert into t_cross_plan(plan_no,name,cross_id)
values (#{id},#{planNo},#{name},#{crossId}) values (#{planNo},#{name},#{crossId})
</insert> </insert>
<insert id="insertBatch" keyProperty="id" useGeneratedKeys="true"> <insert id="insertBatch" keyProperty="id" useGeneratedKeys="true">
insert into t_cross_plan(id,plan_no,name,cross_id) insert into t_cross_plan(plan_no,name,cross_id)
values values
<foreach collection="entities" item="entity" separator=","> <foreach collection="entities" item="entity" separator=",">
(#{entity.id},#{entity.planNo},#{entity.name},#{entity.crossId}) (#{entity.planNo},#{entity.name},#{entity.crossId})
</foreach> </foreach>
</insert> </insert>
<delete id="deleteOne"> <delete id="deleteOne">
delete from t_cross_plan delete from t_cross_plan
where cross_id = #{crossId} and plan_no = #{planNo} where cross_id = #{crossId} and plan_no = CAST(#{planNo} AS VARCHAR)
</delete> </delete>
<select id="selectIdByNo" resultType="java.lang.Integer"> <select id="selectIdByNo" resultType="java.lang.Integer">
select id select id
from t_cross_plan from t_cross_plan
where cross_id = #{crossId} and plan_no = #{planNo} where cross_id = #{crossId} and plan_no = CAST(#{planNo} AS VARCHAR)
</select> </select>
<select id="selectByCrossId" resultMap="BaseResultMap"> <select id="selectByCrossId" resultMap="BaseResultMap">
...@@ -46,7 +46,7 @@ ...@@ -46,7 +46,7 @@
select select
id,plan_no,name,cross_id,gmt_create,gmt_modified id,plan_no,name,cross_id,gmt_create,gmt_modified
from t_cross_plan from t_cross_plan
where cross_id = #{crossId} and plan_no = #{planNo} where cross_id = #{crossId} and plan_no = CAST(#{planNo} AS VARCHAR)
</select> </select>
<select id="selectById" resultType="net.wanji.databus.dao.entity.CrossPlanPO"> <select id="selectById" resultType="net.wanji.databus.dao.entity.CrossPlanPO">
......
...@@ -18,10 +18,10 @@ ...@@ -18,10 +18,10 @@
<!-- 批量新增数据 --> <!-- 批量新增数据 -->
<insert id="insertBatch" keyProperty="id" useGeneratedKeys="true"> <insert id="insertBatch" keyProperty="id" useGeneratedKeys="true">
insert into t_cross_schedules(id,schedule_no,name,cross_id,plan_id,week,special_date,months,weeks,days) insert into t_cross_schedules(schedule_no,name,cross_id,plan_id,week,special_date,months,weeks,days)
values values
<foreach collection="entities" item="entity" separator=","> <foreach collection="entities" item="entity" separator=",">
(#{entity.id},#{entity.scheduleNo},#{entity.name},#{entity.crossId},#{entity.planId},#{entity.week}, (#{entity.scheduleNo},#{entity.name},#{entity.crossId},#{entity.planId},#{entity.week},
#{entity.specialDate},#{entity.months},#{entity.weeks},#{entity.days}) #{entity.specialDate},#{entity.months},#{entity.weeks},#{entity.days})
</foreach> </foreach>
</insert> </insert>
......
...@@ -17,10 +17,10 @@ ...@@ -17,10 +17,10 @@
<!-- 批量新增数据 --> <!-- 批量新增数据 -->
<insert id="insertBatch" keyProperty="id" useGeneratedKeys="true"> <insert id="insertBatch" keyProperty="id" useGeneratedKeys="true">
insert into t_cross_scheme(id,scheme_no,name,cross_id,cycle,coord_phase,"offset",source,is_deleted) insert into t_cross_scheme(scheme_no,name,cross_id,cycle,coord_phase,"offset",source,is_deleted)
values values
<foreach collection="entities" item="entity" separator=","> <foreach collection="entities" item="entity" separator=",">
(#{entity.id},#{entity.schemeNo},#{entity.name},#{entity.crossId},#{entity.cycle},#{entity.coordPhase},#{entity.offset},#{entity.source},#{entity.isDeleted}) (#{entity.schemeNo},#{entity.name},#{entity.crossId},#{entity.cycle},#{entity.coordPhase},#{entity.offset},#{entity.source},#{entity.isDeleted})
</foreach> </foreach>
</insert> </insert>
......
...@@ -15,15 +15,15 @@ ...@@ -15,15 +15,15 @@
</resultMap> </resultMap>
<insert id="insertOne" keyProperty="id" useGeneratedKeys="true"> <insert id="insertOne" keyProperty="id" useGeneratedKeys="true">
insert into t_cross_section(id,section_no, start_time, end_time, cross_id, plan_id, control_mode, scheme_id) insert into t_cross_section(section_no, start_time, end_time, cross_id, plan_id, control_mode, scheme_id)
values (#{id},#{sectionNo}, #{startTime}, #{endTime}, #{crossId}, #{planId}, #{controlMode}, #{schemeId}) values (#{sectionNo}, #{startTime}, #{endTime}, #{crossId}, #{planId}, #{controlMode}, #{schemeId})
</insert> </insert>
<insert id="insertBatch" keyProperty="id" useGeneratedKeys="true"> <insert id="insertBatch" keyProperty="id" useGeneratedKeys="true">
insert into t_cross_section(id,section_no,start_time,end_time,cross_id,plan_id,control_mode,scheme_id) insert into t_cross_section(section_no,start_time,end_time,cross_id,plan_id,control_mode,scheme_id)
values values
<foreach collection="entities" item="entity" separator=","> <foreach collection="entities" item="entity" separator=",">
(#{entity.id},#{entity.sectionNo},#{entity.startTime},#{entity.endTime},#{entity.crossId},#{entity.planId},#{entity.controlMode},#{entity.schemeId}) (#{entity.sectionNo},#{entity.startTime},#{entity.endTime},#{entity.crossId},#{entity.planId},#{entity.controlMode},#{entity.schemeId})
</foreach> </foreach>
</insert> </insert>
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
<mapper namespace="net.wanji.databus.dao.mapper.GreenwaveCrossMapper"> <mapper namespace="net.wanji.databus.dao.mapper.GreenwaveCrossMapper">
<sql id="Base_Column_List"> <sql id="Base_Column_List">
id,green_id,cross_id,in_dir,out_dir,offset,sort,section_id,next_cross_len, id,green_id,cross_id,in_dir,out_dir,"offset",sort,section_id,next_cross_len,
is_key_route,gmt_create,gmt_modified, start_time, end_time, week is_key_route,gmt_create,gmt_modified, start_time, end_time, week
</sql> </sql>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment