select scene_id, scene_name, tenant_id, scene_mode_id, scene_pic, default_flag, scene_status, auth_mode, mode_account, mode_key, mode_secret, preserve_time, test_preserve_time, remark, create_by, create_time, update_by, update_time, scene_environment, scene_field from hw_scene
insert into hw_scene
scene_name,
tenant_id,
scene_mode_id,
scene_pic,
default_flag,
scene_status,
auth_mode,
mode_account,
mode_key,
mode_secret,
preserve_time,
test_preserve_time,
remark,
create_by,
create_time,
update_by,
update_time,
scene_environment,
scene_field,
#{sceneName},
#{tenantId},
#{sceneModeId},
#{scenePic},
#{defaultFlag},
#{sceneStatus},
#{authMode},
#{modeAccount},
#{modeKey},
#{modeSecret},
#{preserveTime},
#{testPreserveTime},
#{remark},
#{createBy},
#{createTime},
#{updateBy},
#{updateTime},
#{sceneEnvironment},
#{sceneField},
update hw_scene
set default_flag = '0'
where tenant_id = #{tenantId}
update hw_scene
scene_name = #{sceneName},
tenant_id = #{tenantId},
scene_mode_id = #{sceneModeId},
scene_pic = #{scenePic},
default_flag = #{defaultFlag},
scene_status = #{sceneStatus},
auth_mode = #{authMode},
mode_account = #{modeAccount},
mode_key = #{modeKey},
mode_secret = #{modeSecret},
preserve_time = #{preserveTime},
test_preserve_time = #{testPreserveTime},
remark = #{remark},
create_by = #{createBy},
create_time = #{createTime},
update_by = #{updateBy},
update_time = #{updateTime},
scene_environment = #{sceneEnvironment},
scene_field = #{sceneField},
where scene_id = #{sceneId}
update hw_scene set scene_status = '9' where scene_id = #{sceneId}
update hw_scene set scene_status = '9' where scene_id = in
#{sceneId}