I'm having problems with SSDT detecting a change to a "TIMESTAMP" column where both the target column and model.xml column definition are of type "TIMESTAMP". When this happens, the following alter statement is generated which fails trying to alter a TIMESTAMP column:
ALTER TABLE [dbo].[MyTable] ALTER COLUMN [MyColumn] TIMESTAMP NOT NULL;
My guess is that target column was created as ROWVERSION rather than TIMESTAMP and this is tripping up SSDT as when I update the model.xml column def to "ROWVERSION" a difference is NOT detected and the ALTER statement is not generated.
I know that these two statements are functionally equivalent:
alter table [MyTable] add [NewColumn] TIMESTAMP not null alter table [MyTable] add [NewColumn] ROWVERSION not null
and that ROWVERSION is a alias for TIMESTAMP..
However, when enquiring on the column type, both alter statements result in the DATA_TYPE being reported as [timestamp]:
SELECT * FROM INFORMATION_SCHEMA.COLUMNS WHERE Table_Name = 'MyTable'
Is there an underlying "hidden" difference between columns created as ROWVERSION vs TIMESTAMP? - one that is being picked up by the Diff engine in SSDT?
Thanks in advance for any help!