search for: association_foreign

Displaying 1 result from an estimated 1 matches for "association_foreign".

2007 Oct 22
1
self-referential habtm: why are my keys null?
...rent_id, :integer t.column :child_id, :integer end end def self.down drop_table :nodes_nodes end end And here is the model: class Node < ActiveRecord::Base has_and_belongs_to_many :parents, :foreign_key => :child_id, :association_foreign_key => :parent_id, :class_name => ''Node''; has_and_belongs_to_many :children, :foreign_key => :parent_id, :association_foreign_key => :child_id, :class_na...