# cardinality **Category:** [Implementers (archive)](https://discourse.openehr.org/c/implementers-archive/158) **Created:** 2007-05-19 11:26 UTC **Views:** 6 **Replies:** 4 **URL:** https://discourse.openehr.org/t/cardinality/14645 --- ## Post #1 by @system I had one more question, I said this morning: What is the use of the numerical part of the Cardinality object, I wonder? It can be calculated from the number and occurences of the items\. Or do I misunderstand? For example events cardinality matches \{\*;ordered\} matches \{     EVENT\[at001\] occurences matches \{0\.\.1\} matches \{\*\}     EVENT\[at002\] occurences matches \{0\.\.1\} matches \{\*\}     EVENT\[at003\] occurences matches \{0\.\.1\} matches \{\*\} \} Because the attribute "events" can have 0 to 3 elements \(the occurences property tells me\), the cardinality is \{0\.\.3;ordered\} It cannot be something else\. Or do I misunderstand? Thanks in advance for an answer regards, Bert --- ## Post #2 by @system The use for the numerical part of Cardniality, I can think of, is events cardinality matches \{0\.\.2;ordered\} matches \{     EVENT\[at001\] occurences matches \{0\.\.1\} matches \{\*\}     EVENT\[at002\] occurences matches \{0\.\.1\} matches \{\*\}     EVENT\[at003\] occurences matches \{0\.\.1\} matches \{\*\} \} In this way teling that only 2 ELEMENT total may be in this list of events Is that right Bert --- ## Post #3 by @Sam Bert That is right - it is the way of limiting the number of choices as you have said...Sam Bert Verhees wrote: --- ## Post #4 by @system Sam Heard schreef: > Bert > That is right \- it is the way of limiting the number of choices as you > have said\.\.\.Sam Thanks, Sam, for the confirmation\. --- ## Post #5 by @thomas.beale Bert Verhees wrote: > I had one more question, I said this morning: > > What is the use of the numerical part of the Cardinality object, I wonder? >   'cardinality' \(in ADL\) says how big the container can be \- imagine it is like a box containing LEGO pieces\. 'occurrences' says how many of a particular kind of object \- e\.g\. 8x2 LEGO bricks \- can be in the container\. 'Existence' says if there is a container or not\. For non\-container attributes, 'occurrences' always matches 'existence'\. \- thomas --- **Canonical:** https://discourse.openehr.org/t/cardinality/14645 **Original content:** https://discourse.openehr.org/t/cardinality/14645