最佳邀请数据模型?

发布于 2024-12-27 09:57:53 字数 293 浏览 0 评论 0原文

我正在尝试确定为网站实施邀请流程的最佳数据模型,这将减少开销,但也有意义。

我的模型将有一个 InvitationResponses 查找表,用于存储 ResponseID 和“接受”、“可能是”、“拒绝”等描述。另外,我希望能够包含对“可能是”或“拒绝”响应的用户解释。

因此,我试图决定是否应该保留 ResponseID 作为邀请表的一部分,或者有一个单独的表,如下所示:

InvitationsResponses
身份证号
邀请ID
响应ID
评论

I am trying to decide on the best data model to implement Invitation process for a website, that will reduce overhead but also would make sense.

My model will have an InvitationResponses look-up table that will store ResponseID and descriptions like "Accept", "May Be", "Reject". Also, I want to have ability to include user explanation for "May Be" or "Reject" responses.

Therefore, I am trying to decide if I should keep a ResponseID as part of the Invitations table, or have a separate table that will be something like this:

InvitationsResponses
ID
InvitationID
ResponseID
Comment

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

别理我 2025-01-03 09:57:53

我会将其全部保存在一张表中,为每个事件设置一个状态标记,具体取决于它是否被接受、拒绝等...使用一张表比使用两张表获得更好的性能,特别是对于像您所要做的这样简单的事情问。

I would keep it all in one table, have a status marker for each event depending on whether it's accepted, rejected, etc... You'll gain better performance with one table than two, especially for something as simple as what you're asking.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文