﻿CREATE TABLE [dbo].[DiesGroupDet] (
    [CodDiesGroup] NVARCHAR (50)  NOT NULL,
    [Price]        DECIMAL (9, 3) NOT NULL,
    [QtyTot]       INT            NOT NULL,
    [QtyEOL]       INT            NOT NULL,
    [ExpLife]      DECIMAL (9, 2) CONSTRAINT [DF_DiesGroupDet_ExpLife] DEFAULT ((1)) NOT NULL,
    [EOLLife]      DECIMAL (9, 2) CONSTRAINT [DF_DiesGroupDet_EOLLife] DEFAULT ((1)) NOT NULL,
    [DateMod]      DATE           NULL,
    [UserMod]      NVARCHAR (50)  NULL,
    CONSTRAINT [PK_DiesGroupDet] PRIMARY KEY CLUSTERED ([CodDiesGroup] ASC)
);


GO
EXECUTE sp_addextendedproperty @name = N'MS_Description', @value = N'codice CLASSE matrice, es tipo + diametro', @level0type = N'SCHEMA', @level0name = N'dbo', @level1type = N'TABLE', @level1name = N'DiesGroupDet', @level2type = N'COLUMN', @level2name = N'CodDiesGroup';


GO
EXECUTE sp_addextendedproperty @name = N'MS_Description', @value = N'prezzo di acquisto', @level0type = N'SCHEMA', @level0name = N'dbo', @level1type = N'TABLE', @level1name = N'DiesGroupDet', @level2type = N'COLUMN', @level2name = N'Price';


GO
EXECUTE sp_addextendedproperty @name = N'MS_Description', @value = N'Totale matrici del gruppo', @level0type = N'SCHEMA', @level0name = N'dbo', @level1type = N'TABLE', @level1name = N'DiesGroupDet', @level2type = N'COLUMN', @level2name = N'QtyTot';


GO
EXECUTE sp_addextendedproperty @name = N'MS_Description', @value = N'numero rottamate nel gruppo (End Of Life)', @level0type = N'SCHEMA', @level0name = N'dbo', @level1type = N'TABLE', @level1name = N'DiesGroupDet', @level2type = N'COLUMN', @level2name = N'QtyEOL';


GO
EXECUTE sp_addextendedproperty @name = N'MS_Description', @value = N'Durata attesa in kg PREVISTA', @level0type = N'SCHEMA', @level0name = N'dbo', @level1type = N'TABLE', @level1name = N'DiesGroupDet', @level2type = N'COLUMN', @level2name = N'ExpLife';


GO
EXECUTE sp_addextendedproperty @name = N'MS_Description', @value = N'Durata attuale (delle rottamate, media) in kg', @level0type = N'SCHEMA', @level0name = N'dbo', @level1type = N'TABLE', @level1name = N'DiesGroupDet', @level2type = N'COLUMN', @level2name = N'EOLLife';

