什么是MSSQL数据库设计和版本控制的良好实践/工具?

时间:2022-05-16 12:58:16

We work with a small development team and a system engineer who deploys the software at certain times.

我们与一个小型开发团队和一个系统工程师一起工作,他们在特定的时间部署软件。

At the moment we don't have any leading document for database changes. Changes are done in the staging database and added manually to production when the system engineer deploys a new release.

目前我们还没有任何数据库更改的前导文档。当系统工程师部署一个新版本时,在staging数据库中进行更改,并手动添加到生产中。

We started to work with DBDesigner Fork to create the design and generate the SQL create script, but we are still not happy with this solution. The solution is incomplete, because it's impossible to create views and stored procedures in DBDesigner Fork for example.

我们开始使用DBDesigner Fork来创建设计并生成SQL create脚本,但是我们仍然不满意这个解决方案。解决方案是不完整的,因为不可能在DBDesigner Fork中创建视图和存储过程。

We would like to find a practice/tool to design the database, stored procedures, views, etc. and version the changes in Subversion.

我们希望找到一个实践/工具来设计数据库、存储过程、视图等,并对Subversion中的更改进行版本化。

When a new software release is created (tagged in SVN), we should be able to create a patch file for the database (a SQL script for example).

当创建一个新的软件版本(在SVN中标记)时,我们应该能够为数据库创建一个补丁文件(例如一个SQL脚本)。

What is the best way to handle the issues described above?

处理上述问题的最佳方式是什么?

2 个解决方案

#1


6  

We are a $2.5B solar manufacturing company that is using Visual Studio Database Edition for all our database management and versioning needs. It has been a very good tool for us. It version controls our databases with TFS integration, does schema and data compares (like Red-Gate), database validations and much more. We couldn't live without it now.

我们是一家价值2.5亿美元的太阳能制造公司,使用Visual Studio数据库版本满足我们所有的数据库管理和版本控制需求。这对我们来说是一个很好的工具。It版本通过TFS集成控制我们的数据库,进行模式和数据比较(如Red-Gate),数据库验证等等。我们现在没有它就活不下去。

#2


2  

We use source control for versioning. All databases changes must only be made in scripts and placed in source control as part of the branch of the code that goes to production with the rest of the code changes for that version. Since devs don't have any rights to create or alter objects in Prod, this works out well for us as your changes don't get moved up unless they are in a script.

我们使用源代码控制进行版本控制。所有数据库更改必须仅在脚本中进行,并作为代码分支的一部分放在源代码控制中,该分支将与该版本的其余代码更改一起投入生产。由于devs没有任何在Prod中创建或更改对象的权限,所以这对我们来说很好,因为您的更改不会被更改,除非它们在脚本中。

#1


6  

We are a $2.5B solar manufacturing company that is using Visual Studio Database Edition for all our database management and versioning needs. It has been a very good tool for us. It version controls our databases with TFS integration, does schema and data compares (like Red-Gate), database validations and much more. We couldn't live without it now.

我们是一家价值2.5亿美元的太阳能制造公司,使用Visual Studio数据库版本满足我们所有的数据库管理和版本控制需求。这对我们来说是一个很好的工具。It版本通过TFS集成控制我们的数据库,进行模式和数据比较(如Red-Gate),数据库验证等等。我们现在没有它就活不下去。

#2


2  

We use source control for versioning. All databases changes must only be made in scripts and placed in source control as part of the branch of the code that goes to production with the rest of the code changes for that version. Since devs don't have any rights to create or alter objects in Prod, this works out well for us as your changes don't get moved up unless they are in a script.

我们使用源代码控制进行版本控制。所有数据库更改必须仅在脚本中进行,并作为代码分支的一部分放在源代码控制中,该分支将与该版本的其余代码更改一起投入生产。由于devs没有任何在Prod中创建或更改对象的权限,所以这对我们来说很好,因为您的更改不会被更改,除非它们在脚本中。