From 42d5f18e01377c9c6789b9a413ee046e9a46fa3f Mon Sep 17 00:00:00 2001 From: Richard Burkmar Date: Thu, 11 Aug 2022 12:18:19 +0100 Subject: [PATCH] Added reports/library/taxa/taxon_names_2.xml (New version of taxon_names.xml) --- reports/library/taxa/taxon_names_2.xml | 30 ++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 reports/library/taxa/taxon_names_2.xml diff --git a/reports/library/taxa/taxon_names_2.xml b/reports/library/taxa/taxon_names_2.xml new file mode 100644 index 0000000000..a4dd3ad5ba --- /dev/null +++ b/reports/library/taxa/taxon_names_2.xml @@ -0,0 +1,30 @@ + + + select distinct tall.id, tall.taxon_meaning_id, tall.external_key, tall.default_common_name, + case tall.language_iso when 'lat' then '<em>' || tall.taxon || '</em>' || coalesce(' ' || tall.authority, '') else tall.taxon end, + tall.language_iso, + tall.language_iso='lat' as latin, + tall.preferred + from cache_taxa_taxon_lists t + join cache_taxa_taxon_lists tall on tall.taxon_meaning_id=t.taxon_meaning_id + where 1=1 + + + + tall.preferred desc, tall.language_iso='lat' desc, tall.language_iso desc, tall.id asc + + + + t.id=#taxa_taxon_list_id# + + + t.taxon_meaning_id=#taxon_meaning_id# + + + t.external_key='#external_key#' + + +