IF EXISTS (SELECT SYSCOLUMNS.* FROM TALYASETUP.dbo.SYSCOLUMNS INNER JOIN TALYASETUP.dbo.SYSOBJECTS ON SYSOBJECTS.id = SYSCOLUMNS.id 
              WHERE SYSCOLUMNS.NAME = 'REPORTID' AND SYSOBJECTS.name = 'RT_REPORTS' AND SYSCOLUMNS.type=38)
ALTER TABLE TALYASETUP.dbo.RT_REPORTS DROP COLUMN
	REPORTID 
GO

IF NOT EXISTS (SELECT SYSCOLUMNS.* FROM TALYASETUP.dbo.SYSCOLUMNS INNER JOIN TALYASETUP.dbo.SYSOBJECTS ON SYSOBJECTS.id = SYSCOLUMNS.id 
              WHERE SYSCOLUMNS.NAME = 'REPORTID' AND SYSOBJECTS.name = 'RT_REPORTS')
ALTER TABLE TALYASETUP.dbo.RT_REPORTS ADD
	REPORTID int NOT NULL IDENTITY (1, 1)
GO