关于使用JSONB与Postgres中的归一化列的指南

发布于 2025-02-10 12:09:37 字数 157 浏览 2 评论 0原文

如果在JSON中仅使用40%的时间(或具有值),我是否仍然为Postgres中的该键创建列?在线文献指出,当键的值始终存在时,要使用归一化的列,但是我找不到有关在大多数时间或阈值填充键时该怎么做的指导。我试图找出何时更喜欢JSONB而不是列,而不是释义,键的阈值是什么是有资格拥有自己的列的值的阈值。

If a key is used (or has a value) only 40% of the time in a JSON, do I still create a column for that key in Postgres? The online literature states to use a normalized column when the value for a key is always there, but I couldn't find any guidance on what to do when a key is filled most of the time or a threshold. I am trying to find out when to prefer JSONB over column, To paraphrase, what is the threshold for how often a key should have a value to qualify having its own column.

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

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

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文