TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Ask HN: How do you enforce database standards?

3 点作者 aesthetics1超过 5 年前
How does your team ensure that your database standards are being followed? Naming standards, ensuring certain triggers are present, index&#x2F;constraint rules, etc. Do you use tools, code reviews, or some other method?<p>I&#x27;m finding that this seems to be a harder problem to solve than enforcing other types of coding standards.

2 条评论

davismwfl超过 5 年前
Our DB standards are controlled through code, scripts and code reviews. That works fine for smaller teams and is good for us today (we do use DataGrip by JetBrains to help manage&#x2F;validate our Postgres databases).<p>There are other tools like Red Gate <a href="https:&#x2F;&#x2F;www.red-gate.com&#x2F;" rel="nofollow">https:&#x2F;&#x2F;www.red-gate.com&#x2F;</a>, and others who sell tooling that works on different databases which allow you to automate a lot of standards and deployments etc. Even works for things like data migrations etc. I&#x27;ve used red gate and tools like it on other solutions, a lot of it depends on the architecture and structure of your project.<p>For example, tools like Red Gate work great when you have DBA&#x27;s and developers working together to manage databases (datasets) outside of the application code. It is a more traditional method of data solutions. But as seems to happen in tech, we are back to doing things more from the application and managing structure, migrations and standards through application code. There are valid reasons for both methodologies, so a lot just depends on what you are doing and how your team is structured and how big it is.
评论 #21347677 未加载
verdverm超过 5 年前
I&#x27;m using a sort of ORM, and part of that is making casing consistent. Naming conventions are harder to enforce because this often requires the semantic context to be understood.