insert into complaint( store_id,owner_id,room_id,room_name,start_user_id,complaint_id,type_cd,owner_name,context,complaint_name,tel,state,community_id ) values ( #{storeId},#{ownerId},#{roomId},#{roomName},#{startUserId},#{complaintId},#{typeCd},#{ownerName},#{context},#{complaintName},#{tel},#{state},#{communityId} ) update complaint t set t.status_cd = #{statusCd} ,t.b_id = #{newBId} , t.owner_id= #{ownerId} , t.room_id= #{roomId} , t.room_name= #{roomName} , t.start_user_id= #{startUserId} , t.type_cd= #{typeCd} , t.owner_name= #{ownerName} , t.context= #{context} , t.complaint_name= #{complaintName} , t.tel= #{tel} , t.state= #{state} where 1=1 and t.complaint_id= #{complaintId} and t.community_id= #{communityId} and t.store_id= #{storeId}