IF NOT EXISTS (SELECT * FROM SYSCOLUMNS INNER JOIN SYSOBJECTS ON SYSOBJECTS.id = SYSCOLUMNS.id 
              WHERE SYSCOLUMNS.NAME = 'AKTIF' AND SYSOBJECTS.name = 'TTURFIRMA')
ALTER TABLE dbo.[TTURFIRMA] ADD AKTIF bit NOT NULL CONSTRAINT [DF_TTURFIRMA_AKTIF] DEFAULT (1)

GO

IF NOT EXISTS (SELECT * FROM SYSCOLUMNS INNER JOIN SYSOBJECTS ON SYSOBJECTS.id = SYSCOLUMNS.id 
              WHERE SYSCOLUMNS.NAME = 'AKTIF' AND SYSOBJECTS.name = 'TYRLACENTA')
ALTER TABLE dbo.[TYRLACENTA] ADD AKTIF bit NOT NULL CONSTRAINT [DF_TYRLACENTA_TYRLACENTA] DEFAULT (1)

GO

IF NOT EXISTS (SELECT * FROM SYSCOLUMNS INNER JOIN SYSOBJECTS ON SYSOBJECTS.id = SYSCOLUMNS.id 
              WHERE SYSCOLUMNS.NAME = 'AKTIF' AND SYSOBJECTS.name = 'TYONLENDIREN')
ALTER TABLE dbo.[TYONLENDIREN] ADD AKTIF bit NOT NULL CONSTRAINT [DF_TYONLENDIREN_AKTIF] DEFAULT (1)

GO

IF NOT EXISTS (SELECT * FROM SYSCOLUMNS INNER JOIN SYSOBJECTS ON SYSOBJECTS.id = SYSCOLUMNS.id 
              WHERE SYSCOLUMNS.NAME = 'AKTIF' AND SYSOBJECTS.name = 'TASILSIGORTA')
ALTER TABLE dbo.[TASILSIGORTA] ADD AKTIF bit NOT NULL CONSTRAINT [DF_TASILSIGORTA_AKTIF] DEFAULT (1)

GO

IF NOT EXISTS (SELECT * FROM SYSCOLUMNS INNER JOIN SYSOBJECTS ON SYSOBJECTS.id = SYSCOLUMNS.id 
              WHERE SYSCOLUMNS.NAME = 'AKTIF' AND SYSOBJECTS.name = 'TYRDSIGFRM')
ALTER TABLE dbo.[TYRDSIGFRM] ADD AKTIF bit NOT NULL CONSTRAINT [DF_TYRDSIGFRM_AKTIF] DEFAULT (1)

GO

IF NOT EXISTS (SELECT * FROM SYSCOLUMNS INNER JOIN SYSOBJECTS ON SYSOBJECTS.id = SYSCOLUMNS.id 
              WHERE SYSCOLUMNS.NAME = 'AKTIF' AND SYSOBJECTS.name = 'TGARANTI')
ALTER TABLE dbo.[TGARANTI] ADD AKTIF bit NOT NULL CONSTRAINT [DF_TGARANTI_AKTIF] DEFAULT (1)

GO
