Displaying 1 result from an estimated 1 matches for "n2n_id".
Did you mean:
min_id
2006 Apr 23
0
Severe STI, HABTM with Attributes and 1.1
..._many
:through
The original schema I had worked like this :
create_table "nodes" do |t|
t.column "title", :string
t.column "body", :integer
t.column "type", :string
end
create_table "nodes_to_nodes", :id => true, :primary_key => "n2n_id",
:force => true do |t|
t.column :node_id, :integer, :default => 0, :null => false
t.column :node_fk_id, :integer, :default => 0, :null => false
t.column :position, :integer
t.column :foreign_type, :string
end
class NodesToNodes < ActiveRecord::Base
set_primary_key...