实体关系图
我正在尝试为我的应用程序创建一个实体关系模型。
该应用程序在测验中包含问题和答案。
到目前为止,我生成的模型如下所示:
我对这些图表很陌生,所以会如果有人能解释如何用箭头和多重性来完成它,我将不胜感激。
Quiz 表在 QUIZ_TEXT 中保存问题,在 CORRECT_ANSWER 中保存正确答案。
Answer 表在 ANSWERS 中保存答案,并将这些答案与问题 QUIZ_ID 进行匹配。
我知道这可能很简单,但我已经很长时间没有使用数据库了,我的大脑一片空白。另外,我需要做的就是这样我就可以继续前进,并且我的大部分工作不是在数据库上。请帮忙。谢谢
编辑:
我已经尝试这样做,请告诉我这是否正确。谢谢:
I am trying to create an entity relationship model for my application.
The application has questions and answers within a quiz.
The model which I have produced so far looks like this:
I am quite new to these diagrams, so would appreciate if someone could explain how to complete it with an arrow and multiplicity.
The Quiz table holds questions in QUIZ_TEXT and the correct answer in CORRECT_ANSWER
The Answer table holds the answers in ANSWERS and matches these answers with the QUIZ_ID which is the question.
I understand this is probably simple but I haven't worked with databases for a long time and my mind is going blank. Also all I need to do is this then I can move on and the majority of my work is not on databases. Please help. Thanks
Edit:
I have tried to do this, please let me know if this is correct. Thanks:
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
测验和答案之间的关系是一对多,因此您应该在测验和答案之间画一条线,并在答案末端画一条鱼尾纹。还有其他表示法,但这是最常见的方式之一。
The relationship between Quiz and Answer is one-to-many so you should draw line from Quiz to Answer and put a crow's foot in the Answer end. There are other notations but this is one of the most common ways.