[MS][SQL] Add Your Database Under Version Control 把資料庫加入版本控制


Environment:SQL Server 2008/2012 Express / VS2010 SP1 / SSDT for VS2010 / TFS2012

SSDT for Visual Studio 2013 : https://msdn.microsoft.com/en-us/dn864412
SSDT for Visual Studio 2012 : https://msdn.microsoft.com/en-us/jj650015
SSDT for Visual Studio 2010 : https://msdn.microsoft.com/en-us/jj650014


Step 1. Open SQL server Browser in VS2010 and connect your database
















Step 2. Left click target Database and select "Create New Project".







Step 3. You can UNCHECK "Add into Source Control", "Import Autorization" or Not.


















Step 4. Add to TFS 





















Finished


















Check the Source Control panel













Step 5. Add a Table for test












Step 6. Add a Column and Save Files











Step 7. Left Click Project and select "Public..." option in order to update changes to real database.











Step 8. Select your database














Step 9. Click "Public" to update database.











Setp 10. Check Result. 
















Double check by SSMS:


留言