Joined: 29 Aug 2013
|Posted: Thu Aug 29, 2013 7:05 pm Post subject: Extended properties to track version control revision number
|We have automated builds that get triggered from Jenkins on every database change check-in.
Jenkins calls SQL Compare command line which generates the deployment change script and then deploys all the changes to a SQL build instance. In the automated builds, we do not see the extended properties for version control revision number being set.
When we use SQL Compare UI and generate the script manually, it generates the script to add/update version control revision number which looks something like:
DECLARE @RG_SC_VERSION BIGINT
SET @RG_SC_VERSION = 1670
IF EXISTS (SELECT 1 FROM fn_listextendedproperty(N'SQLSourceControl Database Revision', NULL, NULL, NULL, NULL, NULL, NULL))
EXEC sp_dropextendedproperty N'SQLSourceControl Database Revision', NULL, NULL, NULL, NULL, NULL, NULL
EXEC sp_addextendedproperty N'SQLSourceControl Database Revision', @RG_SC_VERSION, NULL, NULL, NULL, NULL, NULL, NULL
Is there a command line parameter that needs to be passed in to SQL Compare command line to generate the code to update version control revision number extended property? I looked at the documentation for SQL Compare command line and did not find anything there. Am I missing something?
Any help would be appreciated. Thanks!