Hi, I have a database question.
I''m trying to plan a simple app for tracking pupil progress at a
school. These are the models and associations I had in mind:
Teachers :have_many Classes
Classes :have_many Pupils
Classes :belong_to Subjects
Subjects: have_many Topics
I thought that it would be a good idea to have a super class of Person
that Teachers and Pupils could inherit from. How does this work with
the database tables? Do I have a people table or separate teachers and
pupils tables? Teachers will have some attributes that Pupils won''t
(payroll number for example). Would these be included in the super
class people table and just set as nil for pupils or is there a better
way of doing this?
Also, I know that I can''t use Class for a model name - should I use
Klass, Clas or change the name to something like Group?
cheers,
DAZ
--~--~---------~--~----~------------~-------~--~----~
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-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
To unsubscribe from this group, send email to
rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---