Skip to content

Instantly share code, notes, and snippets.

@tdmitch
Created June 1, 2018 01:10
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tdmitch/156fe3be7d6c40a04e8a3834d2c2b83d to your computer and use it in GitHub Desktop.
Save tdmitch/156fe3be7d6c40a04e8a3834d2c2b83d to your computer and use it in GitHub Desktop.
DECLARE @StartVersionID BIGINT
, @EndVersionID BIGINT
-- Set the starting version ID
SET @StartVersionID = (SELECT Change_Tracking_Version
FROM etl.Change_Tracking_Version
WHERE Table_Name = 'Emp')
-- Set the ending version ID
SET @EndVersionID = CHANGE_TRACKING_CURRENT_VERSION()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment