summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--db/migrate/20221012135202_add_index_to_custom_values.rb6
1 files changed, 6 insertions, 0 deletions
diff --git a/db/migrate/20221012135202_add_index_to_custom_values.rb b/db/migrate/20221012135202_add_index_to_custom_values.rb
new file mode 100644
index 000000000..21f5670aa
--- /dev/null
+++ b/db/migrate/20221012135202_add_index_to_custom_values.rb
@@ -0,0 +1,6 @@
+class AddIndexToCustomValues < ActiveRecord::Migration[6.1]
+ def change
+ remove_index :custom_values, column: [:customized_type, :customized_id], name: :custom_values_customized, if_exists: true
+ add_index :custom_values, [:customized_type, :customized_id, :custom_field_id], name: :custom_values_customized_custom_field
+ end
+end