demarches-normaliennes/lib/tasks/2018_09_20_procedure_presentation_jsonb.rake
2018-09-24 19:39:01 +02:00

9 lines
254 B
Ruby

namespace :'2018_09_20_procedure_presentation_jsonb' do
task run: :environment do
ProcedurePresentation.update_all(
<<~SQL
displayed_fields = ('[' || ARRAY_TO_STRING(old_displayed_fields, ',') || ']')::JSONB
SQL
)
end
end