How to drop a primary key using ActiveRecord migrations
Posted
by knoopx
on Stack Overflow
See other posts from Stack Overflow
or by knoopx
Published on 2010-04-03T00:01:55Z
Indexed on
2010/04/03
0:03 UTC
Read the original article
Hit count: 320
Due to a mistake I forgot to add :id => false
to a has_many :trough
table creation migration.
Now I reverted the association back to a has_and_belongs_to_many
and ActiveRecord throws an exception complaining about the presence of the primary key.
I couldn't find any reference on the ActiveRecord documentation so, do you know if there is any standard, clean way of doing it?
© Stack Overflow or respective owner