ONLINE HELP WINDEV, WEBDEV AND WINDEV MOBILEVersion: 151617181920212223242526
 Home | Sign in | English
 OverviewSimple cardinalitiesExample of cardinalitiesAdvanced cardinalitiesExample of advanced cardinalities WINDEV WEBDEV WINDEV Mobile Others Overview The cardinalities are used to count the links between the files. Two types of cardinalities are available:Simple cardinalities The cardinality is defined according to the answers to the two following questions:For each record found in the data file, what is the minimum number of records in the other file to which this record is linked?The answer provides the first part of cardinality (minimum cardinality):if the answer is "none", the cardinality is 0,X.if the answer is "a single one", the cardinality is 1,X.For each record found in the data file, what is the maximum number of records in the other file to which this record is linked?The answer provides the second part of the cardinality (maximum cardinality):if the answer is "a single one", the cardinality is X,1.if the answer is "several", the cardinality is X, N.The answer to these two questions defines the cardinality that can be: 0,1 ; 0,N ; 1,1 ; 1,NThe description of cardinalities is fundamental: it is the basis for respecting the referential integrity of the database.To put it simply, these two questions can be broken down into four questions. For example, to describe a link between the "Club" file and the "Member" file: each "Club" has at least one "Member": Yes/No?each "Club" can have several "Member": Yes/No?each "Member" has at least one "Club": Yes/No?each "Member" can have several "Club": Yes/No?Example of cardinalitiesThis example presents two different cardinalities: 0,1 cardinality: A person can be a member of a single sport club. This person does not have to belong to a sport club.0,N cardinality: A club can have no member or several members.Advanced cardinalities The cardinalities can be defined more precisely. This is referred to as advanced cardinalities.These cardinalities are used to exactly specify the minimum cardinality and the maximum cardinality.To define the advanced cardinalities, check "Display advanced cardinalities" in the link description. The link description can be displayed: when creating a link. Reminder: To create a link, on the "Analysis" pane, in the "Creation" group, click "New link".by double-clicking the representation of a link.Example of advanced cardinalitiesThis example presents two different cardinalities: 0,1 cardinality: A person can be a member of a single sport club. This person does not have to belong to a sport club.0,10 cardinality: A club can have nobody or up to 10 people as members. Minimum version required Version 9 This page is also available for…
 Comments
 Click [Add] to post a comment
 Last update: 05/12/2021Send a report | Local help
 Registered trademarks. Copyright ©2009-2021 PC SOFT. All rights reservedThis website has been developed with WEBDEV and HFSQLWEBDEV, WINDEV Mobile and WINDEV programming