CREATE TABLE [wh].[PL_S80Alternativa] (
	[ProcedureName] nvarchar(33) NOT NULL,
	[i_rete] nvarchar(1) NOT NULL,
	[i_codiceFiscale] nvarchar(16) NOT NULL,
	[RETE] nvarchar(1) NOT NULL,
	[Cod_Fiscale] nvarchar(16) NOT NULL,
	[Fase] int NOT NULL,
	[DataFase] datetime NOT NULL,
	[Partita_viaggiante] decimal(15,2) NOT NULL,
	[CTV_EXT] decimal(15,3) NOT NULL,
	[CTV_INV] decimal(15,3) NOT NULL,
	[CTV_PRE] decimal(15,3) NOT NULL,
	[CTV_RIS] decimal(15,3) NOT NULL,
	[CTV_LIQ] decimal(15,3) NOT NULL,
	[RisorseAllocate] decimal(19,3) NULL,
	[RisorseNonAllocate] decimal(15,3) NOT NULL,
	[RisorseFinanziarie] decimal(20,3) NULL,
	[Contocorrente] decimal(15,3) NOT NULL,
	[ctvself] decimal(18,3) NOT NULL,
	[TotalePatrimonio] decimal(23,3) NULL,
	[DettMov] nvarchar(50) NULL,
	[NumeroAsterischiNota] int NOT NULL
)
ALTER TABLE [wh].[PL_S80Alternativa] ADD CONSTRAINT [PK__PL_S80Alternativ__0CC76C1D] PRIMARY KEY CLUSTERED ([i_rete],[i_codiceFiscale],[Fase])
GO