if not exists (select * FROM sys.syscolumns where name = 'SecurityGroup' AND id = object_id(N'dbo.Todo')) 
  alter table dbo.todo ADD SecurityGroup uniqueidentifier null FOREIGN KEY REFERENCES dbo.GroupInfo(ID);