2007-03-27 railsのリレーションで外部キーのカラムを指定 メモ has_one :hoge,:foreign_key => :foo_id belongs_to :hoge,:foreign_key => :foo_id とか