﻿CREATE TABLE [dbo].[ActionsEdu] (
    [Id]                    INT            IDENTITY (1, 1) NOT NULL,
    [Numero]                NVARCHAR (MAX) NOT NULL,
    [Nom]                   NVARCHAR (MAX) NOT NULL,
    [Description]           NVARCHAR (MAX) NOT NULL,
    [Neutralise]            BIT            NOT NULL,
    [Ordre]                 INT            NOT NULL,
    [ActionEduThematiqueId] INT            NOT NULL,
    [AnneeId]               INT            NOT NULL,
    CONSTRAINT [PK_ActionsEdu] PRIMARY KEY CLUSTERED ([Id] ASC),
    CONSTRAINT [FK_ActionEduAnnee] FOREIGN KEY ([AnneeId]) REFERENCES [dbo].[Annees] ([Id]),
    CONSTRAINT [FK_ActionEduThematiqueActionEdu] FOREIGN KEY ([ActionEduThematiqueId]) REFERENCES [dbo].[ActionEduThematiques] ([Id])
);


GO
CREATE NONCLUSTERED INDEX [IX_FK_ActionEduThematiqueActionEdu]
    ON [dbo].[ActionsEdu]([ActionEduThematiqueId] ASC);


GO
CREATE NONCLUSTERED INDEX [IX_FK_ActionEduAnnee]
    ON [dbo].[ActionsEdu]([AnneeId] ASC);

