Follow Distance Related Tables

DISTANCEPARTS (Follow Participants Between Whom Distance Was Measured)

DISTANCEPARTS contains exactly 2 rows for each recorded distance, one row for each of the individuals between whom the distance was measured. To restate, there are always exactly 2 rows on DISTANCEPARTS for every DISTANCES row. This check is performed on transaction commit.

The individuals between whom the distance is measured can only be those individuals who are participants in the follow -- each Participant value in DISTANCEPARTS has a related CHIMPIDS.AnimID value, this value must be that of a CHIMPIDS.AnimID related to one of the follows' FOLLOWPARTS.ChimpID values. This check is performed on transaction commit on update to FOLLOWPARTS and insert or update of DISTANCEPARTS, and otherwise immediately.

The individual must have the same role (i.e., mother, infant, twin1, etc.) on DISTANCEPARTS as the individual does in the rest of the follow -- the DISTANCEPARTS.Role value for each individual must match the value found in the related FOLLOWPARTS.Role. This check is performed on transaction commit on changes to DISTANCEPARTS and FOLLOWPARTS and immediately upon changes to INTERVALS and DISTANCES.[26]

Distance must be measured between two different individuals -- the combination of DistID and the related CHIMPIDS.AnimID must be unique.

Distance can be measured between two individuals at most once per interval.

If there is a group composition survey for the related interval then the survey must include the individuals between whom the distance was measured -- when there is a related GROUPS row then the related GROUPMEMBERS rows must include rows for the individuals identified in the DISTANCEPARTS rows. This check is performed upon transaction commit on changes to INTERVALS and delete of GROUPMEMBERS rows, and immediately otherwise.

DPID (Distance Participant Identifier)

A unique integer identifying the row recording one participant in the inter-individual distance measurement. This column is automatically maintained by the database, cannot be changed, and must not be NULL.

DistID (Distance Identifier)

The identifier assigned to the distance measurement, the DISTANCES.DistID value, of which the individual was a participant.

This column may not be NULL.

Role

Code indicating the individual's role in the follow. The legal values for this column are defined by the FOLLOWROLES support table.

This column may not be NULL.

Participant (Chimp Virtual Identifier)

The identifier assigned to the individual. The ChimpID code of the individual.

This column may not be NULL.

DISTANCES (Distances Between Follow Participants)

DISTANCES contains one row for each recorded distance between follow participants. Note that codes are used to represent various distance ranges, and that codes have varied over time. For more information see the Gombe Chimp Database Handbook.

When the Distance value is 99, observed but unknown, the Uncertain value must be TRUE.

Note

Deleting a row from the DISTANCES table will delete the entire record of the distance -- the system will first delete all related DISTANCEPARTS rows.

DistID (Distance Identifier)

A unique integer identifying the row recording the distance. This column is automatically maintained by the database, cannot be changed, and must not be NULL.

IntID (Interval Identifier)

The identifier assigned to the follow interval, the INTERVALS.IntID, value, during which the distance measurement was taken.

This column may not be NULL.

Uncertain (Distance is Uncertain)

A Boolean flag indicating whether the observer was certain of the recorded distance measurement. TRUE when the distance measurement is not certain, FALSE when certain.

This column may not be NULL.

Distance (Distance Code)

Code indicating the distance between two followed individuals. The legal values for this column are defined by the DISTANCECODES support table.

This column may not be NULL.



[26] An improved design would have the trigger automatically set the value of DISTANCEPARTS.Role based on the individual's FOLLOWPARTS.Role. Among other advantages, the columns on the FAMILY_DISTS view that expose the role could be removed.


Page generated: 2018-08-25T22:19:25-04:00.