Project

General

Profile

« Previous | Next » 

Revision 14426

fix: inputs/.TNRS/schema.sql: MatchedTaxon: merged synonymous columns

View differences:

vegbien.sql
8448 8448
    taxon_scrub."*Name_matched" AS "Name_matched__@TNRS__@vegpath.org",
8449 8449
    taxon_scrub."*Name_matched_author" AS "Name_matched_author__@TNRS__@vegpath.org",
8450 8450
    family_higher_plant_group.higher_plant_group AS "[higher_plant_group~]higherClassification__@DwC__@vegpath.org",
8451
    taxon_scrub."taxonomicStatus" AS "taxonomicStatus__@DwC__@vegpath.org",
8451
    taxon_scrub."[scrubbed_]taxonomicStatus__@DwC__@vegpath.org" AS "taxonomicStatus__@DwC__@vegpath.org",
8452 8452
    taxon_scrub.scrubbed_family,
8453 8453
    taxon_scrub.scrubbed_genus,
8454 8454
    taxon_scrub.scrubbed_specific_epithet,
......
12439 12439
CREATE VIEW _plots_20_tnrs_names AS
12440 12440
 SELECT taxonverbatim.taxonomicname AS verbatim_name_with_author,
12441 12441
    taxonlabel.taxonomicname AS tnrs_input_name,
12442
    taxon_scrub."taxonomicStatus" AS tnrs_taxonomic_status,
12442
    taxon_scrub."[scrubbed_]taxonomicStatus__@DwC__@vegpath.org" AS tnrs_taxonomic_status,
12443 12443
    taxon_scrub."*Accepted_name_family" AS tnrs_accepted_name_family,
12444 12444
    taxon_scrub."*Accepted_name" AS tnrs_accepted_name,
12445 12445
    taxon_scrub."*Accepted_name_author" AS tnrs_accepted_name_author,
12446
    taxon_scrub.accepted_morphospecies_binomial AS taxon_morphospecies
12446
    taxon_scrub."[accepted_]morphospecies[_binomial]__@Brad__.TNRS@vegpath.org" AS taxon_morphospecies
12447 12447
   FROM ((public.taxonverbatim
12448 12448
   JOIN public.taxonlabel USING (taxonlabel_id))
12449 12449
   JOIN "TNRS".taxon_scrub ON ((taxon_scrub."*Name_submitted" = taxonlabel.taxonomicname)))
......
21411 21411
    taxon_best_match."[scrubbed_]infraspecificEpithet__@DwC__@vegpath.org",
21412 21412
    taxon_best_match."[scrubbed_]name[_no_author]~(-Accepted_-)__@TNRS__@vegpath.org",
21413 21413
    taxon_best_match."[scrubbed_]author~(-Accepted_-)__@TNRS__@vegpath.org",
21414
    taxon_best_match."[scrubbed_]scientificName[_with_author]__@DwC__@vegpath.org",
21415
        CASE
21416
            WHEN true THEN taxon_best_match."[scrubbed_]taxonomicStatus__@DwC__@vegpath.org"
21417
            ELSE NULL::text
21418
        END AS "taxonomicStatus",
21419
        CASE
21420
            WHEN true THEN taxon_best_match."[accepted_]morphospecies[_binomial]__@Brad__.TNRS@vegpath.org"
21421
            ELSE NULL::text
21422
        END AS accepted_morphospecies_binomial
21414
    taxon_best_match."[scrubbed_]scientificName[_with_author]__@DwC__@vegpath.org"
21423 21415
   FROM taxon_best_match;
21424 21416

  
21425 21417

  
......
21506 21498
    "MatchedTaxon"."[scrubbed_]infraspecificEpithet__@DwC__@vegpath.org",
21507 21499
    "MatchedTaxon"."[scrubbed_]name[_no_author]~(-Accepted_-)__@TNRS__@vegpath.org",
21508 21500
    "MatchedTaxon"."[scrubbed_]author~(-Accepted_-)__@TNRS__@vegpath.org",
21509
    "MatchedTaxon"."[scrubbed_]scientificName[_with_author]__@DwC__@vegpath.org",
21510
    "MatchedTaxon"."taxonomicStatus",
21511
    "MatchedTaxon".accepted_morphospecies_binomial
21501
    "MatchedTaxon"."[scrubbed_]scientificName[_with_author]__@DwC__@vegpath.org"
21512 21502
   FROM "MatchedTaxon"
21513 21503
  WHERE "MatchedTaxon".is_valid_match;
21514 21504

  
......
21706 21696
--
21707 21697

  
21708 21698
CREATE VIEW taxon_scrub AS
21709
 SELECT "ValidMatchedTaxon".scrubbed_unique_taxon_name,
21710
    "ValidMatchedTaxon".batch,
21699
 SELECT "ValidMatchedTaxon".batch,
21711 21700
    "ValidMatchedTaxon".match_num,
21712 21701
    "ValidMatchedTaxon"."*Name_number",
21713 21702
    "ValidMatchedTaxon"."*Name_submitted",
......
21746 21735
    "ValidMatchedTaxon"."*Warnings",
21747 21736
    "ValidMatchedTaxon"."*Accepted_name_lsid",
21748 21737
    "ValidMatchedTaxon".is_valid_match,
21738
    "ValidMatchedTaxon".scrubbed_unique_taxon_name,
21749 21739
    "ValidMatchedTaxon"."[parsed_]morphospecies[_suffix]__@Brad__.morphosp@vegpath.org",
21750 21740
    "ValidMatchedTaxon"."[matched_]species[_binomial]~(-Accepted_-)__@TNRS__@vegpath.org",
21751 21741
    "ValidMatchedTaxon"."matched~Name[_no_author]___@TNRS__@vegpath.org",
......
21773 21763
    "ValidMatchedTaxon"."[scrubbed_]name[_no_author]~(-Accepted_-)__@TNRS__@vegpath.org",
21774 21764
    "ValidMatchedTaxon"."[scrubbed_]author~(-Accepted_-)__@TNRS__@vegpath.org",
21775 21765
    "ValidMatchedTaxon"."[scrubbed_]scientificName[_with_author]__@DwC__@vegpath.org",
21776
    "ValidMatchedTaxon"."taxonomicStatus",
21777
    "ValidMatchedTaxon".accepted_morphospecies_binomial,
21778 21766
        CASE
21779 21767
            WHEN true THEN "ValidMatchedTaxon"."[scrubbed_]taxonRank__@DwC__@vegpath.org"
21780 21768
            ELSE NULL::text

Also available in: Unified diff