ALTER TABLE LogTmConsProc ADD ItemDet INT DEFAULT(0) NOT NULL,CostoEst MONEY DEFAULT(0) NOT NULL
,EdoOrden INT DEFAULT(0) NOT NULL,TipOrden VARCHAR(3),NumOrden INT DEFAULT(0) NOT NULL,CdCiaOrden CHAR(2)
,CantOrden DECIMAL(14,4) DEFAULT(0) NOT NULL
GO
ALTER TABLE LogTmConsInsu ADD CantSalidas DECIMAL(14,4) DEFAULT(0)
GO
CREATE TABLE LogTmConsTallas ( 
Id INT IDENTITY ( 1,1 ) NOT NULL,
TipoReg VARCHAR(3) NOT NULL,
IdUsuario VARCHAR(5) NOT NULL,
Item INT DEFAULT ((0)) NOT NULL,
ItemDet INT DEFAULT ((0)) NOT NULL,
NumTalla VARCHAR(30) NOT NULL,
CantPed DECIMAL(14,4) DEFAULT ((0)) NOT NULL,
Cantidad DECIMAL(14,4) DEFAULT ((0)) NOT NULL
 CONSTRAINT PK_LogTmConsTallas PRIMARY KEY CLUSTERED (Id),
 CONSTRAINT CK_LogTmConsTallasIdUsuario CHECK ((len([IdUsuario])>(0))),
 CONSTRAINT CK_LogTmConsTallasNumTalla CHECK ((len([NumTalla])>(0))),
 CONSTRAINT CK_LogTmConsTallasTipoReg CHECK ((len([TipoReg])>(0))))
GO
 CREATE NONCLUSTERED INDEX IX_LogTmConsTallasIdUsuario ON LogTmConsTallas(TipoReg,IdUsuario,Item)
