CREATE TABLE Trn_SobGasOxigen ( 
IdDec VARCHAR(4) NOT NULL,
NumDeclara INT DEFAULT ((0)) NOT NULL,
Item INT DEFAULT ((0)) NOT NULL,
ItemDet INT DEFAULT ((0)) NOT NULL,
ClaseProd VARCHAR(20) NOT NULL,
IdProducto VARCHAR(16) NOT NULL,
Cantidad DECIMAL(14,4) DEFAULT ((0)) NOT NULL,
Tarifa DECIMAL(14,4) DEFAULT ((0)) NOT NULL,
PorcBase DECIMAL(14,4) DEFAULT ((0)) NOT NULL,
PorcAch DECIMAL(14,4) DEFAULT ((0)) NOT NULL,
BaseGrav DECIMAL(14,4) DEFAULT ((0)) NOT NULL,
VrSobretasa MONEY DEFAULT ((0)) NOT NULL,
PrecioRef MONEY DEFAULT ((0)) NOT NULL
 CONSTRAINT PK_Trn_SobGasOxigen PRIMARY KEY CLUSTERED (IdDec,NumDeclara,Item),
 CONSTRAINT CK_Trn_SobGasOxigenClaseProd CHECK ((len([ClaseProd])>(0))),
 CONSTRAINT CK_Trn_SobGasOxigenIdDec CHECK ((len([IdDec])>(0))),
 CONSTRAINT CK_Trn_SobGasOxigenIdProducto CHECK ((len([IdProducto])>(0))))
GO
