From c9a6f9874300b1bfffd52d151f7faa6ae0fef33f Mon Sep 17 00:00:00 2001 From: Magali Ruffier <mr6@ebi.ac.uk> Date: Wed, 19 Dec 2012 15:43:09 +0000 Subject: [PATCH] not all species have a common name, use production_name as a key instead --- .../production_database/scripts/populate_species_meta.pl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/misc-scripts/production_database/scripts/populate_species_meta.pl b/misc-scripts/production_database/scripts/populate_species_meta.pl index 745cd02005..ea9bd9761f 100644 --- a/misc-scripts/production_database/scripts/populate_species_meta.pl +++ b/misc-scripts/production_database/scripts/populate_species_meta.pl @@ -172,7 +172,7 @@ sub _production { my $sql = 'select common_name, web_name, scientific_name, production_name, url_name, taxon, species_prefix from species where taxon =?'; my $hash_ref = $self->_query_production($sql,$taxon); - if (!exists $hash_ref->{'species.common_name'}) { + if (!exists $hash_ref->{'species.production_name'}) { warning("Failed to find original taxon id for $db. Attempting to obtain by DB name instead"); my $db_name = $db; # regex chops tail end off core-like databases. This must be extended if new naming schemes are used. -- GitLab