I want to push dummy content in my database. There is a 1:n relationship concepted in my models.
seeds.rb
:
city= City.create([{:ort_name=>"Hagen"}])
person= Person.create([{:name = "root"}])
I try this
city << person
and
person.city_id = city.id
How would you do this?