From ea5ef3bcf69b70f9b68edd2aeb3b2122a61b2b45 Mon Sep 17 00:00:00 2001 From: Sam Date: Tue, 28 Jul 2015 10:50:02 +1000 Subject: [PATCH] correct index on name value to drop long values --- ...50724165259_add_index_to_post_custom_fields.rb | 13 +++++++++++-- ...50728004647_correct_custom_fields_migration.rb | 15 +++++++++++++++ 2 files changed, 26 insertions(+), 2 deletions(-) create mode 100644 db/migrate/20150728004647_correct_custom_fields_migration.rb diff --git a/db/migrate/20150724165259_add_index_to_post_custom_fields.rb b/db/migrate/20150724165259_add_index_to_post_custom_fields.rb index b0197d311f3..230b3d499f6 100644 --- a/db/migrate/20150724165259_add_index_to_post_custom_fields.rb +++ b/db/migrate/20150724165259_add_index_to_post_custom_fields.rb @@ -1,5 +1,14 @@ class AddIndexToPostCustomFields < ActiveRecord::Migration - def change - add_index :post_custom_fields, [:name, :value] + def up + execute <