Skip to content

When should occurrences table be updated to match authorities? #18

@aazaff

Description

@aazaff

I have created the following scenarios using collection_no 3000 and collection_no 30001 on the dev server.

SCENARIO 1

I have added the following taxa via the client edit-occurrences to collection 3000.

  1. Virgiana decussata
  2. Virgiana decussatredux
  3. Virgiana sp.
  4. Virgiana bobii

Here is how the added occurrences look in the db after adding through the form.

SELECT taxon_no, genus_name, species_name 
FROM occurrences WHERE collection_no = 3000;
occurrence_no taxon_no genus_name species_name Result
39163 309830 Virgiana decussata Virgiana decussata is matched to pre-existing species Virgiana decussata in the Authorities table (taxon_no 309830)
1662178 28329 Virgiana decussatredux Virgiana decussataredux does not exist in the database and is matched to closest name - genus Virgiana (taxon_no 28329)
1662179 28329 Virgiana sp. Virgiana is matched to genus Virgiana (taxon_no 28329)
1662180 28329 Virgiana bobii Virgiana bobii does not exist in the database and is matched to closest name - genus Virgiana (taxon_no 28329).

All of this matches my expectations. Note the following: the species name is NOT changed to sp. for the species only matched to genus. The taxon names (i.e., genus and species fields) retain whatever was originally entered.

SCENARIO 2

I used the edit taxon form to change the name for Virgiana decussata to now be Virgiana decussataredux. This change is reflected by a change in the Authorities table as shown below.

SELECT taxon_no, taxon_name 
FROM authorities WHERE taxon_no = 309830;
taxon_no taxon_name
309830 Virgiana decussataredux

What you might expect after this change is the following:

  1. The taxon_no for occurrence_no 39163 will change from 309830 to 28329 because Virgiana decussata no longer has an authority.
  2. The taxon_no for occurrence_no 1662178 will change from 28329 to 309830 because Virgiana decussataredux now has an authority.

However, NEITHER of these things happen and the occurrences table stays exactly as it was before the name change in the authorities table.

SELECT taxon_no, genus_name, species_name 
FROM occurrences WHERE collection_no = 3000;
occurrence_no taxon_no genus_name species_name notes
39163 309830 Virgiana decussata Virgiana decussata is matched to pre-existing species Virgiana decussata in the Authorities table (taxon_no 309830)
1662178 28329 Virgiana decussatredux Virgiana decussataredux does not exist in the database and is matched to closest genus Virgiana (taxon_no 28329)
1662179 28329 Virgiana sp. Virgiana is matched to genus Virgiana (taxon_no 28329)
1662180 28329 Virgiana bobii Virgiana bobii does not exist in the database and is matched to closest genus Virgiana (taxon_no 28329).

SCENARIO 3

I went to collection 3001 and add new occurrences for Virgiana decussata and Virgiana decussataredux.

SELECT occurrence_no, taxon_no, genus_name, species_name 
FROM occurrences WHERE collection_no = 3001;
occurrence_no taxon_no genus_name species_name notes
39187 309830 Virgiana decussata Ignore this, we will come back to this later
39188 28329 Virgiana bobii Virgiana bobii does not exist in the database and is matched to closest genus Virgiana (taxon_no 28329)
1662181 309830 Virgiana decussata matched to taxon 309830 even though the name no longer has a match in the authorities table
1662182 309830 Virgiana decussataredux matched to taxon 309830 based on exact match to authorities table.

The taxon_no matching procedure now matches BOTH Virgiana decussata and Virgiana decussataredux to taxon_no 309830. This seems inconsistent with the behavior observed in SCENARIO 2.

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions