On Saturday, 12 June 2021 at 04:48:27 UTC+10, Nicola wrote:Yes.
On 2021-06-11, Derek Ignatius Asirvadem wrote:Not directly relevant to the topic of this thread, and possibly not
That Bridge problem is from my days of hard labour at TTM gulag.
relevant to the formulation of that problem, but... your
Solver_Not_Composer constraint only ensures that the solver is not the
main composer. But nothing in that model prevents a solver to be the
same as the second composer (i.e., SolverID may be Composer_Id_2).
I would have designed the model differently:Ok.
Person[PersonId | LastName FirstName ...]
Problem[ComposerId.PersonId ProblemNo | Name Score ...] ProblemStakeholder[ComposerId ProblemNo StakeholderId.PersonId Role] JointComposer[ComposerId ProblemNo JointComposer.StakeholderId] Solver[ComposerId ProblemNo Solver.StakeholderId]
where ProblemStakeholder is an exclusive generalization of JointComposerVery thoughtful.
and Solver. Then, a simple check constraint on ProblemStakeholder (ComposerId rea StakeholderId) plus the exclusive subtyping would prevent composers to be solvers of their own problems.
An upper-bound on theIt is already there:
maximum number of composers or solvers for a problem could be added as
in your model.
Relationships:Fine.
1. Each Person invents 0-N Problems
2. Each Problem has 0-N ProblemStakeholders
3. Each ProblemStakeholder is one of JointComposer or Solver
What in heavens name is rCLexclusive generalizationrCY, do you have a definition or link ?
An upper-bound on the
maximum number of composers or solvers for a problem could be added as
in your model.
It is already there:
- the cardinality in Composer_2 means max 1 JointComposer
- the Constraint /Solver_Max_4/ means exactly that.
The DDL link gives all DDL including the Functions called by the Constraints.
Relationships:
1. Each Person invents 0-N Problems
2. Each Problem has 0-N ProblemStakeholders
3. Each ProblemStakeholder is one of JointComposer or Solver
Fine.
You need:
__ ProblemStakeholder needs a reference for the StakeholderId FK
__ 4. Each Person claims 0-N ProblemStakeholders
Erect the model and have a good look. Although it is fine, and it
works, it is just not straight-forward (a desirable element in logic).
Rather than fixing-up the Bridge model, which had a specific
argumentation purpose, I would erect a logically straight-forward
model. Ends up with fewer Facts.
____ https://www.softwaregems.com.au/Documents/Article/Normalisation/Bridge%202.pdf
| Sysop: | Amessyroom |
|---|---|
| Location: | Fayetteville, NC |
| Users: | 65 |
| Nodes: | 6 (0 / 6) |
| Uptime: | 03:52:19 |
| Calls: | 862 |
| Files: | 1,311 |
| D/L today: |
700 files (7,187M bytes) |
| Messages: | 264,528 |