Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How can I update my SQL Server database schema?

Usually throughout development of a project I will deploy frequently, just to make sure I wont have any problems in production.

Also, throughout development, I find myself changing the database's schema.

How can I easily update the database in production?

I have been dropping the old database and reattaching the new one. Is there a faster way to update the deployment database?

Thanks

EDIT

What are some free tools for this?

like image 265
Ronnie Overby Avatar asked Jul 23 '09 12:07

Ronnie Overby


People also ask

How do I refresh a schema in SQL Server?

To refresh a DSV, double-click the DSV from Solution Explorer in SQL Server Data Tools. This launches the DSV designer. Then click the Refresh Data Source View button in the designer or choose Refresh from the Data Source View menu.

What does it mean to update a schema?

What Does Schema Change Mean? A schema change is an alteration made to a collection of logical structures (or schema objects) in a database.


1 Answers

Try DBSourceTools.
http://dbsourcetools.codeplex.com
Its open source, and will script an entire database
- tables, views, procs and data to disk, and then allow you to re-create that database through a deployment target.
It's specifically designed to help developers get their databases under source code control.

like image 118
blorkfish Avatar answered Sep 27 '22 19:09

blorkfish