Bonjour Miflon,
Envoyé par
Miflon
Un flag, c'est un booléen, placé dans la table "adherent"?
==> oui.
Envoyé par
Miflon
A ce moment là, flag = NULL -> ancien membre
flag = false -> adhérent non licencié
flag = true -> adhérent licencié.
==> non, surtout pas.
D'après tes règles de gestion, j'avais compris que, soit un adhérent possède une licence fédération, soit il possède une licence club, mais pas les deux. Si c'est bien le cas, ce MCD (simple, non satisfaisant) pourrait convenir :
donnant :
Adherent(IdAdherent, NomAdherent, LicenceInterne_O/N, ...)
Federation(IdFederation, LibelleFederation, ...)
Adherent_Federation(#IdAdherent, #IdFederation, NumLicence, DateLicence, ...)
avec :
- anciens membres ==> pas d'enregistrement dans Adherent_Federation ;
- adhérents non licenciés (cotisation club seule) ==> enregistrement dans Adherent avec LicenceInterne_O/N=Vrai ;
- adhérents licenciés à une ou plusieurs fédérations ==> enregistrement(s) existant(s) dans Adherent_Federation.
Autre suggestion (mieux, sans le flag) :
donnant :
Adherent(IdAdherent, NomAdherent, ...)
Federation(IdFederation, LibelleFederation, ...)
Adherent_Federation(#IdAdherent, #IdFederation, NumLicence, DateLicence, ...)
LicenceClub(IdLicenceClub, ...)
Adherent_LicenceClub(#IdAdherent, #IdLicenceClub, ...)
Avec la contrainte décrite précédemment symbolisée par "X".
Partager