IF NOT EXISTS (SELECT * FROM SYSCOLUMNS INNER JOIN SYSOBJECTS ON SYSOBJECTS.id = SYSCOLUMNS.id 
              WHERE SYSCOLUMNS.NAME = 'IADEEDILENFATURATARIHI' AND SYSOBJECTS.name = 'FATURA')
alter table FATURA
        add IADEEDILENFATURATARIHI DATETIME null
GO

IF NOT EXISTS (SELECT * FROM SYSCOLUMNS INNER JOIN SYSOBJECTS ON SYSOBJECTS.id = SYSCOLUMNS.id 
              WHERE SYSCOLUMNS.NAME = 'IADEEDILENFATURANO' AND SYSOBJECTS.name = 'FATURA')
alter table FATURA
        add IADEEDILENFATURANO nVarChar(16) null
GO
