select channel_id,
channel_code,
up_system_device_code,
channel_name,
parent_channel_id,
eqp_book_id,
channel_type,
online_state,
channel_content,
provider,
address,
host,
port,
create_by,
create_time,
update_by,
update_time,
delete_flag,
patrol_device_code,
username,
password,
device_source
from basedata_eqpbook_channel
insert into basedata_eqpbook_channel
channel_code,
channel_name,
parent_channel_id,
eqp_book_id,
channel_type,
online_state,
channel_content,
provider,
address,
host,
port,
create_by,
create_time,
update_by,
update_time,
delete_flag,
patrol_device_code,
username,
password,
device_source,
#{channelCode},
#{channelName},
#{parentChannelId},
#{eqpBookId},
#{channelType},
#{onlineState},
#{channelContent},
#{provider},
#{address},
#{host},
#{port},
#{createBy},
#{createTime},
#{updateBy},
#{updateTime},
#{deleteFlag},
#{patrolDeviceCode},
#{username},
#{password},
#{deviceSource},
update basedata_eqpbook_channel
channel_code = #{channelCode},
channel_name = #{channelName},
parent_channel_id = #{parentChannelId},
eqp_book_id = #{eqpBookId},
channel_type = #{channelType},
online_state = #{onlineState},
channel_content = #{channelContent},
provider = #{provider},
address = #{address},
host = #{host},
port = #{port},
create_by = #{createBy},
create_time = #{createTime},
update_by = #{updateBy},
update_time = #{updateTime},
delete_flag = #{deleteFlag},
patrol_device_code = #{patrolDeviceCode},
username = #{username},
password = #{password},
device_source = #{deviceSource},
where channel_id = #{channelId}
delete
from basedata_eqpbook_channel
where channel_id = #{channelId}
delete from basedata_eqpbook_channel where channel_id in
#{channelId}