insert into patrol_building(pb_id, staff_id, staff_name, state, community_id, floor_id, floor_num, title, remark, create_time) values (#{pbId}, #{staffId}, #{staffName}, #{state}, #{communityId}, #{floorId}, #{floorNum}, #{title}, #{remark}, #{createTime}) update patrol_building t set t.status_cd = #{statusCd} , t.staff_id= #{staffId} , t.staff_name = #{staffName} , t.state= #{state} , t.community_id= #{communityId} , t.floor_id= #{floorId} , t.floor_num= #{floorNum} , t.title= #{title} , t.remark= #{remark} where 1=1 and t.pb_id= #{pbId}