Method: ActiveRecord::ConnectionAdapters::Table#rename_index
- Defined in:
- lib/active_record/connection_adapters/abstract/schema_definitions.rb
#rename_index(index_name, new_index_name) ⇒ Object
Renames the given index on the table.
t.rename_index(:user_id, :account_id)
389 390 391 |
# File 'lib/active_record/connection_adapters/abstract/schema_definitions.rb', line 389 def rename_index(index_name, new_index_name) @base.rename_index(@table_name, index_name, new_index_name) end |