How to do version control for SQL Server database

0 votes
I'd want to keep track of the versions of my databases.

I'll always want to have some information in there. For performance measurements, I'll frequently want a significant quantity of created test data.

How would I go about implementing version control in my database?
Feb 15, 2022 in Database by Vaani
• 7,070 points
657 views

1 answer to this question.

0 votes
Not only can you compare objects at the object level and produce change scripts using Red Gate's SQL Compare, but you can also export your database objects into a folder hierarchy structured by object type, with one [objectname].sql creation script per object in these folders. The hierarchy of object types looks like this:

\Functions
\Security
\Security\Roles
\Security\Schemas
\Security\Users
\Stored Procedures
\Tables

You can use this to update your SVN repo and retain a running history of each item individually if you dump your scripts to the same root directory whenever you make changes.
answered Feb 15, 2022 by Neha
• 9,020 points

Related Questions In Database

0 votes
0 answers

How to fix Recovery Pending State in SQL Server Database?

How to fix Recovery Pending State in ...READ MORE

Aug 27, 2022 in Database by Kithuzzz
• 38,000 points
607 views
0 votes
0 answers

How do I query for all dates greater than a certain date in SQL Server?

I tried this: SELECT * FROM dbo.March2010 A WHERE ...READ MORE

Aug 29, 2022 in Database by Kithuzzz
• 38,000 points
805 views
+15 votes
2 answers

Git management technique when there are multiple customers and need multiple customization?

Consider this - In 'extended' Git-Flow, (Git-Multi-Flow, ...READ MORE

answered Mar 27, 2018 in DevOps & Agile by DragonLord999
• 8,450 points
4,062 views
+2 votes
1 answer
0 votes
1 answer

How to drop all tables from a database with one SQL query?

Use the INFORMATION_SCHEMA.TABLES view to get the ...READ MORE

answered Feb 4, 2022 in Database by Neha
• 9,020 points
9,009 views
0 votes
1 answer

How to rename a column in a database table using SQL?

For SQL Server, use sp_rename USE AdventureWorks; GO EXEC sp_rename 'Customers.CustomerTerritory.TerritoryID', ...READ MORE

answered Feb 9, 2022 in Database by Neha
• 9,020 points
773 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP