if not exists (select * from sys.syscolumns where name = 'ImageName' and id = object_id(N'dbo.Repository'))
begin
    alter table dbo.Repository add ImageName nvarchar(256) null
        ,IsAllowedOffline bit not null constraint DF_Repository_IsAllowedOffline default (1)
        ,RepositorySettings nvarchar(max) null
end