if exists (select * from sys.default_constraints where name = 'DF_Repository_RepositoryType' and parent_object_id = object_id(N'dbo.Repository'))
    alter table dbo.Repository drop constraint DF_Repository_RepositoryType;