diff --git a/lib/tasks/one_off.rake b/lib/tasks/one_off.rake index 7465046f..5fce6b62 100644 --- a/lib/tasks/one_off.rake +++ b/lib/tasks/one_off.rake @@ -4,8 +4,8 @@ namespace :one_off do combined_school.update qualtrics_code: 5 full_circle = School.find_by_name 'Full Circle High School' next_wave = School.find_by_name 'Next Wave Junior High School' - SurveyItemResponse.where(school: [full_circle, next_wave]).update! school: combined_school - full_circle.destroy - next_wave.destroy + SurveyItemResponse.where(school: [full_circle, next_wave]).update_all school_id: combined_school.id + full_circle.destroy! + next_wave.destroy! end end