
/*------ ATD 345255 ------*/
-- Cria o campo "VlrFreteItem" na tabela CadItemAtF
-- SQL Server
IF NOT EXISTS (SELECT 1 FROM SYSCOLUMNS WHERE name = 'VlrFreteItem' and
			syscolumns.id IN (SELECT ID FROM SYSOBJECTS WHERE xtype='U' AND name='CadItemAtF'))
	ALTER TABLE CadItemAtF ADD VlrFreteItem NUMERIC(10,2)
	GO
	UPDATE CadItemAtF SET VlrFreteItem = 0
	GO
	ALTER TABLE CadItemAtF ALTER COLUMN VlrFreteItem NUMERIC(10,2) NOT NULL
	GO
	EXEC SP_BINDEFAULT 'UW_ZERODEFAULT','CadItemAtF.VlrFreteItem'
GO