In Rails 3.0 it was called primary_key_name and in Rails 3.2 it was renamed to foreign_key .. out of confusion or whatever reason.