Revision 14376
Added by Aaron Marcuse-Kubitza over 10 years ago
trunk/inputs/.TNRS/schema.sql | ||
---|---|---|
223 | 223 |
new.matched_has_accepted = NULL; |
224 | 224 |
new."Accepted_family__@TNRS__@vegpath.org" = NULL; |
225 | 225 |
new."Accepted_species[_binomial]__@TNRS__@vegpath.org" = NULL; |
226 |
new."__accepted_{genus,specific_epithet}" = NULL; |
|
226 |
new."__accepted_{genus,specific_epithet,infra_{rank,epithet}}" = NULL;
|
|
227 | 227 |
new."[accepted_]genus__@DwC__@vegpath.org" = NULL; |
228 | 228 |
new."[accepted_]specificEpithet__@DwC__@vegpath.org" = NULL; |
229 | 229 |
new."[accepted_]morphospecies[_binomial]__@Brad__.TNRS@vegpath.org" = NULL; |
... | ... | |
257 | 257 |
ELSE NULL::text |
258 | 258 |
END) FROM (SELECT new.*) new); |
259 | 259 |
new."Accepted_species[_binomial]__@TNRS__@vegpath.org" = (SELECT rtrim("*Accepted_name_species", ' '::text) FROM (SELECT new.*) new); |
260 |
new."__accepted_{genus,specific_epithet}" = (SELECT regexp_split_to_array("*Accepted_name", ' '::text) FROM (SELECT new.*) new); |
|
261 |
new."[accepted_]genus__@DwC__@vegpath.org" = (SELECT COALESCE("__accepted_{genus,specific_epithet}"[1], |
|
260 |
new."__accepted_{genus,specific_epithet,infra_{rank,epithet}}" = (SELECT regexp_split_to_array("*Accepted_name", ' '::text) FROM (SELECT new.*) new);
|
|
261 |
new."[accepted_]genus__@DwC__@vegpath.org" = (SELECT COALESCE("__accepted_{genus,specific_epithet,infra_{rank,epithet}}"[1],
|
|
262 | 262 |
CASE |
263 | 263 |
WHEN ("*Accepted_name_rank" = 'genus'::text) THEN "*Accepted_name" |
264 | 264 |
ELSE NULL::text |
265 | 265 |
END) FROM (SELECT new.*) new); |
266 |
new."[accepted_]specificEpithet__@DwC__@vegpath.org" = (SELECT "__accepted_{genus,specific_epithet}"[2] FROM (SELECT new.*) new); |
|
266 |
new."[accepted_]specificEpithet__@DwC__@vegpath.org" = (SELECT "__accepted_{genus,specific_epithet,infra_{rank,epithet}}"[2] FROM (SELECT new.*) new);
|
|
267 | 267 |
new."[accepted_]morphospecies[_binomial]__@Brad__.TNRS@vegpath.org" = (SELECT CASE |
268 | 268 |
WHEN ("*Accepted_name_rank" = 'family'::text) THEN concat_ws(' '::text, "Accepted_family__@TNRS__@vegpath.org", "[parsed_]morphospecies[_suffix]__@Brad__.morphosp@vegpath.org") |
269 | 269 |
WHEN ("*Accepted_name_rank" = 'genus'::text) THEN concat_ws(' '::text, "[accepted_]genus__@DwC__@vegpath.org", "[parsed_]morphospecies[_suffix]__@Brad__.morphosp@vegpath.org") |
... | ... | |
458 | 458 |
matched_has_accepted boolean, |
459 | 459 |
"Accepted_family__@TNRS__@vegpath.org" text, |
460 | 460 |
"Accepted_species[_binomial]__@TNRS__@vegpath.org" text, |
461 |
"__accepted_{genus,specific_epithet}" text[], |
|
461 |
"__accepted_{genus,specific_epithet,infra_{rank,epithet}}" text[],
|
|
462 | 462 |
"[accepted_]genus__@DwC__@vegpath.org" text, |
463 | 463 |
"[accepted_]specificEpithet__@DwC__@vegpath.org" text, |
464 | 464 |
"[accepted_]morphospecies[_binomial]__@Brad__.TNRS@vegpath.org" text, |
... | ... | |
486 | 486 |
END)))), |
487 | 487 |
CONSTRAINT "Accepted_species[_binomial]__@TNRS__@vegpath.org" CHECK ((NOT ("Accepted_species[_binomial]__@TNRS__@vegpath.org" IS DISTINCT FROM rtrim("*Accepted_name_species", ' '::text)))), |
488 | 488 |
CONSTRAINT "[accepted_]Infraspecific_rank[_abbr]__@TNRS__@vegpath.org" CHECK ((NOT ("[accepted_]Infraspecific_rank[_abbr]__@TNRS__@vegpath.org" IS DISTINCT FROM "__accepted_infraspecific_{rank,epithet}"[1]))), |
489 |
CONSTRAINT "[accepted_]genus__@DwC__@vegpath.org" CHECK ((NOT ("[accepted_]genus__@DwC__@vegpath.org" IS DISTINCT FROM COALESCE("__accepted_{genus,specific_epithet}"[1], |
|
489 |
CONSTRAINT "[accepted_]genus__@DwC__@vegpath.org" CHECK ((NOT ("[accepted_]genus__@DwC__@vegpath.org" IS DISTINCT FROM COALESCE("__accepted_{genus,specific_epithet,infra_{rank,epithet}}"[1],
|
|
490 | 490 |
CASE |
491 | 491 |
WHEN ("*Accepted_name_rank" = 'genus'::text) THEN "*Accepted_name" |
492 | 492 |
ELSE NULL::text |
... | ... | |
499 | 499 |
ELSE "Accepted_species[_binomial]__@TNRS__@vegpath.org" |
500 | 500 |
END))), |
501 | 501 |
CONSTRAINT "[accepted_]scientificName[_with_author]__@DwC__@vegpath.org" CHECK ((NOT ("[accepted_]scientificName[_with_author]__@DwC__@vegpath.org" IS DISTINCT FROM ("*Accepted_name" || COALESCE((' '::text || "*Accepted_name_author"), ''::text))))), |
502 |
CONSTRAINT "[accepted_]specificEpithet__@DwC__@vegpath.org" CHECK ((NOT ("[accepted_]specificEpithet__@DwC__@vegpath.org" IS DISTINCT FROM "__accepted_{genus,specific_epithet}"[2]))), |
|
502 |
CONSTRAINT "[accepted_]specificEpithet__@DwC__@vegpath.org" CHECK ((NOT ("[accepted_]specificEpithet__@DwC__@vegpath.org" IS DISTINCT FROM "__accepted_{genus,specific_epithet,infra_{rank,epithet}}"[2]))),
|
|
503 | 503 |
CONSTRAINT "[matched_]scientificName[_with_author]__@DwC__@vegpath.org" CHECK ((NOT ("[matched_]scientificName[_with_author]__@DwC__@vegpath.org" IS DISTINCT FROM ("matched~Name[_no_author]___@TNRS__@vegpath.org" || COALESCE((' '::text || "*Name_matched_author"), ''::text))))), |
504 | 504 |
CONSTRAINT "[matched_]species[_binomial]~(-Accepted_-)__@TNRS__@vegpath.org" CHECK ((NOT ("[matched_]species[_binomial]~(-Accepted_-)__@TNRS__@vegpath.org" IS DISTINCT FROM (("*Genus_matched" || ' '::text) || "*Specific_epithet_matched")))), |
505 | 505 |
CONSTRAINT "[parsed_]morphospecies[_suffix]__@Brad__.morphosp@vegpath.org" CHECK ((NOT ("[parsed_]morphospecies[_suffix]__@Brad__.morphosp@vegpath.org" IS DISTINCT FROM "*Unmatched_terms"))), |
... | ... | |
562 | 562 |
CONSTRAINT "[scrubbed_]taxonomicStatus__@DwC__@vegpath.org" CHECK ((NOT ("[scrubbed_]taxonomicStatus__@DwC__@vegpath.org" IS DISTINCT FROM map_taxonomic_status("*Taxonomic_status", "*Accepted_name")))), |
563 | 563 |
CONSTRAINT __accepted_infraspecific_label CHECK ((NOT (__accepted_infraspecific_label IS DISTINCT FROM ltrim(NULLIF(remove_prefix("Accepted_species[_binomial]__@TNRS__@vegpath.org", "*Accepted_name", require := true, case_sensitive := false), ''::text), ' '::text)))), |
564 | 564 |
CONSTRAINT "__accepted_infraspecific_{rank,epithet}" CHECK ((NOT ("__accepted_infraspecific_{rank,epithet}" IS DISTINCT FROM regexp_split_to_array(__accepted_infraspecific_label, ' '::text)))), |
565 |
CONSTRAINT "__accepted_{genus,specific_epithet}" CHECK ((NOT ("__accepted_{genus,specific_epithet}" IS DISTINCT FROM regexp_split_to_array("*Accepted_name", ' '::text)))),
|
|
565 |
CONSTRAINT "__accepted_{genus,specific_epithet,infra_{rank,epithet}}" CHECK ((NOT ("__accepted_{genus,specific_epithet,infra_{rank,epithet}}" IS DISTINCT FROM regexp_split_to_array("*Accepted_name", ' '::text)))),
|
|
566 | 566 |
CONSTRAINT matched_has_accepted CHECK ((NOT (matched_has_accepted IS DISTINCT FROM ("*Accepted_name" IS NOT NULL)))), |
567 | 567 |
CONSTRAINT "matched~Name[_no_author]___@TNRS__@vegpath.org" CHECK ((NOT ("matched~Name[_no_author]___@TNRS__@vegpath.org" IS DISTINCT FROM NULLIF("*Name_matched", 'No suitable matches found.'::text)))) |
568 | 568 |
); |
... | ... | |
755 | 755 |
|
756 | 756 |
|
757 | 757 |
-- |
758 |
-- Name: COLUMN taxon_match."__accepted_{genus,specific_epithet}"; Type: COMMENT; Schema: TNRS; Owner: - |
|
758 |
-- Name: COLUMN taxon_match."__accepted_{genus,specific_epithet,infra_{rank,epithet}}"; Type: COMMENT; Schema: TNRS; Owner: -
|
|
759 | 759 |
-- |
760 | 760 |
|
761 |
COMMENT ON COLUMN taxon_match."__accepted_{genus,specific_epithet}" IS ' |
|
761 |
COMMENT ON COLUMN taxon_match."__accepted_{genus,specific_epithet,infra_{rank,epithet}}" IS '
|
|
762 | 762 |
= regexp_split_to_array("*Accepted_name", '' ''::text) |
763 | 763 |
|
764 | 764 |
derived column |
765 | 765 |
|
766 | 766 |
to modify expr: |
767 |
SELECT util.derived_col_update(((''"TNRS".taxon_match'', ''__accepted_{genus,specific_epithet}'')::util.col, $$regexp_split_to_array("*Accepted_name", '' ''::text)$$)::util.derived_col_def); |
|
767 |
SELECT util.derived_col_update(((''"TNRS".taxon_match'', ''__accepted_{genus,specific_epithet,infra_{rank,epithet}}'')::util.col, $$regexp_split_to_array("*Accepted_name", '' ''::text)$$)::util.derived_col_def);
|
|
768 | 768 |
SELECT util.derived_cols_populate(''"TNRS".taxon_match''::regclass); |
769 | 769 |
|
770 | 770 |
to rename: |
... | ... | |
779 | 779 |
-- |
780 | 780 |
|
781 | 781 |
COMMENT ON COLUMN taxon_match."[accepted_]genus__@DwC__@vegpath.org" IS ' |
782 |
= COALESCE("__accepted_{genus,specific_epithet}"[1], |
|
782 |
= COALESCE("__accepted_{genus,specific_epithet,infra_{rank,epithet}}"[1],
|
|
783 | 783 |
CASE |
784 | 784 |
WHEN ("*Accepted_name_rank" = ''genus''::text) THEN "*Accepted_name" |
785 | 785 |
ELSE NULL::text |
... | ... | |
788 | 788 |
derived column |
789 | 789 |
|
790 | 790 |
to modify expr: |
791 |
SELECT util.derived_col_update(((''"TNRS".taxon_match'', ''[accepted_]genus__@DwC__@vegpath.org'')::util.col, $$COALESCE("__accepted_{genus,specific_epithet}"[1], |
|
791 |
SELECT util.derived_col_update(((''"TNRS".taxon_match'', ''[accepted_]genus__@DwC__@vegpath.org'')::util.col, $$COALESCE("__accepted_{genus,specific_epithet,infra_{rank,epithet}}"[1],
|
|
792 | 792 |
CASE |
793 | 793 |
WHEN ("*Accepted_name_rank" = ''genus''::text) THEN "*Accepted_name" |
794 | 794 |
ELSE NULL::text |
... | ... | |
807 | 807 |
-- |
808 | 808 |
|
809 | 809 |
COMMENT ON COLUMN taxon_match."[accepted_]specificEpithet__@DwC__@vegpath.org" IS ' |
810 |
= "__accepted_{genus,specific_epithet}"[2] |
|
810 |
= "__accepted_{genus,specific_epithet,infra_{rank,epithet}}"[2]
|
|
811 | 811 |
|
812 | 812 |
derived column |
813 | 813 |
|
814 | 814 |
to modify expr: |
815 |
SELECT util.derived_col_update(((''"TNRS".taxon_match'', ''[accepted_]specificEpithet__@DwC__@vegpath.org'')::util.col, $$"__accepted_{genus,specific_epithet}"[2]$$)::util.derived_col_def); |
|
815 |
SELECT util.derived_col_update(((''"TNRS".taxon_match'', ''[accepted_]specificEpithet__@DwC__@vegpath.org'')::util.col, $$"__accepted_{genus,specific_epithet,infra_{rank,epithet}}"[2]$$)::util.derived_col_def);
|
|
816 | 816 |
SELECT util.derived_cols_populate(''"TNRS".taxon_match''::regclass); |
817 | 817 |
|
818 | 818 |
to rename: |
... | ... | |
1310 | 1310 |
taxon_match.matched_has_accepted, |
1311 | 1311 |
taxon_match."Accepted_family__@TNRS__@vegpath.org", |
1312 | 1312 |
taxon_match."Accepted_species[_binomial]__@TNRS__@vegpath.org", |
1313 |
taxon_match."__accepted_{genus,specific_epithet}", |
|
1313 |
taxon_match."__accepted_{genus,specific_epithet,infra_{rank,epithet}}" AS "__accepted_{genus,specific_epithet}",
|
|
1314 | 1314 |
taxon_match."[accepted_]genus__@DwC__@vegpath.org", |
1315 | 1315 |
taxon_match."[accepted_]specificEpithet__@DwC__@vegpath.org", |
1316 | 1316 |
taxon_match."[accepted_]morphospecies[_binomial]__@Brad__.TNRS@vegpath.org", |
trunk/schemas/vegbien.my.sql | ||
---|---|---|
15963 | 15963 |
matched_has_accepted int(1), |
15964 | 15964 |
`Accepted_family__@TNRS__@vegpath.org` varchar(255), |
15965 | 15965 |
`Accepted_species[_binomial]__@TNRS__@vegpath.org` varchar(255), |
15966 |
`__accepted_{genus,specific_epithet}` varchar(255), |
|
15966 |
`__accepted_{genus,specific_epithet,infra_{rank,epithet}}` varchar(255),
|
|
15967 | 15967 |
`[accepted_]genus__@DwC__@vegpath.org` varchar(255), |
15968 | 15968 |
`[accepted_]specificEpithet__@DwC__@vegpath.org` varchar(255), |
15969 | 15969 |
`[accepted_]morphospecies[_binomial]__@Brad__.TNRS@vegpath.org` varchar(255), |
... | ... | |
16102 | 16102 |
|
16103 | 16103 |
|
16104 | 16104 |
-- |
16105 |
-- Name: COLUMN taxon_match.`__accepted_{genus,specific_epithet}`; Type: COMMENT; Schema: TNRS; Owner: - |
|
16105 |
-- Name: COLUMN taxon_match.`__accepted_{genus,specific_epithet,infra_{rank,epithet}}`; Type: COMMENT; Schema: TNRS; Owner: -
|
|
16106 | 16106 |
-- |
16107 | 16107 |
|
16108 | 16108 |
|
trunk/schemas/vegbien.sql | ||
---|---|---|
19842 | 19842 |
new.matched_has_accepted = NULL; |
19843 | 19843 |
new."Accepted_family__@TNRS__@vegpath.org" = NULL; |
19844 | 19844 |
new."Accepted_species[_binomial]__@TNRS__@vegpath.org" = NULL; |
19845 |
new."__accepted_{genus,specific_epithet}" = NULL; |
|
19845 |
new."__accepted_{genus,specific_epithet,infra_{rank,epithet}}" = NULL;
|
|
19846 | 19846 |
new."[accepted_]genus__@DwC__@vegpath.org" = NULL; |
19847 | 19847 |
new."[accepted_]specificEpithet__@DwC__@vegpath.org" = NULL; |
19848 | 19848 |
new."[accepted_]morphospecies[_binomial]__@Brad__.TNRS@vegpath.org" = NULL; |
... | ... | |
19876 | 19876 |
ELSE NULL::text |
19877 | 19877 |
END) FROM (SELECT new.*) new); |
19878 | 19878 |
new."Accepted_species[_binomial]__@TNRS__@vegpath.org" = (SELECT rtrim("*Accepted_name_species", ' '::text) FROM (SELECT new.*) new); |
19879 |
new."__accepted_{genus,specific_epithet}" = (SELECT regexp_split_to_array("*Accepted_name", ' '::text) FROM (SELECT new.*) new); |
|
19880 |
new."[accepted_]genus__@DwC__@vegpath.org" = (SELECT COALESCE("__accepted_{genus,specific_epithet}"[1], |
|
19879 |
new."__accepted_{genus,specific_epithet,infra_{rank,epithet}}" = (SELECT regexp_split_to_array("*Accepted_name", ' '::text) FROM (SELECT new.*) new);
|
|
19880 |
new."[accepted_]genus__@DwC__@vegpath.org" = (SELECT COALESCE("__accepted_{genus,specific_epithet,infra_{rank,epithet}}"[1],
|
|
19881 | 19881 |
CASE |
19882 | 19882 |
WHEN ("*Accepted_name_rank" = 'genus'::text) THEN "*Accepted_name" |
19883 | 19883 |
ELSE NULL::text |
19884 | 19884 |
END) FROM (SELECT new.*) new); |
19885 |
new."[accepted_]specificEpithet__@DwC__@vegpath.org" = (SELECT "__accepted_{genus,specific_epithet}"[2] FROM (SELECT new.*) new); |
|
19885 |
new."[accepted_]specificEpithet__@DwC__@vegpath.org" = (SELECT "__accepted_{genus,specific_epithet,infra_{rank,epithet}}"[2] FROM (SELECT new.*) new);
|
|
19886 | 19886 |
new."[accepted_]morphospecies[_binomial]__@Brad__.TNRS@vegpath.org" = (SELECT CASE |
19887 | 19887 |
WHEN ("*Accepted_name_rank" = 'family'::text) THEN concat_ws(' '::text, "Accepted_family__@TNRS__@vegpath.org", "[parsed_]morphospecies[_suffix]__@Brad__.morphosp@vegpath.org") |
19888 | 19888 |
WHEN ("*Accepted_name_rank" = 'genus'::text) THEN concat_ws(' '::text, "[accepted_]genus__@DwC__@vegpath.org", "[parsed_]morphospecies[_suffix]__@Brad__.morphosp@vegpath.org") |
... | ... | |
20119 | 20119 |
matched_has_accepted boolean, |
20120 | 20120 |
"Accepted_family__@TNRS__@vegpath.org" text, |
20121 | 20121 |
"Accepted_species[_binomial]__@TNRS__@vegpath.org" text, |
20122 |
"__accepted_{genus,specific_epithet}" text[], |
|
20122 |
"__accepted_{genus,specific_epithet,infra_{rank,epithet}}" text[],
|
|
20123 | 20123 |
"[accepted_]genus__@DwC__@vegpath.org" text, |
20124 | 20124 |
"[accepted_]specificEpithet__@DwC__@vegpath.org" text, |
20125 | 20125 |
"[accepted_]morphospecies[_binomial]__@Brad__.TNRS@vegpath.org" text, |
... | ... | |
20147 | 20147 |
END)))), |
20148 | 20148 |
CONSTRAINT "Accepted_species[_binomial]__@TNRS__@vegpath.org" CHECK ((NOT ("Accepted_species[_binomial]__@TNRS__@vegpath.org" IS DISTINCT FROM rtrim("*Accepted_name_species", ' '::text)))), |
20149 | 20149 |
CONSTRAINT "[accepted_]Infraspecific_rank[_abbr]__@TNRS__@vegpath.org" CHECK ((NOT ("[accepted_]Infraspecific_rank[_abbr]__@TNRS__@vegpath.org" IS DISTINCT FROM "__accepted_infraspecific_{rank,epithet}"[1]))), |
20150 |
CONSTRAINT "[accepted_]genus__@DwC__@vegpath.org" CHECK ((NOT ("[accepted_]genus__@DwC__@vegpath.org" IS DISTINCT FROM COALESCE("__accepted_{genus,specific_epithet}"[1], |
|
20150 |
CONSTRAINT "[accepted_]genus__@DwC__@vegpath.org" CHECK ((NOT ("[accepted_]genus__@DwC__@vegpath.org" IS DISTINCT FROM COALESCE("__accepted_{genus,specific_epithet,infra_{rank,epithet}}"[1],
|
|
20151 | 20151 |
CASE |
20152 | 20152 |
WHEN ("*Accepted_name_rank" = 'genus'::text) THEN "*Accepted_name" |
20153 | 20153 |
ELSE NULL::text |
... | ... | |
20160 | 20160 |
ELSE "Accepted_species[_binomial]__@TNRS__@vegpath.org" |
20161 | 20161 |
END))), |
20162 | 20162 |
CONSTRAINT "[accepted_]scientificName[_with_author]__@DwC__@vegpath.org" CHECK ((NOT ("[accepted_]scientificName[_with_author]__@DwC__@vegpath.org" IS DISTINCT FROM ("*Accepted_name" || COALESCE((' '::text || "*Accepted_name_author"), ''::text))))), |
20163 |
CONSTRAINT "[accepted_]specificEpithet__@DwC__@vegpath.org" CHECK ((NOT ("[accepted_]specificEpithet__@DwC__@vegpath.org" IS DISTINCT FROM "__accepted_{genus,specific_epithet}"[2]))), |
|
20163 |
CONSTRAINT "[accepted_]specificEpithet__@DwC__@vegpath.org" CHECK ((NOT ("[accepted_]specificEpithet__@DwC__@vegpath.org" IS DISTINCT FROM "__accepted_{genus,specific_epithet,infra_{rank,epithet}}"[2]))),
|
|
20164 | 20164 |
CONSTRAINT "[matched_]scientificName[_with_author]__@DwC__@vegpath.org" CHECK ((NOT ("[matched_]scientificName[_with_author]__@DwC__@vegpath.org" IS DISTINCT FROM ("matched~Name[_no_author]___@TNRS__@vegpath.org" || COALESCE((' '::text || "*Name_matched_author"), ''::text))))), |
20165 | 20165 |
CONSTRAINT "[matched_]species[_binomial]~(-Accepted_-)__@TNRS__@vegpath.org" CHECK ((NOT ("[matched_]species[_binomial]~(-Accepted_-)__@TNRS__@vegpath.org" IS DISTINCT FROM (("*Genus_matched" || ' '::text) || "*Specific_epithet_matched")))), |
20166 | 20166 |
CONSTRAINT "[parsed_]morphospecies[_suffix]__@Brad__.morphosp@vegpath.org" CHECK ((NOT ("[parsed_]morphospecies[_suffix]__@Brad__.morphosp@vegpath.org" IS DISTINCT FROM "*Unmatched_terms"))), |
... | ... | |
20223 | 20223 |
CONSTRAINT "[scrubbed_]taxonomicStatus__@DwC__@vegpath.org" CHECK ((NOT ("[scrubbed_]taxonomicStatus__@DwC__@vegpath.org" IS DISTINCT FROM map_taxonomic_status("*Taxonomic_status", "*Accepted_name")))), |
20224 | 20224 |
CONSTRAINT __accepted_infraspecific_label CHECK ((NOT (__accepted_infraspecific_label IS DISTINCT FROM ltrim(NULLIF(remove_prefix("Accepted_species[_binomial]__@TNRS__@vegpath.org", "*Accepted_name", require := true, case_sensitive := false), ''::text), ' '::text)))), |
20225 | 20225 |
CONSTRAINT "__accepted_infraspecific_{rank,epithet}" CHECK ((NOT ("__accepted_infraspecific_{rank,epithet}" IS DISTINCT FROM regexp_split_to_array(__accepted_infraspecific_label, ' '::text)))), |
20226 |
CONSTRAINT "__accepted_{genus,specific_epithet}" CHECK ((NOT ("__accepted_{genus,specific_epithet}" IS DISTINCT FROM regexp_split_to_array("*Accepted_name", ' '::text)))),
|
|
20226 |
CONSTRAINT "__accepted_{genus,specific_epithet,infra_{rank,epithet}}" CHECK ((NOT ("__accepted_{genus,specific_epithet,infra_{rank,epithet}}" IS DISTINCT FROM regexp_split_to_array("*Accepted_name", ' '::text)))),
|
|
20227 | 20227 |
CONSTRAINT matched_has_accepted CHECK ((NOT (matched_has_accepted IS DISTINCT FROM ("*Accepted_name" IS NOT NULL)))), |
20228 | 20228 |
CONSTRAINT "matched~Name[_no_author]___@TNRS__@vegpath.org" CHECK ((NOT ("matched~Name[_no_author]___@TNRS__@vegpath.org" IS DISTINCT FROM NULLIF("*Name_matched", 'No suitable matches found.'::text)))) |
20229 | 20229 |
); |
... | ... | |
20416 | 20416 |
|
20417 | 20417 |
|
20418 | 20418 |
-- |
20419 |
-- Name: COLUMN taxon_match."__accepted_{genus,specific_epithet}"; Type: COMMENT; Schema: TNRS; Owner: - |
|
20419 |
-- Name: COLUMN taxon_match."__accepted_{genus,specific_epithet,infra_{rank,epithet}}"; Type: COMMENT; Schema: TNRS; Owner: -
|
|
20420 | 20420 |
-- |
20421 | 20421 |
|
20422 |
COMMENT ON COLUMN taxon_match."__accepted_{genus,specific_epithet}" IS ' |
|
20422 |
COMMENT ON COLUMN taxon_match."__accepted_{genus,specific_epithet,infra_{rank,epithet}}" IS '
|
|
20423 | 20423 |
= regexp_split_to_array("*Accepted_name", '' ''::text) |
20424 | 20424 |
|
20425 | 20425 |
derived column |
20426 | 20426 |
|
20427 | 20427 |
to modify expr: |
20428 |
SELECT util.derived_col_update(((''"TNRS".taxon_match'', ''__accepted_{genus,specific_epithet}'')::util.col, $$regexp_split_to_array("*Accepted_name", '' ''::text)$$)::util.derived_col_def); |
|
20428 |
SELECT util.derived_col_update(((''"TNRS".taxon_match'', ''__accepted_{genus,specific_epithet,infra_{rank,epithet}}'')::util.col, $$regexp_split_to_array("*Accepted_name", '' ''::text)$$)::util.derived_col_def);
|
|
20429 | 20429 |
SELECT util.derived_cols_populate(''"TNRS".taxon_match''::regclass); |
20430 | 20430 |
|
20431 | 20431 |
to rename: |
... | ... | |
20440 | 20440 |
-- |
20441 | 20441 |
|
20442 | 20442 |
COMMENT ON COLUMN taxon_match."[accepted_]genus__@DwC__@vegpath.org" IS ' |
20443 |
= COALESCE("__accepted_{genus,specific_epithet}"[1], |
|
20443 |
= COALESCE("__accepted_{genus,specific_epithet,infra_{rank,epithet}}"[1],
|
|
20444 | 20444 |
CASE |
20445 | 20445 |
WHEN ("*Accepted_name_rank" = ''genus''::text) THEN "*Accepted_name" |
20446 | 20446 |
ELSE NULL::text |
... | ... | |
20449 | 20449 |
derived column |
20450 | 20450 |
|
20451 | 20451 |
to modify expr: |
20452 |
SELECT util.derived_col_update(((''"TNRS".taxon_match'', ''[accepted_]genus__@DwC__@vegpath.org'')::util.col, $$COALESCE("__accepted_{genus,specific_epithet}"[1], |
|
20452 |
SELECT util.derived_col_update(((''"TNRS".taxon_match'', ''[accepted_]genus__@DwC__@vegpath.org'')::util.col, $$COALESCE("__accepted_{genus,specific_epithet,infra_{rank,epithet}}"[1],
|
|
20453 | 20453 |
CASE |
20454 | 20454 |
WHEN ("*Accepted_name_rank" = ''genus''::text) THEN "*Accepted_name" |
20455 | 20455 |
ELSE NULL::text |
... | ... | |
20468 | 20468 |
-- |
20469 | 20469 |
|
20470 | 20470 |
COMMENT ON COLUMN taxon_match."[accepted_]specificEpithet__@DwC__@vegpath.org" IS ' |
20471 |
= "__accepted_{genus,specific_epithet}"[2] |
|
20471 |
= "__accepted_{genus,specific_epithet,infra_{rank,epithet}}"[2]
|
|
20472 | 20472 |
|
20473 | 20473 |
derived column |
20474 | 20474 |
|
20475 | 20475 |
to modify expr: |
20476 |
SELECT util.derived_col_update(((''"TNRS".taxon_match'', ''[accepted_]specificEpithet__@DwC__@vegpath.org'')::util.col, $$"__accepted_{genus,specific_epithet}"[2]$$)::util.derived_col_def); |
|
20476 |
SELECT util.derived_col_update(((''"TNRS".taxon_match'', ''[accepted_]specificEpithet__@DwC__@vegpath.org'')::util.col, $$"__accepted_{genus,specific_epithet,infra_{rank,epithet}}"[2]$$)::util.derived_col_def);
|
|
20477 | 20477 |
SELECT util.derived_cols_populate(''"TNRS".taxon_match''::regclass); |
20478 | 20478 |
|
20479 | 20479 |
to rename: |
... | ... | |
20971 | 20971 |
taxon_match.matched_has_accepted, |
20972 | 20972 |
taxon_match."Accepted_family__@TNRS__@vegpath.org", |
20973 | 20973 |
taxon_match."Accepted_species[_binomial]__@TNRS__@vegpath.org", |
20974 |
taxon_match."__accepted_{genus,specific_epithet}", |
|
20974 |
taxon_match."__accepted_{genus,specific_epithet,infra_{rank,epithet}}" AS "__accepted_{genus,specific_epithet}",
|
|
20975 | 20975 |
taxon_match."[accepted_]genus__@DwC__@vegpath.org", |
20976 | 20976 |
taxon_match."[accepted_]specificEpithet__@DwC__@vegpath.org", |
20977 | 20977 |
taxon_match."[accepted_]morphospecies[_binomial]__@Brad__.TNRS@vegpath.org", |
Also available in: Unified diff
inputs/.TNRS/schema.sql: taxon_match."__accepted_{genus,specific_epithet}": renamed to "__accepted_{genus,specific_epithet,infra_{rank,epithet}}" since this now includes these other ranks as well