Math4Team/RIT/Projects/Question Support API/Data Model: Difference between revisions
Move data model to its own page. |
highlight recursive entities |
||
| (3 intermediate revisions by the same user not shown) | |||
| Line 1: | Line 1: | ||
===Data Model=== | ===Data Model=== | ||
Here is a potential data model: (It was built for a corporate medical department's medical records. I've already renamed Clinic and Provider to School and Teacher.) | |||
[[Image:QuestionERDiagram.PNG|left]] | |||
[[Image:QuestionERDiagram.PNG|left]]<br clear="all"> | |||
====Table Dictionary==== | ====Table Dictionary==== | ||
{{Definition_table | {{Definition_table | ||
|Questionnaire |A collection of questions that might be used in a Survey, Quiz, Exam, etc. | |Questionnaire |A collection of questions that might be used in a Survey, Quiz, Exam, etc., or when its key appears in the Category field, a group, class, or category of Questionnaires (a recursive entity) | ||
|Question | A problem seeking an answer | |Question | A problem seeking an answer | ||
|Answer | A potential solution to the problem | |Answer | A potential solution to the problem | ||
|AnswerType | The class of answer suitable for the problem or question | |AnswerType | The class of answer suitable for the problem or question | ||
|Survey | An event instance | |Survey | An event in time instance, at which Answers to Questions or problems are gathered. Survey events can reference other surveys, such as follow-up Surveys (a recursive entity). | ||
|Response | An event instance | |Response | An event in time instance, at which the Student provides an answer to a question on a Survey or Quiz, etc. | ||
|School | An organization | |School | An organization | ||
|Person | An individual, such as a Teacher, Student, etc. | |Person | An individual, such as a Teacher, Student, etc. | ||
}} | }} | ||
====Questionnaire==== | ====Questionnaire==== | ||
: '''''A collection of questions that might be used in a Survey, Quiz, Exam, etc.''''', | |||
:: or when its key appears in the Category field making a recursive entity, | |||
: '''''a group, class, or category of Questionnaires''''' | |||
{{Definition_table | {{Definition_table | ||
|ID | primary key | |ID | primary key | ||
|Title | Short name for questionnaire | |Title | Short name for questionnaire | ||
|Category | | |Category | Category ID, the ID of a Questionnaire group, class, or category of Questionnaire (the parent of a recursive relationship with other Questionnaire records) | ||
|Notes | Description, Image link, rich format data | |Notes | Description, Image link, rich format data | ||
|StartDate | Effective date for this instance of the Questionnaire | |StartDate | Effective date for this instance of the Questionnaire | ||
| Line 26: | Line 28: | ||
====Question==== | ====Question==== | ||
: '''''A problem seeking an answer''''' | |||
{{Definition_table | {{Definition_table | ||
|ID | primary key | |ID | primary key | ||
| Line 38: | Line 41: | ||
}} | }} | ||
====Answer==== | ====Answer==== | ||
: '''''A potential solution to the problem''''' | |||
{{Definition_table | {{Definition_table | ||
|ID | primary key | |ID | primary key | ||
| Line 48: | Line 52: | ||
}} | }} | ||
====AnswerType==== | ====AnswerType==== | ||
: '''''The class of answer suitable for the problem or question''''' | |||
{{Definition_table | {{Definition_table | ||
|ID | primary key | |ID | primary key | ||
| Line 54: | Line 59: | ||
}} | }} | ||
====Survey==== | ====Survey==== | ||
: '''''An event in time instance, at which Answers to Questions or problems are gathered. Survey events can reference other surveys, such as follow-up Surveys''''' (a recursive entity). | |||
{{Definition_table | {{Definition_table | ||
|ID | primary key | |ID | primary key | ||
| Line 66: | Line 72: | ||
}} | }} | ||
====Response==== | ====Response==== | ||
: '''''An event in time instance, at which the Student provides an answer to a question on a Survey or Quiz, etc.''''' | |||
{{Definition_table | {{Definition_table | ||
|ID | primary key | |ID | primary key | ||
| Line 80: | Line 87: | ||
====School==== | ====School==== | ||
: '''''An organization''''' | |||
{{Definition_table | {{Definition_table | ||
|ID | primary key | |ID | primary key | ||
| Line 85: | Line 93: | ||
}} | }} | ||
====Person==== | ====Person==== | ||
: '''''An individual, such as a Teacher, Student, etc.''''' | |||
{{Definition_table | {{Definition_table | ||
|ID | primary key | |ID | primary key | ||
| Line 90: | Line 99: | ||
|First Name | Primary name for Person | |First Name | Primary name for Person | ||
}} | }} | ||
== Comments == | |||
Authorship and history attributes for Questions could be provided through a new Person ID field in Questionnaire and recursive links. | |||
:: For reference, here is the Moodle [http://docs.moodle.org/en/Development:Question_database_structure Question database structure]. | |||