On Dec 22, 9:16 am, John Smith <rails-mailing-l...@andreas-s.net>
wrote:
> I have this problem.
> I have a Job table in my db, and each job has many steps (table Step).
> Is not possible to know how many steps a job has until it is created. So
> when I create a new job I have a problem: I can not have a step_id in my
> Job table, because it can be one step or more.
> What can I do?

If jobs has_many :steps then the jobs table doesn't have a step_id at
all: steps have a job_id column.

Fred
> --
> Posted viahttp://www.ruby-forum.com/.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com
To unsubscribe from this group, send email to 
rubyonrails-talk+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to