humlab-sead / sead_bugs_import

SEAD bugs import
2 stars 0 forks source link

Bugs import error: No group found for code #45

Closed roger-mahler closed 4 years ago

roger-mahler commented 4 years ago

The error is raised for all Koch ecocode definitions, and caused by the system failing to retrieve the Kock ecocode system item in tbl_ecocode_systems. The following snippet gives the domain query used, that expects the name to be "Koch System". The name in the database is "Koch Ecology Codes".

public interface EcocodeSystemRepository extends Repository<EcocodeSystem, Integer> {

    @Query("select eSystem from EcocodeSystem eSystem where eSystem.name = 'Koch System'")
    EcocodeSystem findKochSystem();
}