简体   繁体   English

如何为“时间记录”服务创建关系数据库?

[英]How can I create a relational database for a “time-logging” service?

I currently have a database of customers. 我目前有一个客户数据库。 I would like to be able to query the database and see the list of dates the customer has made an appointment. 我希望能够查询数据库并查看客户预约的日期列表。 For example, if I select John Doe, I want to be able to see that he had an appointment on June 6th, July 2nd, and July 24th, etc. and the total cost of the appointment. 例如,如果我选择John Doe,那么我希望能够看到他在6月6日,7月2日和7月24日等进行了约会,以及约会的总费用。 I feel like I can probably do this using a relational database, but I can't figure out a really good structure. 我觉得我可以使用关系数据库来做到这一点,但是我找不到一个真正好的结构。 Would a table of dates be a parent to the child customer table? 日期表将成为子客户表的父表吗?

Thank you! 谢谢!

感谢Mihai,我将创建一个约会表,将日期时间值与客户联系起来!

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM