'$RCSfile: eml-constraint.xsd,v $'
Copyright: 2000 Regents of the University of California and the
National Center for Ecological Analysis and Synthesis
For Details: http://knb.ecoinformatics.org/
'$Author: berkley $'
'$Date: 2002/04/21 22:45:30 $'
'$Revision: 1.15 $'
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
eml-constraint
This schema defines the integrity constraints between entities
(e.g., data tables) as would be maintained in a relational database.
These constraints include
primary key constraints, foreign key constraints, unique key
constraints, check constraints, and not null constraints,
among potential others.
Relational integrity constraint descriptors
Describes the relational integrity constraints of a relational
database.
Describes the relational integrity constraints of a relational
database. This includes primary keys, foreign keys, unique keys, etc.
When an eml-constraint module is created, it should be linked into
a dataset using the "triple" element, and all of the entities that
are referenced in the constraints should be accessible within that
same package.
New in EML 2.0
Unique identifier
The unique identifier of this metadata file or object.
The identifier field provides a unique identifier for this
metadata documentation. It will most likely be part of a
sequence of numbers or letters that are meaningful in a
larger context, such as a metadata catalog. That larger
system can be identified in the "system" attribute. Multiple
identifiers can be listed corresponding to different catalog
systems.
nceas.3.2
]]>
The 'identifier' field is derived from the eml-dataset
meta_file_id filed in EML 1.4.
Catalog system
The catalog system in which this identifier is used.
This element gives the name of the catalog system in which
this identifier is used. It is useful to determine the
scope of the identifier, and to determine the semantics
of the various subparts of the identifier. Unresolved issue:
can or should this be a URI/URL pointing to the catalog
system, or just the name?
nceas.3.2]]>
New to EML 2.0.
Integrity constraint
Information about the integrity constraint being defined.
Complete information needed to reconstruct this integrity
constraint for enforcement in a system such as a relational
database management system.
New in EML 2.0
type of constraint
the type of constraint being defined
the type of constraint being defined. This is
what kind of constraint this is.
PrimaryKey, ForeignKey, UniqueKey
New in EML 2.0
Extended description of the key
Key
The set of attributes to which this constraint applies.
The set of attributes to which this constraint applies.
For a primary key or a unique key, the set of attributes must be
identifying. For a foreign key, the set of attributes must match
an identifying key in the referenced entity. For a not null
constraint, the key indicates the attribute which should not
be null.
New in EML 2.0
Attribute Name
Name of an attribute found in the identified entity
Name of an attribute that can be found in the identified
entity. This name will be unique within an entity and
specifies that the attribute participates in the key that
is being defined.
New in EML 2.0
Key
The set of attributes to which this constraint applies.
The set of attributes to which this constraint applies.
For a primary key or a unique key, the set of attributes must be
identifying. For a foreign key, the set of attributes must match
an identifying key in the referenced entity. For a not null
constraint, the key indicates the attribute which should not
be null.
New in EML 2.0
Attribute Name
Name of an attribute found in the identified entity
Name of an attribute that can be found in the identified
entity. This name will be unique within an entity and
specifies that the attribute participates in the key that
is being defined.
New in EML 2.0
Check Condition
An SQL statement or other language implementation of
the condition for a check constraint.
A SQL statement or other language implementation of
the condition for a check constraint.
Generally this provides a means for constraining the
values within and among entities.
1900 and year < 1990)]]>
New in EML 2.0
Key
The set of attributes to which this constraint applies.
The set of attributes to which this constraint applies.
For a primary key or a unique key, the set of attributes must be
identifying. For a foreign key, the set of attributes must match
an identifying key in the referenced entity. For a not null
constraint, the key indicates the attribute which should not
be null.
New in EML 2.0
Attribute Name
Name of an attribute found in the identified entity
Name of an attribute that can be found in the identified
entity. This name will be unique within an entity and
specifies that the attribute participates in the key that
is being defined.
New in EML 2.0
Constrained Entity
Entity to which this constraint applies
Entity to which this constraint applies. This should be
an identifer that matches one of the "identifier"
elements for an entity that is linked into the package
with a triple. The constraint document itself should be
linked into the package as a member.
knb.78.3
New in EML 2.0.0
Referenced Entity ID
The id of the parent-entity in a foreign key constraint.
This field contains the id of the entity to which a foreign key
refers, otherwise known as the parent-entity or parent-table.
This should be an identifer that matches one of the "identifier"
elements for an entity that is linked into the package
with a triple. The constraint document itself should be
linked into the package as a member.
knb.79.4
New in EML 2.0
Key
The set of attributes to which a foreign key constraint refers.
The set of attributes to which a foreign key constraint refers.
If the key refers to the primary key in the referenced entity,
then the "referencedKey" is optional. For a foreign key, the
set of attributes must match an identifying key in the
referenced entity.
New in EML 2.0
Attribute Name
Name of an attribute found in the identified entity
Name of an attribute that can be found in the identified
entity. This name will be unique within an entity and
specifies that the attribute participates in the key that
is being defined.
New in EML 2.0
Specify whether the "parent" key is mandatory or optional.
Specify whether the "parent" key is mandatory or optional.
Describes the relationship between a pair of entities from the perspective of the child entity. Fundamentally, it is the answer to the question, "Is a foreign key value required in the child entity?" If the answer is OPTIONAL, then a foreign key value is not always required in the child entity,. If a value does exist, then the foreign key value must be found in the primary key of the parent. If the answer is MANDATORY, then a foreign key vale must exist in the child entity and the foreign key value must be found in the primary key of the parent.. At the physical database level mandatory becomes "not null" while optional becomes "null".
New in EML 2.0
speficies whether the "child" key is mandatory or optional
Relationship type: Identifying or non-identifying
Relationship type: Identifying or non-identifying
Identifying relationships propagate the the parent entity's primary key to the child's primary key. Non-identifying relationships propagate the parent's primary key as a non-key attribute of the child entity. Relations
New in EML 2.0
Cardinality of the relationship between parent and child entities
Cardinality of the relationship between parent and child entities
Cardinality is a statement of of the relationship between parent and child entities. Cardinality is expressed as the ratio of related parent and child entities. The cardinality ratio for the parent entity depends on whether the relationshipType is mandatory (one or more) or optional (zero or more). Cardinality is a "logical" design concept. Its implementation at the physical database level must be done through procedures or through an application. One to Many, One to One, Zero or One to Many
New in EML 2.0
Cardinality of 0 or 1 (parents) to exactly N (children)
Cardinality 1 to N is a specific form of cardinalty in which zero or one parent records are related to a specified number of child records.
Cardinality is a statement of of the relationship between parent and child entities. Cardinality is expressed as the ration of related parent and child entities. Cardinality 1 to N is a specific form of cardinalty in which zero or one parent records are related to a specified number of child records.The cardinality ratio for the parent entity depends on whether the relationshipType is mandatory (one or more) or optional (zero or 15.
One to 10, Zero or One to Many
New in EML 2.0
Parent portion of a 1 to exactly N cardinality
Parent portion of a 1 to exactly N cardinality May have a value of either 0 or 1.
>Parent portion of a 1 to exactly N cardinality May have a value of either 0 or 1. Value of 0 implies a non-identifying relationship. Value of 1 implies an identifying relationship. One to 10, Zero or One to Many
New in EML 2.0
Child portion of a 1 to exactly N cardinality
Child portion of a 1 to exactly N cardinality. May have an interger value of 1 or greater.
>Child portion of a 1 to exactly N cardinality. In a 1 to exactly N cardinality, the value of N should be 2 or greater since a one to one zero or one to one relationship can be specified in the cardinality element. 2, 15
New in EML 2.0