Two tables, one model

Posted 3 years ago by desarrolloE1

Hi.

I was wondering if is possible that one model can manipulate the data of two or more tables with the same columns/attributes. For example, I have these models: Survey, Exam and Question. Survey and Exam can have a given number of Questions, but I don't want a single big table that stores the questions of both models, I want two separate tables: survey_questions and exam_questions, but with the same structure. Is possible that the model Question handle both tables?

Please sign in or create an account to participate in this conversation.

Reply to

Use Markdown with GitHub-flavored code blocks.