I need to add one field to a table in my SQL Server Database and creates a sql migration for that:
IF NOT EXISTS (SELECT 1 FROM SYS.COLUMNS WHERE
OBJECT_ID = OBJECT_ID(N’[dbo].[MyTable]') AND name = ‘My_Field’)
BEGIN
ALTER TABLE [dbo].[MyTable]
ADD My_Field varchar(14) COLLATE Latin1_General_CI_AS;
END;
I am getting an exception related with collation
Caused by: liquibase.exception.DatabaseException: Incorrect syntax near ‘Latin1_General_CI_AS’
Is there a special syntax for specify collation ?
TIA
Yamil