-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added reports/library/taxa/taxon_names_2.xml
(New version of taxon_names.xml)
- Loading branch information
Showing
1 changed file
with
30 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
<report | ||
title="Species Data" | ||
description="Report used to retrieve details of a species excluding custom attributes for the species details form. Includes default common name and external key." | ||
> | ||
<query> | ||
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 | ||
|
||
</query> | ||
<order_bys> | ||
<order_by>tall.preferred desc, tall.language_iso='lat' desc, tall.language_iso desc, tall.id asc</order_by> | ||
</order_bys> | ||
<params> | ||
<param name='taxa_taxon_list_id' display='Taxa Taxon List ID' default='' description='Taxa_taxon_list_id of the taxon to load' datatype='text'> | ||
<where>t.id=#taxa_taxon_list_id#</where> | ||
</param> | ||
<param name='taxon_meaning_id' display='Taxon Meaning ID' default='' description='Taxon meaning ID of the taxon to load. Provide this OR the taxa taxon list ID OR the external key.' datatype='text'> | ||
<where>t.taxon_meaning_id=#taxon_meaning_id#</where> | ||
</param> | ||
<param name='external_key' display='External key' default='' description='Taxon meaning ID of the taxon to load. Provide this (tvk) OR the taxa taxon list ID OR the taxon meaning ID.' datatype='text'> | ||
<where>t.external_key='#external_key#'</where> | ||
</param> | ||
</params> | ||
</report> |