select id, battery_pack, battery_cluster, battery_cell_id, voltage, temperature, soc, soh, data_timestamp, create_by, create_time, update_by, update_time, remark, site_id, device_id, cluster_device_id, inter_resistance from ems_battery_data
insert into ems_battery_data
battery_pack,
battery_cluster,
battery_cell_id,
voltage,
temperature,
soc,
soh,
data_timestamp,
create_by,
create_time,
update_by,
update_time,
remark,
site_id,
device_id,
cluster_device_id,
inter_resistance,
#{batteryPack},
#{batteryCluster},
#{batteryCellId},
#{voltage},
#{temperature},
#{soc},
#{soh},
#{dataTimestamp},
#{createBy},
#{createTime},
#{updateBy},
#{updateTime},
#{remark},
#{siteId},
#{deviceId},
#{clusterDeviceId},
#{interResistance},
update ems_battery_data
battery_pack = #{batteryPack},
battery_cluster = #{batteryCluster},
battery_cell_id = #{batteryCellId},
voltage = #{voltage},
temperature = #{temperature},
soc = #{soc},
soh = #{soh},
data_timestamp = #{dataTimestamp},
create_by = #{createBy},
create_time = #{createTime},
update_by = #{updateBy},
update_time = #{updateTime},
remark = #{remark},
site_id = #{siteId},
device_id = #{deviceId},
cluster_device_id = #{clusterDeviceId},
inter_resistance = #{interResistance},
where id = #{id}
delete from ems_battery_data where id = #{id}
delete from ems_battery_data where id in
#{id}
INSERT INTO ems_battery_data (
battery_pack, battery_cluster, battery_cell_id,
voltage, temperature, soc, soh, data_timestamp,
create_by, create_time, update_by, update_time,
remark, site_id, device_id, cluster_device_id, inter_resistance
) VALUES
(
#{item.batteryPack}, #{item.batteryCluster}, #{item.batteryCellId},
#{item.voltage}, #{item.temperature}, #{item.soc}, #{item.soh}, #{item.dataTimestamp},
#{item.createBy}, #{item.createTime}, #{item.updateBy}, #{item.updateTime},
#{item.remark}, #{item.siteId}, #{item.deviceId}, #{item.clusterDeviceId},#{item.interResistance}
)