Revision 4727
Added by Aaron Marcuse-Kubitza over 12 years ago
inputs/MT/Specimen/VegBIEN.csv | ||
---|---|---|
13 | 13 |
family,/location/locationevent/taxonoccurrence/taxondetermination[!isoriginal]/*_id/taxonpath/family, |
14 | 14 |
genus,/location/locationevent/taxonoccurrence/taxondetermination[!isoriginal]/*_id/taxonpath/genus, |
15 | 15 |
locality,/location/locationnarrative/_merge/1, |
16 |
continent,"/location/locationplace/namedplace_id/_forEach:[in:[county,stateProvince,country,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=continent]/placename",
|
|
16 |
continent,/location/locationplace/*_id/placepath/continent,
|
|
17 | 17 |
basisOfRecord,,** No join mapping for basisOfRecord ** |
18 | 18 |
countryCode,,** No join mapping for countryCode ** |
19 | 19 |
datasetName,,** No join mapping for datasetName ** |
inputs/MT/Specimen/test.xml.ref | ||
---|---|---|
64 | 64 |
</taxonoccurrence> |
65 | 65 |
</locationevent> |
66 | 66 |
<locationnarrative>$locality</locationnarrative> |
67 |
<locationplace> |
|
68 |
<namedplace_id> |
|
69 |
<namedplace> |
|
70 |
<rank>county</rank> |
|
71 |
<parent_id> |
|
72 |
<namedplace> |
|
73 |
<rank>stateProvince</rank> |
|
74 |
<parent_id> |
|
75 |
<namedplace> |
|
76 |
<rank>country</rank> |
|
77 |
<parent_id> |
|
78 |
<namedplace> |
|
79 |
<rank>continent</rank> |
|
80 |
<placename>$continent</placename> |
|
81 |
</namedplace> |
|
82 |
</parent_id> |
|
83 |
</namedplace> |
|
84 |
</parent_id> |
|
85 |
</namedplace> |
|
86 |
</parent_id> |
|
87 |
</namedplace> |
|
88 |
</namedplace_id> |
|
89 |
</locationplace> |
|
67 |
<locationplace><placepath_id><placepath><continent>$continent</continent></placepath></placepath_id></locationplace> |
|
90 | 68 |
</location> |
91 | 69 |
</path> |
92 | 70 |
</_simplifyPath> |
inputs/XAL/Specimen/VegBIEN.csv | ||
---|---|---|
45 | 45 |
darwin:MaximumDepth,"/location/locationevent/waterdepth/_avg/max/_units:[default=m,to=m,to=]/value/_replace:[""\bca\.?""=]/value", |
46 | 46 |
darwin:MinimumDepth,"/location/locationevent/waterdepth/_avg/min/_units:[default=m,to=m,to=]/value/_replace:[""\bca\.?""=]/value", |
47 | 47 |
darwin:Locality,/location/locationnarrative/_merge/1, |
48 |
darwin:County,"/location/locationplace/namedplace_id/_forEach:[in:[],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=county]/placename",
|
|
49 |
darwin:StateProvince,"/location/locationplace/namedplace_id/_forEach:[in:[county,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=stateProvince]/placename",
|
|
50 |
darwin:Country,"/location/locationplace/namedplace_id/_forEach:[in:[county,stateProvince,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=country]/placename",
|
|
51 |
darwin:ContinentOcean,"/location/locationplace/namedplace_id/_forEach:[in:[county,stateProvince,country,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=continent]/placename",
|
|
48 |
darwin:ContinentOcean,/location/locationplace/*_id/placepath/continent,
|
|
49 |
darwin:Country,/location/locationplace/*_id/placepath/country,
|
|
50 |
darwin:County,/location/locationplace/*_id/placepath/county,
|
|
51 |
darwin:StateProvince,/location/locationplace/*_id/placepath/stateprovince,
|
|
52 | 52 |
darwin:BasisOfRecord,,** No join mapping for BasisOfRecord ** |
53 | 53 |
darwin:DateLastModified,,** No join mapping for dcterms:modified ** |
54 | 54 |
darwin:JulianDay,,** No join mapping for day ** |
inputs/NY/Specimen/VegBIEN.csv | ||
---|---|---|
50 | 50 |
Substrate,"/location/locationnarrative/_merge/1/_join/2/_label[label=""substrate""]/value", |
51 | 51 |
Vegetation,"/location/locationnarrative/_merge/1/_join/3/_label[label=""vegetation""]/value", |
52 | 52 |
Habitat,"/location/locationnarrative/_merge/3/_label[label=""habitat""]/value","Brad: Free-text description of vegetation community where collected, frequently redundane wrt 'Vegetation'. Bob, Nick: keep as user defined or create special element?" |
53 |
County,"/location/locationplace/namedplace_id/_forEach:[in:[],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=county]/placename",
|
|
54 |
StateProvince,"/location/locationplace/namedplace_id/_forEach:[in:[county,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=stateProvince]/placename",
|
|
55 |
Country,"/location/locationplace/namedplace_id/_forEach:[in:[county,stateProvince,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=country]/placename",
|
|
56 |
ContinentOcean,"/location/locationplace/namedplace_id/_forEach:[in:[county,stateProvince,country,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=continent]/placename",
|
|
53 |
ContinentOcean,/location/locationplace/*_id/placepath/continent,
|
|
54 |
Country,/location/locationplace/*_id/placepath/country,
|
|
55 |
County,/location/locationplace/*_id/placepath/county,
|
|
56 |
StateProvince,/location/locationplace/*_id/placepath/stateprovince,
|
|
57 | 57 |
BasisOfRecord,,** No join mapping for BasisOfRecord ** |
58 | 58 |
CollectorNumber,,"** No join mapping for OMIT ** Not used [1], so does not need to be mapped. |
59 | 59 |
|
inputs/NY/Specimen/test.xml.ref | ||
---|---|---|
305 | 305 |
</_merge> |
306 | 306 |
</locationnarrative> |
307 | 307 |
<locationplace> |
308 |
<namedplace_id> |
|
309 |
<namedplace> |
|
310 |
<rank>county</rank> |
|
311 |
<placename>$County</placename> |
|
312 |
<parent_id> |
|
313 |
<namedplace> |
|
314 |
<rank>stateProvince</rank> |
|
315 |
<placename>$StateProvince</placename> |
|
316 |
<parent_id> |
|
317 |
<namedplace> |
|
318 |
<rank>country</rank> |
|
319 |
<placename>$Country</placename> |
|
320 |
<parent_id> |
|
321 |
<namedplace> |
|
322 |
<rank>continent</rank> |
|
323 |
<placename>$ContinentOcean</placename> |
|
324 |
</namedplace> |
|
325 |
</parent_id> |
|
326 |
</namedplace> |
|
327 |
</parent_id> |
|
328 |
</namedplace> |
|
329 |
</parent_id> |
|
330 |
</namedplace> |
|
331 |
</namedplace_id> |
|
308 |
<placepath_id> |
|
309 |
<placepath> |
|
310 |
<continent>$ContinentOcean</continent> |
|
311 |
<country>$Country</country> |
|
312 |
<county>$County</county> |
|
313 |
<stateprovince>$StateProvince</stateprovince> |
|
314 |
</placepath> |
|
315 |
</placepath_id> |
|
332 | 316 |
</locationplace> |
333 | 317 |
</location> |
334 | 318 |
</path> |
335 | 319 |
</_simplifyPath> |
336 | 320 |
</VegBIEN> |
337 |
Inserted 32 new rows into database |
|
321 |
Inserted 27 new rows into database |
inputs/UNCC/Specimen/VegBIEN.csv | ||
---|---|---|
31 | 31 |
collector3,/location/locationevent/taxonoccurrence/verbatimcollectorname/_join/4, |
32 | 32 |
locality,/location/locationnarrative/_merge/1, |
33 | 33 |
habitat,"/location/locationnarrative/_merge/3/_label[label=""habitat""]/value","Brad: Free-text description of vegetation community where collected, frequently redundane wrt 'Vegetation'. Bob, Nick: keep as user defined or create special element?" |
34 |
county,"/location/locationplace/namedplace_id/_forEach:[in:[],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=county]/placename",
|
|
35 |
state,"/location/locationplace/namedplace_id/_forEach:[in:[county,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=stateProvince]/placename",
|
|
36 |
country,"/location/locationplace/namedplace_id/_forEach:[in:[county,stateProvince,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=country]/placename",
|
|
34 |
country,/location/locationplace/*_id/placepath/country,
|
|
35 |
county,/location/locationplace/*_id/placepath/county,
|
|
36 |
state,/location/locationplace/*_id/placepath/stateprovince,
|
|
37 | 37 |
filler,,"** No join mapping for filler ** Where used, same as family" |
38 | 38 |
flower,,"** No join mapping for reproductiveCondition/_map:[A=*,I=*,M=*]/value ** Main values are A, I, and M. What do they mean?" |
39 | 39 |
fruit,,"** No join mapping for reproductiveCondition/_map:[A=*,I=*,M=*]/value ** Main values are A, I, and M. What do they mean?" |
inputs/UNCC/Specimen/test.xml.ref | ||
---|---|---|
123 | 123 |
</_merge> |
124 | 124 |
</locationnarrative> |
125 | 125 |
<locationplace> |
126 |
<namedplace_id> |
|
127 |
<namedplace> |
|
128 |
<rank>county</rank> |
|
129 |
<placename>$county</placename> |
|
130 |
<parent_id> |
|
131 |
<namedplace> |
|
132 |
<rank>stateProvince</rank> |
|
133 |
<placename>$state</placename> |
|
134 |
<parent_id> |
|
135 |
<namedplace> |
|
136 |
<rank>country</rank> |
|
137 |
<placename>$country</placename> |
|
138 |
</namedplace> |
|
139 |
</parent_id> |
|
140 |
</namedplace> |
|
141 |
</parent_id> |
|
142 |
</namedplace> |
|
143 |
</namedplace_id> |
|
126 |
<placepath_id> |
|
127 |
<placepath> |
|
128 |
<country>$country</country> |
|
129 |
<county>$county</county> |
|
130 |
<stateprovince>$state</stateprovince> |
|
131 |
</placepath> |
|
132 |
</placepath_id> |
|
144 | 133 |
</locationplace> |
145 | 134 |
</location> |
146 | 135 |
</path> |
147 | 136 |
</_simplifyPath> |
148 | 137 |
</VegBIEN> |
149 |
Inserted 21 new rows into database |
|
138 |
Inserted 20 new rows into database |
inputs/ACAD/Specimen/VegBIEN.csv | ||
---|---|---|
36 | 36 |
catalogNumber,"/location/locationevent/taxonoccurrence/voucher/*_id/specimenreplicate/catalognumber_dwc/_if[@name=""if indirect voucher""]/then", |
37 | 37 |
locality,/location/locationnarrative/_merge/1, |
38 | 38 |
habitat,"/location/locationnarrative/_merge/3/_label[label=""habitat""]/value","Brad: Free-text description of vegetation community where collected, frequently redundane wrt 'Vegetation'. Bob, Nick: keep as user defined or create special element?" |
39 |
county,"/location/locationplace/namedplace_id/_forEach:[in:[],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=county]/placename",
|
|
40 |
stateProvince,"/location/locationplace/namedplace_id/_forEach:[in:[county,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=stateProvince]/placename",
|
|
41 |
country,"/location/locationplace/namedplace_id/_forEach:[in:[county,stateProvince,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=country]/placename",
|
|
42 |
continent,"/location/locationplace/namedplace_id/_forEach:[in:[county,stateProvince,country,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=continent]/placename",
|
|
39 |
continent,/location/locationplace/*_id/placepath/continent,
|
|
40 |
country,/location/locationplace/*_id/placepath/country,
|
|
41 |
county,/location/locationplace/*_id/placepath/county,
|
|
42 |
stateProvince,/location/locationplace/*_id/placepath/stateprovince,
|
|
43 | 43 |
basisOfRecord,,** No join mapping for basisOfRecord ** |
44 | 44 |
bibliographicCitation,,** No join mapping for dcterms:bibliographicCitation ** |
45 | 45 |
dynamicProperties,,** No join mapping for dynamicProperties ** |
inputs/ACAD/Specimen/test.xml.ref | ||
---|---|---|
113 | 113 |
</_merge> |
114 | 114 |
</locationnarrative> |
115 | 115 |
<locationplace> |
116 |
<namedplace_id> |
|
117 |
<namedplace> |
|
118 |
<rank>county</rank> |
|
119 |
<placename>$county</placename> |
|
120 |
<parent_id> |
|
121 |
<namedplace> |
|
122 |
<rank>stateProvince</rank> |
|
123 |
<placename>$stateProvince</placename> |
|
124 |
<parent_id> |
|
125 |
<namedplace> |
|
126 |
<rank>country</rank> |
|
127 |
<placename>$country</placename> |
|
128 |
<parent_id> |
|
129 |
<namedplace> |
|
130 |
<rank>continent</rank> |
|
131 |
<placename>$continent</placename> |
|
132 |
</namedplace> |
|
133 |
</parent_id> |
|
134 |
</namedplace> |
|
135 |
</parent_id> |
|
136 |
</namedplace> |
|
137 |
</parent_id> |
|
138 |
</namedplace> |
|
139 |
</namedplace_id> |
|
116 |
<placepath_id> |
|
117 |
<placepath> |
|
118 |
<continent>$continent</continent> |
|
119 |
<country>$country</country> |
|
120 |
<county>$county</county> |
|
121 |
<stateprovince>$stateProvince</stateprovince> |
|
122 |
</placepath> |
|
123 |
</placepath_id> |
|
140 | 124 |
</locationplace> |
141 | 125 |
</location> |
142 | 126 |
</path> |
143 | 127 |
</_simplifyPath> |
144 | 128 |
</VegBIEN> |
145 |
Inserted 28 new rows into database |
|
129 |
Inserted 25 new rows into database |
inputs/SALVIAS-CSV/Plot/VegBIEN.csv | ||
---|---|---|
41 | 41 |
soil_texture,/location/locationevent/soilobs/texture, |
42 | 42 |
temp_c,/location/locationevent/temperature, |
43 | 43 |
locality_description,/location/locationnarrative/_merge/1,"Brad: No; this is free text description of locality where plot was situated, same as for DwC. Not a description of vegetation. Most likely='namedPlace.placeDescription' in VB; not sure about VX, again need to ask Nick where locality descriptions live in VX" |
44 |
pol2,"/location/locationplace/namedplace_id/_forEach:[in:[],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=county]/placename",Brad: No pol2=countyParish
|
|
45 |
pol1,"/location/locationplace/namedplace_id/_forEach:[in:[county,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=stateProvince]/placename",Brad: No; pol1=stateProvince
|
|
46 |
country,"/location/locationplace/namedplace_id/_forEach:[in:[county,stateProvince,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=country]/placename",
|
|
47 |
major_geo,"/location/locationplace/namedplace_id/_forEach:[in:[county,stateProvince,country,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=continent]/placename",
|
|
44 |
major_geo,/location/locationplace/*_id/placepath/continent,
|
|
45 |
country,/location/locationplace/*_id/placepath/country,
|
|
46 |
pol2,/location/locationplace/*_id/placepath/county,Brad: No pol2=countyParish
|
|
47 |
pol1,/location/locationplace/*_id/placepath/stateprovince,Brad: No; pol1=stateProvince
|
|
48 | 48 |
slope_aspect,/location/slopeaspect/_alt/1/_compass/value, |
49 | 49 |
slope_gradient,/location/slopegradient/_alt/1, |
50 | 50 |
observation_type,,"** No join mapping for observation_type ** Brad: SALVIAS internal metadata indicating whether the record represents an individual or aggregate observation. Rather than storing, use to decide where to store in VegX.; Aaron: VegX aggregateOrganismObservation table is missing many fields available in individualOrganismObservation, so we're mapping to individualOrganismObservation regardless of observation type" |
inputs/SALVIAS-CSV/Plot/test.xml.ref | ||
---|---|---|
244 | 244 |
</locationevent> |
245 | 245 |
<locationnarrative>$locality_description</locationnarrative> |
246 | 246 |
<locationplace> |
247 |
<namedplace_id> |
|
248 |
<namedplace> |
|
249 |
<rank>county</rank> |
|
250 |
<placename>$pol2</placename> |
|
251 |
<parent_id> |
|
252 |
<namedplace> |
|
253 |
<rank>stateProvince</rank> |
|
254 |
<placename>$pol1</placename> |
|
255 |
<parent_id> |
|
256 |
<namedplace> |
|
257 |
<rank>country</rank> |
|
258 |
<placename>$country</placename> |
|
259 |
<parent_id> |
|
260 |
<namedplace> |
|
261 |
<rank>continent</rank> |
|
262 |
<placename>$major_geo</placename> |
|
263 |
</namedplace> |
|
264 |
</parent_id> |
|
265 |
</namedplace> |
|
266 |
</parent_id> |
|
267 |
</namedplace> |
|
268 |
</parent_id> |
|
269 |
</namedplace> |
|
270 |
</namedplace_id> |
|
247 |
<placepath_id> |
|
248 |
<placepath> |
|
249 |
<continent>$major_geo</continent> |
|
250 |
<country>$country</country> |
|
251 |
<county>$pol2</county> |
|
252 |
<stateprovince>$pol1</stateprovince> |
|
253 |
</placepath> |
|
254 |
</placepath_id> |
|
271 | 255 |
</locationplace> |
272 | 256 |
<slopeaspect><_compass><value>$slope_aspect</value></_compass></slopeaspect> |
273 | 257 |
<slopegradient>$slope_gradient</slopegradient> |
... | ... | |
275 | 259 |
</path> |
276 | 260 |
</_simplifyPath> |
277 | 261 |
</VegBIEN> |
278 |
Inserted 18 new rows into database |
|
262 |
Inserted 16 new rows into database |
inputs/CVS/Organism/VegBIEN.csv | ||
---|---|---|
10 | 10 |
%cover,/location/locationevent/taxonoccurrence/aggregateoccurrence/cover, |
11 | 11 |
currentTaxonName sec Weakley 2006,/location/locationevent/taxonoccurrence/authortaxoncode/_alt/2/_alt/3, |
12 | 12 |
currentTaxonName sec Weakley 2006,/location/locationevent/taxonoccurrence/taxondetermination[!isoriginal]/*_id/taxonpath/scientificname, |
13 |
county,"/location/locationplace/namedplace_id/_forEach:[in:[],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=county]/placename",
|
|
14 |
state,"/location/locationplace/namedplace_id/_forEach:[in:[county,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=stateProvince]/placename",
|
|
13 |
county,/location/locationplace/*_id/placepath/county,
|
|
14 |
state,/location/locationplace/*_id/placepath/stateprovince,
|
|
15 | 15 |
confidentialityStatus,,** No join mapping for confidentialityStatus ** |
16 | 16 |
realLatitude,,** No join mapping for OMIT ** |
17 | 17 |
realLongitude,,** No join mapping for OMIT ** |
inputs/CVS/Organism/test.xml.ref | ||
---|---|---|
32 | 32 |
</taxonoccurrence> |
33 | 33 |
</locationevent> |
34 | 34 |
<locationplace> |
35 |
<namedplace_id> |
|
36 |
<namedplace> |
|
37 |
<rank>county</rank> |
|
38 |
<placename>$county</placename> |
|
39 |
<parent_id> |
|
40 |
<namedplace> |
|
41 |
<rank>stateProvince</rank> |
|
42 |
<placename>$state</placename> |
|
43 |
</namedplace> |
|
44 |
</parent_id> |
|
45 |
</namedplace> |
|
46 |
</namedplace_id> |
|
35 |
<placepath_id> |
|
36 |
<placepath> |
|
37 |
<county>$county</county> |
|
38 |
<stateprovince>$state</stateprovince> |
|
39 |
</placepath> |
|
40 |
</placepath_id> |
|
47 | 41 |
</locationplace> |
48 | 42 |
</location> |
49 | 43 |
</path> |
50 | 44 |
</_simplifyPath> |
51 | 45 |
</VegBIEN> |
52 |
Inserted 15 new rows into database |
|
46 |
Inserted 14 new rows into database |
inputs/REMIB/Specimen/VegBIEN.csv | ||
---|---|---|
14 | 14 |
collector,/location/locationevent/taxonoccurrence/verbatimcollectorname, |
15 | 15 |
locality,/location/locationnarrative/_merge/1, |
16 | 16 |
habitat,"/location/locationnarrative/_merge/3/_label[label=""habitat""]/value","Brad: Free-text description of vegetation community where collected, frequently redundane wrt 'Vegetation'. Bob, Nick: keep as user defined or create special element?" |
17 |
county,"/location/locationplace/namedplace_id/_forEach:[in:[],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=county]/placename",
|
|
18 |
state,"/location/locationplace/namedplace_id/_forEach:[in:[county,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=stateProvince]/placename",
|
|
19 |
country,"/location/locationplace/namedplace_id/_forEach:[in:[county,stateProvince,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=country]/placename",
|
|
17 |
country,/location/locationplace/*_id/placepath/country,
|
|
18 |
county,/location/locationplace/*_id/placepath/county,
|
|
19 |
state,/location/locationplace/*_id/placepath/stateprovince,
|
|
20 | 20 |
lat_min,,** No join mapping for lat_min ** |
21 | 21 |
lat_sec,,** No join mapping for lat_sec ** |
22 | 22 |
long_min,,** No join mapping for long_min ** |
inputs/REMIB/Specimen/test.xml.ref | ||
---|---|---|
85 | 85 |
</_merge> |
86 | 86 |
</locationnarrative> |
87 | 87 |
<locationplace> |
88 |
<namedplace_id> |
|
89 |
<namedplace> |
|
90 |
<rank>county</rank> |
|
91 |
<placename>$county</placename> |
|
92 |
<parent_id> |
|
93 |
<namedplace> |
|
94 |
<rank>stateProvince</rank> |
|
95 |
<placename>$state</placename> |
|
96 |
<parent_id> |
|
97 |
<namedplace> |
|
98 |
<rank>country</rank> |
|
99 |
<placename>$country</placename> |
|
100 |
</namedplace> |
|
101 |
</parent_id> |
|
102 |
</namedplace> |
|
103 |
</parent_id> |
|
104 |
</namedplace> |
|
105 |
</namedplace_id> |
|
88 |
<placepath_id> |
|
89 |
<placepath> |
|
90 |
<country>$country</country> |
|
91 |
<county>$county</county> |
|
92 |
<stateprovince>$state</stateprovince> |
|
93 |
</placepath> |
|
94 |
</placepath_id> |
|
106 | 95 |
</locationplace> |
107 | 96 |
</location> |
108 | 97 |
</path> |
109 | 98 |
</_simplifyPath> |
110 | 99 |
</VegBIEN> |
111 |
Inserted 25 new rows into database |
|
100 |
Inserted 22 new rows into database |
inputs/CTFS/Plot/VegBIEN.csv | ||
---|---|---|
13 | 13 |
PlotID,"/location/locationevent/_if[@name=""if subplot""]/then/_if[@name=""if event""]/then/parent_id/locationevent/*_id/location/sourceaccessioncode", |
14 | 14 |
DescriptionOfSite,/location/locationnarrative/_merge/1, |
15 | 15 |
LocationName,/location/locationnarrative/_merge/1, |
16 |
CountryName,"/location/locationplace/namedplace_id/_forEach:[in:[county,stateProvince,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=country]/placename",
|
|
16 |
CountryName,/location/locationplace/*_id/placepath/country,
|
|
17 | 17 |
CountryID,,** No join mapping for CountryID ** |
18 | 18 |
ReferenceX,,** No join mapping for ReferenceX ** Rarely used |
19 | 19 |
ReferenceY,,** No join mapping for ReferenceY ** Rarely used |
inputs/CTFS/Plot/test.xml.ref | ||
---|---|---|
36 | 36 |
<1>$LocationName</1> |
37 | 37 |
</_alt> |
38 | 38 |
</locationnarrative> |
39 |
<locationplace> |
|
40 |
<namedplace_id> |
|
41 |
<namedplace> |
|
42 |
<rank>county</rank> |
|
43 |
<parent_id> |
|
44 |
<namedplace> |
|
45 |
<rank>stateProvince</rank> |
|
46 |
<parent_id> |
|
47 |
<namedplace> |
|
48 |
<rank>country</rank> |
|
49 |
<placename>$CountryName</placename> |
|
50 |
</namedplace> |
|
51 |
</parent_id> |
|
52 |
</namedplace> |
|
53 |
</parent_id> |
|
54 |
</namedplace> |
|
55 |
</namedplace_id> |
|
56 |
</locationplace> |
|
39 |
<locationplace><placepath_id><placepath><country>$CountryName</country></placepath></placepath_id></locationplace> |
|
57 | 40 |
</location> |
58 | 41 |
</path> |
59 | 42 |
</_simplifyPath> |
inputs/FIA/Organism/VegBIEN.csv | ||
---|---|---|
14 | 14 |
TreeTag,"/location/locationevent/taxonoccurrence/aggregateoccurrence/plantobservation/stemobservation/stemtag[""""/iscurrent/_alt/2=true]/tag",Quotes sort it before tag2 |
15 | 15 |
Genus,/location/locationevent/taxonoccurrence/taxondetermination[!isoriginal]/*_id/taxonpath/genus, |
16 | 16 |
SpecificEpithet,/location/locationevent/taxonoccurrence/taxondetermination[!isoriginal]/*_id/taxonpath/species, |
17 |
County,"/location/locationplace/namedplace_id/_forEach:[in:[],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=county]/placename",
|
|
18 |
StateProvince,"/location/locationplace/namedplace_id/_forEach:[in:[county,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=stateProvince]/placename",
|
|
17 |
County,/location/locationplace/*_id/placepath/county,
|
|
18 |
StateProvince,/location/locationplace/*_id/placepath/stateprovince,
|
|
19 | 19 |
HOM,,** No join mapping for HOM ** |
inputs/FIA/Organism/test.xml.ref | ||
---|---|---|
72 | 72 |
</taxonoccurrence> |
73 | 73 |
</locationevent> |
74 | 74 |
<locationplace> |
75 |
<namedplace_id> |
|
76 |
<namedplace> |
|
77 |
<rank>county</rank> |
|
78 |
<placename>$County</placename> |
|
79 |
<parent_id> |
|
80 |
<namedplace> |
|
81 |
<rank>stateProvince</rank> |
|
82 |
<placename>$StateProvince</placename> |
|
83 |
</namedplace> |
|
84 |
</parent_id> |
|
85 |
</namedplace> |
|
86 |
</namedplace_id> |
|
75 |
<placepath_id> |
|
76 |
<placepath> |
|
77 |
<county>$County</county> |
|
78 |
<stateprovince>$StateProvince</stateprovince> |
|
79 |
</placepath> |
|
80 |
</placepath_id> |
|
87 | 81 |
</locationplace> |
88 | 82 |
</location> |
89 | 83 |
</path> |
90 | 84 |
</_simplifyPath> |
91 | 85 |
</VegBIEN> |
92 |
Inserted 14 new rows into database |
|
86 |
Inserted 13 new rows into database |
inputs/SALVIAS/plotMetadata/VegBIEN.csv | ||
---|---|---|
42 | 42 |
Temp,/location/locationevent/temperature, |
43 | 43 |
Locality_Description,/location/locationnarrative/_merge/1,"Brad: No; this is free text description of locality where plot was situated, same as for DwC. Not a description of vegetation. Most likely='namedPlace.placeDescription' in VB; not sure about VX, again need to ask Nick where locality descriptions live in VX" |
44 | 44 |
Habitat,"/location/locationnarrative/_merge/3/_label[label=""habitat""]/value","Brad: Free-text description of vegetation community where collected, frequently redundane wrt 'Vegetation'. Bob, Nick: keep as user defined or create special element?" |
45 |
pol2,"/location/locationplace/namedplace_id/_forEach:[in:[],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=county]/placename",Brad: No pol2=countyParish
|
|
46 |
PolDiv1,"/location/locationplace/namedplace_id/_forEach:[in:[county,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=stateProvince]/placename",Brad: No; pol1=stateProvince
|
|
47 |
Country,"/location/locationplace/namedplace_id/_forEach:[in:[county,stateProvince,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=country]/placename",
|
|
48 |
MajorGeo,"/location/locationplace/namedplace_id/_forEach:[in:[county,stateProvince,country,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=continent]/placename",
|
|
45 |
MajorGeo,/location/locationplace/*_id/placepath/continent,
|
|
46 |
Country,/location/locationplace/*_id/placepath/country,
|
|
47 |
pol2,/location/locationplace/*_id/placepath/county,Brad: No pol2=countyParish
|
|
48 |
PolDiv1,/location/locationplace/*_id/placepath/stateprovince,Brad: No; pol1=stateProvince
|
|
49 | 49 |
plot_notes,/location/notespublic, |
50 | 50 |
slope_aspect,/location/slopeaspect/_alt/1/_compass/value, |
51 | 51 |
slope_gradient,/location/slopegradient/_alt/1, |
inputs/SALVIAS/plotMetadata/test.xml.ref | ||
---|---|---|
260 | 260 |
</_merge> |
261 | 261 |
</locationnarrative> |
262 | 262 |
<locationplace> |
263 |
<namedplace_id> |
|
264 |
<namedplace> |
|
265 |
<rank>county</rank> |
|
266 |
<placename>$pol2</placename> |
|
267 |
<parent_id> |
|
268 |
<namedplace> |
|
269 |
<rank>stateProvince</rank> |
|
270 |
<placename>$PolDiv1</placename> |
|
271 |
<parent_id> |
|
272 |
<namedplace> |
|
273 |
<rank>country</rank> |
|
274 |
<placename>$Country</placename> |
|
275 |
<parent_id> |
|
276 |
<namedplace> |
|
277 |
<rank>continent</rank> |
|
278 |
<placename>$MajorGeo</placename> |
|
279 |
</namedplace> |
|
280 |
</parent_id> |
|
281 |
</namedplace> |
|
282 |
</parent_id> |
|
283 |
</namedplace> |
|
284 |
</parent_id> |
|
285 |
</namedplace> |
|
286 |
</namedplace_id> |
|
263 |
<placepath_id> |
|
264 |
<placepath> |
|
265 |
<continent>$MajorGeo</continent> |
|
266 |
<country>$Country</country> |
|
267 |
<county>$pol2</county> |
|
268 |
<stateprovince>$PolDiv1</stateprovince> |
|
269 |
</placepath> |
|
270 |
</placepath_id> |
|
287 | 271 |
</locationplace> |
288 | 272 |
<notespublic>$plot_notes</notespublic> |
289 | 273 |
<slopeaspect><_compass><value>$slope_aspect</value></_compass></slopeaspect> |
... | ... | |
292 | 276 |
</path> |
293 | 277 |
</_simplifyPath> |
294 | 278 |
</VegBIEN> |
295 |
Inserted 25 new rows into database |
|
279 |
Inserted 23 new rows into database |
inputs/U/Specimen/VegBIEN.csv | ||
---|---|---|
25 | 25 |
Newgazett,"/location/locationnarrative/_merge/2/_join/1/_label[label=""gazetteer""]/value/_join/2",Only used in 1 row |
26 | 26 |
Locnotes,/location/locationnarrative/_merge/2/_join/2, |
27 | 27 |
Ecology,"/location/locationnarrative/_merge/3/_label[label=""habitat""]/value","Brad: Free-text description of vegetation community where collected, frequently redundane wrt 'Vegetation'. Bob, Nick: keep as user defined or create special element?" |
28 |
Country,"/location/locationplace/namedplace_id/_forEach:[in:[county,stateProvince,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=country]/placename",
|
|
28 |
Country,/location/locationplace/*_id/placepath/country,
|
|
29 | 29 |
Alt,,** No join mapping for Alt ** What is this? |
30 | 30 |
Alt2,,** No join mapping for Alt2 ** What is this? |
31 | 31 |
Coorsyst,,** No join mapping for Coorsyst ** |
inputs/U/Specimen/test.xml.ref | ||
---|---|---|
125 | 125 |
</3> |
126 | 126 |
</_merge> |
127 | 127 |
</locationnarrative> |
128 |
<locationplace> |
|
129 |
<namedplace_id> |
|
130 |
<namedplace> |
|
131 |
<rank>county</rank> |
|
132 |
<parent_id> |
|
133 |
<namedplace> |
|
134 |
<rank>stateProvince</rank> |
|
135 |
<parent_id> |
|
136 |
<namedplace> |
|
137 |
<rank>country</rank> |
|
138 |
<placename>$Country</placename> |
|
139 |
</namedplace> |
|
140 |
</parent_id> |
|
141 |
</namedplace> |
|
142 |
</parent_id> |
|
143 |
</namedplace> |
|
144 |
</namedplace_id> |
|
145 |
</locationplace> |
|
128 |
<locationplace><placepath_id><placepath><country>$Country</country></placepath></placepath_id></locationplace> |
|
146 | 129 |
</location> |
147 | 130 |
</path> |
148 | 131 |
</_simplifyPath> |
inputs/ARIZ/Specimen/VegBIEN.csv | ||
---|---|---|
56 | 56 |
MaximumDepthInMeters,"/location/locationevent/waterdepth/_avg/max/_units:[default=m,to=m,to=]/value/_replace:[""\bca\.?""=]/value", |
57 | 57 |
MinimumDepthInMeters,"/location/locationevent/waterdepth/_avg/min/_units:[default=m,to=m,to=]/value/_replace:[""\bca\.?""=]/value", |
58 | 58 |
Locality,/location/locationnarrative/_merge/1, |
59 |
County,"/location/locationplace/namedplace_id/_forEach:[in:[],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=county]/placename",
|
|
60 |
StateProvince,"/location/locationplace/namedplace_id/_forEach:[in:[county,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=stateProvince]/placename",
|
|
61 |
Country,"/location/locationplace/namedplace_id/_forEach:[in:[county,stateProvince,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=country]/placename",
|
|
62 |
ContinentOcean,"/location/locationplace/namedplace_id/_forEach:[in:[county,stateProvince,country,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=continent]/placename",
|
|
59 |
ContinentOcean,/location/locationplace/*_id/placepath/continent,
|
|
60 |
Country,/location/locationplace/*_id/placepath/country,
|
|
61 |
County,/location/locationplace/*_id/placepath/county,
|
|
62 |
StateProvince,/location/locationplace/*_id/placepath/stateprovince,
|
|
63 | 63 |
AgeClass,,** No join mapping for lifeStage ** |
64 | 64 |
BasisOfRecord,,** No join mapping for BasisOfRecord ** |
65 | 65 |
DateLastModified,,** No join mapping for dcterms:modified ** |
inputs/ARIZ/Specimen/test.xml.ref | ||
---|---|---|
312 | 312 |
</locationevent> |
313 | 313 |
<locationnarrative>$Locality</locationnarrative> |
314 | 314 |
<locationplace> |
315 |
<namedplace_id> |
|
316 |
<namedplace> |
|
317 |
<rank>county</rank> |
|
318 |
<placename>$County</placename> |
|
319 |
<parent_id> |
|
320 |
<namedplace> |
|
321 |
<rank>stateProvince</rank> |
|
322 |
<placename>$StateProvince</placename> |
|
323 |
<parent_id> |
|
324 |
<namedplace> |
|
325 |
<rank>country</rank> |
|
326 |
<placename>$Country</placename> |
|
327 |
<parent_id> |
|
328 |
<namedplace> |
|
329 |
<rank>continent</rank> |
|
330 |
<placename>$ContinentOcean</placename> |
|
331 |
</namedplace> |
|
332 |
</parent_id> |
|
333 |
</namedplace> |
|
334 |
</parent_id> |
|
335 |
</namedplace> |
|
336 |
</parent_id> |
|
337 |
</namedplace> |
|
338 |
</namedplace_id> |
|
315 |
<placepath_id> |
|
316 |
<placepath> |
|
317 |
<continent>$ContinentOcean</continent> |
|
318 |
<country>$Country</country> |
|
319 |
<county>$County</county> |
|
320 |
<stateprovince>$StateProvince</stateprovince> |
|
321 |
</placepath> |
|
322 |
</placepath_id> |
|
339 | 323 |
</locationplace> |
340 | 324 |
</location> |
341 | 325 |
</path> |
342 | 326 |
</_simplifyPath> |
343 | 327 |
</VegBIEN> |
344 |
Inserted 29 new rows into database |
|
328 |
Inserted 28 new rows into database |
inputs/GBIF/Specimen/test.xml.ref | ||
---|---|---|
183 | 183 |
</locationevent> |
184 | 184 |
<locationnarrative>$Locality</locationnarrative> |
185 | 185 |
<locationplace> |
186 |
<namedplace_id> |
|
187 |
<namedplace> |
|
188 |
<rank>county</rank> |
|
189 |
<placename>$County</placename> |
|
190 |
<parent_id> |
|
191 |
<namedplace> |
|
192 |
<rank>stateProvince</rank> |
|
193 |
<placename>$StateProvince</placename> |
|
194 |
<parent_id> |
|
195 |
<namedplace> |
|
196 |
<rank>country</rank> |
|
197 |
<placename>$Country</placename> |
|
198 |
</namedplace> |
|
199 |
</parent_id> |
|
200 |
</namedplace> |
|
201 |
</parent_id> |
|
202 |
</namedplace> |
|
203 |
</namedplace_id> |
|
186 |
<placepath_id> |
|
187 |
<placepath> |
|
188 |
<country>$Country</country> |
|
189 |
<county>$County</county> |
|
190 |
<stateprovince>$StateProvince</stateprovince> |
|
191 |
</placepath> |
|
192 |
</placepath_id> |
|
204 | 193 |
</locationplace> |
205 | 194 |
</location> |
206 | 195 |
</path> |
inputs/NCU-NCSC/Specimen/test.xml.ref | ||
---|---|---|
66 | 66 |
</taxonoccurrence> |
67 | 67 |
</locationevent> |
68 | 68 |
<locationplace> |
69 |
<namedplace_id> |
|
70 |
<namedplace> |
|
71 |
<rank>county</rank> |
|
72 |
<placename>$County</placename> |
|
73 |
<parent_id> |
|
74 |
<namedplace> |
|
75 |
<rank>stateProvince</rank> |
|
76 |
<placename>$State</placename> |
|
77 |
<parent_id> |
|
78 |
<namedplace> |
|
79 |
<rank>country</rank> |
|
80 |
<placename>$Country</placename> |
|
81 |
</namedplace> |
|
82 |
</parent_id> |
|
83 |
</namedplace> |
|
84 |
</parent_id> |
|
85 |
</namedplace> |
|
86 |
</namedplace_id> |
|
69 |
<placepath_id> |
|
70 |
<placepath> |
|
71 |
<country>$Country</country> |
|
72 |
<county>$County</county> |
|
73 |
<stateprovince>$State</stateprovince> |
|
74 |
</placepath> |
|
75 |
</placepath_id> |
|
87 | 76 |
</locationplace> |
88 | 77 |
</location> |
89 | 78 |
</path> |
90 | 79 |
</_simplifyPath> |
91 | 80 |
</VegBIEN> |
92 |
Inserted 26 new rows into database |
|
81 |
Inserted 23 new rows into database |
inputs/SpeciesLink/Specimen/test.xml.ref | ||
---|---|---|
559 | 559 |
</_alt> |
560 | 560 |
</locationnarrative> |
561 | 561 |
<locationplace> |
562 |
<namedplace_id> |
|
563 |
<namedplace> |
|
564 |
<rank>county</rank> |
|
565 |
<placename> |
|
562 |
<placepath_id> |
|
563 |
<placepath> |
|
564 |
<continent> |
|
566 | 565 |
<_alt> |
566 |
<0>$conceptual_darwin_2003_1_0_ContinentOcean</0> |
|
567 |
<1>$dwc_dwcore_Continent</1> |
|
568 |
<2>$dwc_terms_continent</2> |
|
569 |
</_alt> |
|
570 |
</continent> |
|
571 |
<country> |
|
572 |
<_alt> |
|
573 |
<0>$conceptual_darwin_2003_1_0_Country</0> |
|
574 |
<1>$dwc_dwcore_Country</1> |
|
575 |
<2>$dwc_terms_country</2> |
|
576 |
</_alt> |
|
577 |
</country> |
|
578 |
<county> |
|
579 |
<_alt> |
|
567 | 580 |
<0>$conceptual_darwin_2003_1_0_County</0> |
568 | 581 |
<1>$dwc_dwcore_County</1> |
569 | 582 |
<2>$dwc_terms_county</2> |
570 | 583 |
</_alt> |
571 |
</placename> |
|
572 |
<parent_id> |
|
573 |
<namedplace> |
|
574 |
<rank>stateProvince</rank> |
|
575 |
<placename> |
|
576 |
<_alt> |
|
577 |
<0>$conceptual_darwin_2003_1_0_StateProvince</0> |
|
578 |
<1>$dwc_dwcore_StateProvince</1> |
|
579 |
<2>$dwc_terms_stateProvince</2> |
|
580 |
</_alt> |
|
581 |
</placename> |
|
582 |
<parent_id> |
|
583 |
<namedplace> |
|
584 |
<rank>country</rank> |
|
585 |
<placename> |
|
586 |
<_alt> |
|
587 |
<0>$conceptual_darwin_2003_1_0_Country</0> |
|
588 |
<1>$dwc_dwcore_Country</1> |
|
589 |
<2>$dwc_terms_country</2> |
|
590 |
</_alt> |
|
591 |
</placename> |
|
592 |
<parent_id> |
|
593 |
<namedplace> |
|
594 |
<rank>continent</rank> |
|
595 |
<placename> |
|
596 |
<_alt> |
|
597 |
<0>$conceptual_darwin_2003_1_0_ContinentOcean</0> |
|
598 |
<1>$dwc_dwcore_Continent</1> |
|
599 |
<2>$dwc_terms_continent</2> |
|
600 |
</_alt> |
|
601 |
</placename> |
|
602 |
</namedplace> |
|
603 |
</parent_id> |
|
604 |
</namedplace> |
|
605 |
</parent_id> |
|
606 |
</namedplace> |
|
607 |
</parent_id> |
|
608 |
</namedplace> |
|
609 |
</namedplace_id> |
|
584 |
</county> |
|
585 |
<stateprovince> |
|
586 |
<_alt> |
|
587 |
<0>$conceptual_darwin_2003_1_0_StateProvince</0> |
|
588 |
<1>$dwc_dwcore_StateProvince</1> |
|
589 |
<2>$dwc_terms_stateProvince</2> |
|
590 |
</_alt> |
|
591 |
</stateprovince> |
|
592 |
</placepath> |
|
593 |
</placepath_id> |
|
610 | 594 |
</locationplace> |
611 | 595 |
</location> |
612 | 596 |
</path> |
613 | 597 |
</_simplifyPath> |
614 | 598 |
</VegBIEN> |
615 |
Inserted 33 new rows into database |
|
599 |
Inserted 29 new rows into database |
inputs/MO/Specimen/test.xml.ref | ||
---|---|---|
184 | 184 |
</locationevent> |
185 | 185 |
<locationnarrative>$Locality</locationnarrative> |
186 | 186 |
<locationplace> |
187 |
<namedplace_id> |
|
188 |
<namedplace> |
|
189 |
<rank>county</rank> |
|
190 |
<placename>$County</placename> |
|
191 |
<parent_id> |
|
192 |
<namedplace> |
|
193 |
<rank>stateProvince</rank> |
|
194 |
<placename>$StateProvince</placename> |
|
195 |
<parent_id> |
|
196 |
<namedplace> |
|
197 |
<rank>country</rank> |
|
198 |
<placename>$Country</placename> |
|
199 |
<parent_id> |
|
200 |
<namedplace> |
|
201 |
<rank>continent</rank> |
|
202 |
<placename>$ContinentOcean</placename> |
|
203 |
</namedplace> |
|
204 |
</parent_id> |
|
205 |
</namedplace> |
|
206 |
</parent_id> |
|
207 |
</namedplace> |
|
208 |
</parent_id> |
|
209 |
</namedplace> |
|
210 |
</namedplace_id> |
|
187 |
<placepath_id> |
|
188 |
<placepath> |
|
189 |
<continent>$ContinentOcean</continent> |
|
190 |
<country>$Country</country> |
|
191 |
<county>$County</county> |
|
192 |
<stateprovince>$StateProvince</stateprovince> |
|
193 |
</placepath> |
|
194 |
</placepath_id> |
|
211 | 195 |
</locationplace> |
212 | 196 |
</location> |
213 | 197 |
</path> |
214 | 198 |
</_simplifyPath> |
215 | 199 |
</VegBIEN> |
216 |
Inserted 28 new rows into database |
|
200 |
Inserted 24 new rows into database |
inputs/QMOR/Specimen/VegBIEN.csv | ||
---|---|---|
47 | 47 |
catalogNumber,"/location/locationevent/taxonoccurrence/voucher/*_id/specimenreplicate/catalognumber_dwc/_if[@name=""if indirect voucher""]/then", |
48 | 48 |
locality,/location/locationnarrative/_merge/1, |
49 | 49 |
habitat,"/location/locationnarrative/_merge/3/_label[label=""habitat""]/value","Brad: Free-text description of vegetation community where collected, frequently redundane wrt 'Vegetation'. Bob, Nick: keep as user defined or create special element?" |
50 |
county,"/location/locationplace/namedplace_id/_forEach:[in:[],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=county]/placename",
|
|
51 |
stateProvince,"/location/locationplace/namedplace_id/_forEach:[in:[county,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=stateProvince]/placename",
|
|
52 |
country,"/location/locationplace/namedplace_id/_forEach:[in:[county,stateProvince,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=country]/placename",
|
|
53 |
continent,"/location/locationplace/namedplace_id/_forEach:[in:[county,stateProvince,country,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=continent]/placename",
|
|
50 |
continent,/location/locationplace/*_id/placepath/continent,
|
|
51 |
country,/location/locationplace/*_id/placepath/country,
|
|
52 |
county,/location/locationplace/*_id/placepath/county,
|
|
53 |
stateProvince,/location/locationplace/*_id/placepath/stateprovince,
|
|
54 | 54 |
acceptedNameUsage,,** No join mapping for acceptedNameUsage ** |
55 | 55 |
basisOfRecord,,** No join mapping for basisOfRecord ** |
56 | 56 |
behavior,,** No join mapping for behavior ** |
inputs/GBIF/Specimen/VegBIEN.csv | ||
---|---|---|
32 | 32 |
Collector,/location/locationevent/taxonoccurrence/verbatimcollectorname, |
33 | 33 |
CatalogNO,"/location/locationevent/taxonoccurrence/voucher/*_id/specimenreplicate/catalognumber_dwc/_if[@name=""if indirect voucher""]/then", |
34 | 34 |
Locality,/location/locationnarrative/_merge/1, |
35 |
County,"/location/locationplace/namedplace_id/_forEach:[in:[],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=county]/placename",
|
|
36 |
StateProvince,"/location/locationplace/namedplace_id/_forEach:[in:[county,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=stateProvince]/placename",
|
|
37 |
Country,"/location/locationplace/namedplace_id/_forEach:[in:[county,stateProvince,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=country]/placename",
|
|
35 |
Country,/location/locationplace/*_id/placepath/country,
|
|
36 |
County,/location/locationplace/*_id/placepath/county,
|
|
37 |
StateProvince,/location/locationplace/*_id/placepath/stateprovince,
|
|
38 | 38 |
0,,** No join mapping for 0 ** |
39 | 39 |
1,,** No join mapping for 1 ** |
40 | 40 |
25,,** No join mapping for 25 ** |
inputs/NCU-NCSC/Specimen/VegBIEN.csv | ||
---|---|---|
14 | 14 |
Cultivated?,/location/locationevent/taxonoccurrence/iscultivated/_alt/1, |
15 | 15 |
Full Taxon Name,/location/locationevent/taxonoccurrence/taxondetermination[!isoriginal]/*_id/taxonpath/scientificname, |
16 | 16 |
Barcode,"/location/locationevent/taxonoccurrence/voucher/*_id/specimenreplicate/catalognumber_dwc/_if[@name=""if indirect voucher""]/then", |
17 |
County,"/location/locationplace/namedplace_id/_forEach:[in:[],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=county]/placename",
|
|
18 |
State,"/location/locationplace/namedplace_id/_forEach:[in:[county,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=stateProvince]/placename",
|
|
19 |
Country,"/location/locationplace/namedplace_id/_forEach:[in:[county,stateProvince,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=country]/placename",
|
|
17 |
Country,/location/locationplace/*_id/placepath/country,
|
|
18 |
County,/location/locationplace/*_id/placepath/county,
|
|
19 |
State,/location/locationplace/*_id/placepath/stateprovince,
|
|
20 | 20 |
Alt E/W,,** No join mapping for Alt E/W ** |
21 | 21 |
Alt N/S,,** No join mapping for Alt N/S ** |
22 | 22 |
FIPS,,** No join mapping for FIPS ** FIPS county code |
inputs/SpeciesLink/Specimen/VegBIEN.csv | ||
---|---|---|
157 | 157 |
conceptual_darwin_2003_1_0_Locality,/location/locationnarrative/_merge/1, |
158 | 158 |
dwc_dwcore_Locality,/location/locationnarrative/_merge/1, |
159 | 159 |
dwc_terms_locality,/location/locationnarrative/_merge/1, |
160 |
conceptual_darwin_2003_1_0_County,"/location/locationplace/namedplace_id/_forEach:[in:[],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=county]/placename",
|
|
161 |
dwc_dwcore_County,"/location/locationplace/namedplace_id/_forEach:[in:[],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=county]/placename",
|
|
162 |
dwc_terms_county,"/location/locationplace/namedplace_id/_forEach:[in:[],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=county]/placename",
|
|
163 |
conceptual_darwin_2003_1_0_StateProvince,"/location/locationplace/namedplace_id/_forEach:[in:[county,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=stateProvince]/placename",
|
|
164 |
dwc_dwcore_StateProvince,"/location/locationplace/namedplace_id/_forEach:[in:[county,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=stateProvince]/placename",
|
|
165 |
dwc_terms_stateProvince,"/location/locationplace/namedplace_id/_forEach:[in:[county,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=stateProvince]/placename",
|
|
166 |
conceptual_darwin_2003_1_0_Country,"/location/locationplace/namedplace_id/_forEach:[in:[county,stateProvince,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=country]/placename",
|
|
167 |
dwc_dwcore_Country,"/location/locationplace/namedplace_id/_forEach:[in:[county,stateProvince,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=country]/placename",
|
|
168 |
dwc_terms_country,"/location/locationplace/namedplace_id/_forEach:[in:[county,stateProvince,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=country]/placename",
|
|
169 |
conceptual_darwin_2003_1_0_ContinentOcean,"/location/locationplace/namedplace_id/_forEach:[in:[county,stateProvince,country,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=continent]/placename",
|
|
170 |
dwc_dwcore_Continent,"/location/locationplace/namedplace_id/_forEach:[in:[county,stateProvince,country,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=continent]/placename",
|
|
171 |
dwc_terms_continent,"/location/locationplace/namedplace_id/_forEach:[in:[county,stateProvince,country,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=continent]/placename",
|
|
160 |
conceptual_darwin_2003_1_0_ContinentOcean,/location/locationplace/*_id/placepath/continent,
|
|
161 |
dwc_dwcore_Continent,/location/locationplace/*_id/placepath/continent,
|
|
162 |
dwc_terms_continent,/location/locationplace/*_id/placepath/continent,
|
|
163 |
conceptual_darwin_2003_1_0_Country,/location/locationplace/*_id/placepath/country,
|
|
164 |
dwc_dwcore_Country,/location/locationplace/*_id/placepath/country,
|
|
165 |
dwc_terms_country,/location/locationplace/*_id/placepath/country,
|
|
166 |
conceptual_darwin_2003_1_0_County,/location/locationplace/*_id/placepath/county,
|
|
167 |
dwc_dwcore_County,/location/locationplace/*_id/placepath/county,
|
|
168 |
dwc_terms_county,/location/locationplace/*_id/placepath/county,
|
|
169 |
conceptual_darwin_2003_1_0_StateProvince,/location/locationplace/*_id/placepath/stateprovince,
|
|
170 |
dwc_dwcore_StateProvince,/location/locationplace/*_id/placepath/stateprovince,
|
|
171 |
dwc_terms_stateProvince,/location/locationplace/*_id/placepath/stateprovince,
|
|
172 | 172 |
conceptual_darwin_2003_1_0_BasisOfRecord,,** No join mapping for BasisOfRecord ** |
173 | 173 |
conceptual_darwin_2003_1_0_DateLastModified,,** No join mapping for dcterms:modified ** |
174 | 174 |
conceptual_darwin_2003_1_0_JulianDay,,** No join mapping for day/_alt/1 ** |
inputs/MO/Specimen/VegBIEN.csv | ||
---|---|---|
34 | 34 |
Collector,/location/locationevent/taxonoccurrence/verbatimcollectorname, |
35 | 35 |
CatalogNumber,"/location/locationevent/taxonoccurrence/voucher/*_id/specimenreplicate/catalognumber_dwc/_if[@name=""if indirect voucher""]/then", |
36 | 36 |
Locality,/location/locationnarrative/_merge/1, |
37 |
County,"/location/locationplace/namedplace_id/_forEach:[in:[],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=county]/placename",
|
|
38 |
StateProvince,"/location/locationplace/namedplace_id/_forEach:[in:[county,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=stateProvince]/placename",
|
|
39 |
Country,"/location/locationplace/namedplace_id/_forEach:[in:[county,stateProvince,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=country]/placename",
|
|
40 |
ContinentOcean,"/location/locationplace/namedplace_id/_forEach:[in:[county,stateProvince,country,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=continent]/placename",
|
|
37 |
ContinentOcean,/location/locationplace/*_id/placepath/continent,
|
|
38 |
Country,/location/locationplace/*_id/placepath/country,
|
|
39 |
County,/location/locationplace/*_id/placepath/county,
|
|
40 |
StateProvince,/location/locationplace/*_id/placepath/stateprovince,
|
|
41 | 41 |
BasisOfRecord,,** No join mapping for BasisOfRecord ** |
42 | 42 |
DateLastModified,,** No join mapping for dcterms:modified ** |
43 | 43 |
TypeStatus,,** No join mapping for TypeStatus ** |
inputs/VegBank/plot_/VegBIEN.csv | ||
---|---|---|
14 | 14 |
authorplotcode,"/location/locationevent/_if[@name=""if subplot""]/then/_if[@name=""if event""]/then/parent_id/locationevent/*_id/location/authorlocationcode", |
15 | 15 |
plot_id,"/location/locationevent/_if[@name=""if subplot""]/then/_if[@name=""if event""]/then/parent_id/locationevent/*_id/location/sourceaccessioncode", |
16 | 16 |
locationnarrative,/location/locationnarrative/_merge/1, |
17 |
county,"/location/locationplace/namedplace_id/_forEach:[in:[],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=county]/placename",
|
|
18 |
region|state|province,"/location/locationplace/namedplace_id/_forEach:[in:[county,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=stateProvince]/placename",
|
|
19 |
stateprovince,"/location/locationplace/namedplace_id/_forEach:[in:[county,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=stateProvince]/placename",
|
|
20 |
area|country|territory,"/location/locationplace/namedplace_id/_forEach:[in:[county,stateProvince,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=country]/placename",
|
|
21 |
country,"/location/locationplace/namedplace_id/_forEach:[in:[county,stateProvince,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=country]/placename",
|
|
22 |
continent,"/location/locationplace/namedplace_id/_forEach:[in:[county,stateProvince,country,],do=""namedplace[rank=_val]/parent_id""]/namedplace[rank=continent]/placename",
|
|
17 |
continent,/location/locationplace/*_id/placepath/continent,
|
|
18 |
area|country|territory,/location/locationplace/*_id/placepath/country,
|
|
19 |
country,/location/locationplace/*_id/placepath/country,
|
|
20 |
county,/location/locationplace/*_id/placepath/county,
|
|
21 |
region|state|province,/location/locationplace/*_id/placepath/stateprovince,
|
|
22 |
stateprovince,/location/locationplace/*_id/placepath/stateprovince,
|
|
23 | 23 |
slopeaspect,/location/slopeaspect/_alt/1/_compass/value, |
24 | 24 |
maxslopeaspect,/location/slopeaspect/_alt/2/_avg/max, |
25 | 25 |
minslopeaspect,/location/slopeaspect/_alt/2/_avg/min, |
inputs/QMOR/Specimen/test.xml.ref | ||
---|---|---|
229 | 229 |
</_merge> |
230 | 230 |
</locationnarrative> |
231 | 231 |
<locationplace> |
232 |
<namedplace_id> |
|
233 |
<namedplace> |
|
234 |
<rank>county</rank> |
|
235 |
<placename>$county</placename> |
|
236 |
<parent_id> |
|
237 |
<namedplace> |
|
238 |
<rank>stateProvince</rank> |
|
239 |
<placename>$stateProvince</placename> |
|
240 |
<parent_id> |
|
241 |
<namedplace> |
|
242 |
<rank>country</rank> |
|
243 |
<placename>$country</placename> |
|
244 |
<parent_id> |
|
245 |
<namedplace> |
|
246 |
<rank>continent</rank> |
|
247 |
<placename>$continent</placename> |
|
248 |
</namedplace> |
|
249 |
</parent_id> |
|
250 |
</namedplace> |
|
251 |
</parent_id> |
|
252 |
</namedplace> |
|
253 |
</parent_id> |
|
254 |
</namedplace> |
|
255 |
</namedplace_id> |
|
232 |
<placepath_id> |
|
233 |
<placepath> |
|
234 |
<continent>$continent</continent> |
|
235 |
<country>$country</country> |
|
236 |
<county>$county</county> |
|
237 |
<stateprovince>$stateProvince</stateprovince> |
|
238 |
</placepath> |
|
239 |
</placepath_id> |
|
256 | 240 |
</locationplace> |
257 | 241 |
</location> |
258 | 242 |
</path> |
259 | 243 |
</_simplifyPath> |
260 | 244 |
</VegBIEN> |
261 |
Inserted 28 new rows into database |
|
245 |
Inserted 26 new rows into database |
schemas/vegbien.sql | ||
---|---|---|
668 | 668 |
CREATE TABLE locationplace ( |
669 | 669 |
locationplace_id integer NOT NULL, |
670 | 670 |
location_id integer NOT NULL, |
671 |
namedplace_id integer NOT NULL
|
|
671 |
placepath_id integer NOT NULL
|
|
672 | 672 |
); |
673 | 673 |
|
674 | 674 |
|
... | ... | |
1136 | 1136 |
-- |
1137 | 1137 |
|
1138 | 1138 |
CREATE VIEW analytical_db_view AS |
1139 |
SELECT datasource.organizationname AS "dataSourceName", taxonpath.family, taxonpath.genus, taxonpath.species, COALESCE(taxonpath.scientificnamewithauthor, taxonpath.scientificname) AS taxon, taxonpath.scientificnameauthor AS "taxonAuthor", taxonpath.variety AS "taxonMorphospecies", country.placename AS country, stateprovince.placename AS "stateProvince", county.placename AS "countyParish", taxonoccurrence.verbatimcollectorname AS collector, plantobservation.collectionnumber AS "collectionNumber", array_to_string(ARRAY[identifiedby.givenname, identifiedby.middlename, identifiedby.surname], ' '::text) AS "identifiedBy", aggregateoccurrence.collectiondate AS "observationDate", location.authorlocationcode AS "plotCode", location.area AS "plotAreaHa", method.name AS "plotMethod", locationcoords.latitude, locationcoords.longitude, location.elevation AS elevation_m, taxonoccurrence.iscultivated AS "isCultivated", taxonoccurrence.cultivatedbasis AS "isCultivatedReason", aggregateoccurrence.cover AS "pctCover" FROM ((((((((((((((((((((location JOIN party datasource ON (((datasource.party_id = location.datasource_id) AND (datasource.organizationname IS NOT NULL)))) JOIN locationcoords USING (location_id)) JOIN locationplace USING (location_id)) LEFT JOIN namedplace_ancestor continent_ancestor ON ((continent_ancestor.namedplace_id = locationplace.namedplace_id))) LEFT JOIN namedplace continent ON (((continent.namedplace_id = continent_ancestor.ancestor_id) AND (continent.rank = 'continent'::placerank)))) LEFT JOIN namedplace_ancestor country_ancestor ON ((country_ancestor.namedplace_id = locationplace.namedplace_id))) LEFT JOIN namedplace country ON (((country.namedplace_id = country_ancestor.ancestor_id) AND (country.rank = 'country'::placerank)))) LEFT JOIN namedplace_ancestor stateprovince_ancestor ON ((stateprovince_ancestor.namedplace_id = locationplace.namedplace_id))) LEFT JOIN namedplace stateprovince ON (((stateprovince.namedplace_id = stateprovince_ancestor.ancestor_id) AND (stateprovince.rank = 'stateProvince'::placerank)))) LEFT JOIN namedplace_ancestor county_ancestor ON ((county_ancestor.namedplace_id = locationplace.namedplace_id))) LEFT JOIN namedplace county ON (((county.namedplace_id = county_ancestor.ancestor_id) AND (county.rank = 'county'::placerank)))) JOIN locationevent USING (location_id)) JOIN method USING (method_id)) JOIN taxonoccurrence USING (locationevent_id)) JOIN taxondetermination USING (taxonoccurrence_id)) LEFT JOIN party identifiedby ON ((identifiedby.party_id = taxondetermination.party_id))) JOIN taxonpath USING (taxonpath_id)) LEFT JOIN aggregateoccurrence USING (taxonoccurrence_id)) LEFT JOIN plantobservation USING (aggregateoccurrence_id)) LEFT JOIN specimenreplicate USING (plantobservation_id));
|
|
1139 |
SELECT datasource.organizationname AS "dataSourceName", taxonpath.family, taxonpath.genus, taxonpath.species, COALESCE(taxonpath.scientificnamewithauthor, taxonpath.scientificname) AS taxon, taxonpath.scientificnameauthor AS "taxonAuthor", taxonpath.variety AS "taxonMorphospecies", country.placename AS country, stateprovince.placename AS "stateProvince", county.placename AS "countyParish", taxonoccurrence.verbatimcollectorname AS collector, plantobservation.collectionnumber AS "collectionNumber", array_to_string(ARRAY[identifiedby.givenname, identifiedby.middlename, identifiedby.surname], ' '::text) AS "identifiedBy", aggregateoccurrence.collectiondate AS "observationDate", location.authorlocationcode AS "plotCode", location.area AS "plotAreaHa", method.name AS "plotMethod", locationcoords.latitude, locationcoords.longitude, location.elevation AS elevation_m, taxonoccurrence.iscultivated AS "isCultivated", taxonoccurrence.cultivatedbasis AS "isCultivatedReason", aggregateoccurrence.cover AS "pctCover" FROM ((((((((((((((((((((location JOIN party datasource ON (((datasource.party_id = location.datasource_id) AND (datasource.organizationname IS NOT NULL)))) JOIN locationcoords USING (location_id)) JOIN locationplace USING (location_id)) LEFT JOIN namedplace_ancestor continent_ancestor ON ((continent_ancestor.namedplace_id = locationplace.placepath_id))) LEFT JOIN namedplace continent ON (((continent.namedplace_id = continent_ancestor.ancestor_id) AND (continent.rank = 'continent'::placerank)))) LEFT JOIN namedplace_ancestor country_ancestor ON ((country_ancestor.namedplace_id = locationplace.placepath_id))) LEFT JOIN namedplace country ON (((country.namedplace_id = country_ancestor.ancestor_id) AND (country.rank = 'country'::placerank)))) LEFT JOIN namedplace_ancestor stateprovince_ancestor ON ((stateprovince_ancestor.namedplace_id = locationplace.placepath_id))) LEFT JOIN namedplace stateprovince ON (((stateprovince.namedplace_id = stateprovince_ancestor.ancestor_id) AND (stateprovince.rank = 'stateProvince'::placerank)))) LEFT JOIN namedplace_ancestor county_ancestor ON ((county_ancestor.namedplace_id = locationplace.placepath_id))) LEFT JOIN namedplace county ON (((county.namedplace_id = county_ancestor.ancestor_id) AND (county.rank = 'county'::placerank)))) JOIN locationevent USING (location_id)) JOIN method USING (method_id)) JOIN taxonoccurrence USING (locationevent_id)) JOIN taxondetermination USING (taxonoccurrence_id)) LEFT JOIN party identifiedby ON ((identifiedby.party_id = taxondetermination.party_id))) JOIN taxonpath USING (taxonpath_id)) LEFT JOIN aggregateoccurrence USING (taxonoccurrence_id)) LEFT JOIN plantobservation USING (aggregateoccurrence_id)) LEFT JOIN specimenreplicate USING (plantobservation_id));
|
|
1140 | 1140 |
|
1141 | 1141 |
|
1142 | 1142 |
-- |
... | ... | |
2031 | 2031 |
|
2032 | 2032 |
|
2033 | 2033 |
-- |
2034 |
-- Name: placepath; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
2035 |
-- |
|
2036 |
|
|
2037 |
CREATE TABLE placepath ( |
|
2038 |
placepath_id integer NOT NULL, |
|
2039 |
datasource_id integer NOT NULL, |
|
2040 |
placecode text, |
|
2041 |
namedplace_id integer, |
|
2042 |
continent text, |
|
2043 |
country text, |
|
2044 |
stateprovince text, |
|
2045 |
county text, |
|
2046 |
municipality text, |
|
2047 |
site text |
|
2048 |
); |
|
2049 |
|
|
2050 |
|
|
2051 |
-- |
|
2052 |
-- Name: TABLE placepath; Type: COMMENT; Schema: public; Owner: - |
|
2053 |
-- |
|
2054 |
|
|
2055 |
COMMENT ON TABLE placepath IS 'To include a place at a rank with no explicit column, create a namedplace for it and point to it using namedplace_id. To include multiple such places, chain the namedplaces together using parent_id, as a form of ordered linked list. Note that lower-level places should point to higher-level places.'; |
|
2056 |
|
|
2057 |
|
|
2058 |
-- |
|
2059 |
-- Name: placepath_placepath_id_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
2060 |
-- |
|
2061 |
|
|
2062 |
CREATE SEQUENCE placepath_placepath_id_seq |
|
2063 |
START WITH 1 |
|
2064 |
INCREMENT BY 1 |
|
2065 |
NO MINVALUE |
|
2066 |
NO MAXVALUE |
|
2067 |
CACHE 1; |
|
2068 |
|
|
2069 |
|
|
2070 |
-- |
|
2071 |
-- Name: placepath_placepath_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - |
|
2072 |
-- |
|
2073 |
|
|
2074 |
ALTER SEQUENCE placepath_placepath_id_seq OWNED BY placepath.placepath_id; |
|
2075 |
|
|
2076 |
|
|
2077 |
-- |
|
2034 | 2078 |
-- Name: plant; Type: TABLE; Schema: public; Owner: -; Tablespace: |
2035 | 2079 |
-- |
2036 | 2080 |
|
... | ... | |
3388 | 3432 |
|
3389 | 3433 |
|
3390 | 3434 |
-- |
3435 |
-- Name: placepath_id; Type: DEFAULT; Schema: public; Owner: - |
|
3436 |
-- |
|
3437 |
|
|
3438 |
ALTER TABLE placepath ALTER COLUMN placepath_id SET DEFAULT nextval('placepath_placepath_id_seq'::regclass); |
|
3439 |
|
|
3440 |
|
|
3441 |
-- |
|
3391 | 3442 |
-- Name: plant_id; Type: DEFAULT; Schema: public; Owner: - |
3392 | 3443 |
-- |
3393 | 3444 |
|
... | ... | |
3817 | 3868 |
-- |
3818 | 3869 |
|
3819 | 3870 |
ALTER TABLE ONLY locationplace |
3820 |
ADD CONSTRAINT locationplace_unique UNIQUE (location_id, namedplace_id);
|
|
3871 |
ADD CONSTRAINT locationplace_unique UNIQUE (location_id, placepath_id);
|
|
3821 | 3872 |
|
3822 | 3873 |
|
3823 | 3874 |
-- |
... | ... | |
3909 | 3960 |
|
3910 | 3961 |
|
3911 | 3962 |
-- |
3963 |
-- Name: placepath_pkey; Type: CONSTRAINT; Schema: public; Owner: -; Tablespace: |
|
3964 |
-- |
|
3965 |
|
|
3966 |
ALTER TABLE ONLY placepath |
|
3967 |
ADD CONSTRAINT placepath_pkey PRIMARY KEY (placepath_id); |
|
3968 |
|
|
3969 |
|
|
3970 |
-- |
|
3971 |
-- Name: placepath_unique; Type: CONSTRAINT; Schema: public; Owner: -; Tablespace: |
|
3972 |
-- |
|
3973 |
|
|
3974 |
ALTER TABLE ONLY placepath |
|
3975 |
ADD CONSTRAINT placepath_unique UNIQUE (namedplace_id); |
|
3976 |
|
|
3977 |
|
|
3978 |
-- |
|
3912 | 3979 |
-- Name: plant_pkey; Type: CONSTRAINT; Schema: public; Owner: -; Tablespace: |
3913 | 3980 |
-- |
3914 | 3981 |
|
... | ... | |
4410 | 4477 |
|
4411 | 4478 |
|
4412 | 4479 |
-- |
4480 |
-- Name: placepath_unique_within_datasource_by_code; Type: INDEX; Schema: public; Owner: -; Tablespace: |
|
4481 |
-- |
|
4482 |
|
|
4483 |
CREATE UNIQUE INDEX placepath_unique_within_datasource_by_code ON placepath USING btree (datasource_id, (COALESCE(placecode, '\\N'::text))) WHERE (placecode IS NOT NULL); |
|
4484 |
|
|
4485 |
|
|
4486 |
-- |
|
4487 |
-- Name: placepath_unique_within_datasource_by_name; Type: INDEX; Schema: public; Owner: -; Tablespace: |
|
4488 |
-- |
|
4489 |
|
|
4490 |
CREATE UNIQUE INDEX placepath_unique_within_datasource_by_name ON placepath USING btree (datasource_id, (COALESCE(namedplace_id, 2147483647)), (COALESCE(continent, '\\N'::text)), (COALESCE(country, '\\N'::text)), (COALESCE(stateprovince, '\\N'::text)), (COALESCE(county, '\\N'::text)), (COALESCE(municipality, '\\N'::text)), (COALESCE(site, '\\N'::text))) WHERE (placecode IS NULL); |
|
4491 |
|
|
4492 |
|
|
4493 |
-- |
|
4413 | 4494 |
-- Name: plantobservation_aggregateoccurrence_1_to_1; Type: INDEX; Schema: public; Owner: -; Tablespace: |
4414 | 4495 |
-- |
4415 | 4496 |
|
... | ... | |
5028 | 5109 |
|
5029 | 5110 |
|
5030 | 5111 |
-- |
5031 |
-- Name: locationplace_namedplace_id_fkey; Type: FK CONSTRAINT; Schema: public; Owner: -
|
|
5112 |
-- Name: locationplace_placepath_id_fkey; Type: FK CONSTRAINT; Schema: public; Owner: -
|
|
5032 | 5113 |
-- |
5033 | 5114 |
|
5034 | 5115 |
ALTER TABLE ONLY locationplace |
5035 |
ADD CONSTRAINT locationplace_namedplace_id_fkey FOREIGN KEY (namedplace_id) REFERENCES namedplace(namedplace_id) ON UPDATE CASCADE ON DELETE CASCADE;
|
|
5116 |
ADD CONSTRAINT locationplace_placepath_id_fkey FOREIGN KEY (placepath_id) REFERENCES placepath(placepath_id) ON UPDATE CASCADE ON DELETE CASCADE;
|
|
5036 | 5117 |
|
5037 | 5118 |
|
5038 | 5119 |
-- |
... | ... | |
5164 | 5245 |
|
5165 | 5246 |
|
5166 | 5247 |
-- |
5248 |
-- Name: placepath_datasource_id_fkey; Type: FK CONSTRAINT; Schema: public; Owner: - |
|
5249 |
-- |
|
5250 |
|
|
5251 |
ALTER TABLE ONLY placepath |
|
5252 |
ADD CONSTRAINT placepath_datasource_id_fkey FOREIGN KEY (datasource_id) REFERENCES party(party_id) ON UPDATE CASCADE ON DELETE CASCADE; |
|
5253 |
|
|
5254 |
|
|
5255 |
-- |
|
5256 |
-- Name: placepath_namedplace_id_fkey; Type: FK CONSTRAINT; Schema: public; Owner: - |
|
5257 |
-- |
|
5258 |
|
|
5259 |
ALTER TABLE ONLY placepath |
|
5260 |
ADD CONSTRAINT placepath_namedplace_id_fkey FOREIGN KEY (namedplace_id) REFERENCES namedplace(namedplace_id) ON UPDATE CASCADE ON DELETE CASCADE; |
|
5261 |
|
|
5262 |
|
|
5263 |
-- |
|
5167 | 5264 |
-- Name: plantcorrelation_plantstatus_id_fkey; Type: FK CONSTRAINT; Schema: public; Owner: - |
5168 | 5265 |
-- |
5169 | 5266 |
|
inputs/VegBank/plot_/test.xml.ref | ||
---|---|---|
34 | 34 |
</locationcoords> |
35 | 35 |
<locationnarrative>$locationnarrative</locationnarrative> |
36 | 36 |
<locationplace> |
37 |
<namedplace_id> |
|
38 |
<namedplace> |
|
39 |
<rank>county</rank> |
|
40 |
<placename>$county</placename> |
|
41 |
<parent_id> |
|
42 |
<namedplace> |
|
43 |
<rank>stateProvince</rank> |
|
44 |
<placename> |
|
45 |
<_alt> |
|
46 |
<0>$region|state|province</0> |
|
47 |
<1>$stateprovince</1> |
|
48 |
</_alt> |
|
49 |
</placename> |
|
50 |
<parent_id> |
|
51 |
<namedplace> |
|
52 |
<rank>country</rank> |
|
53 |
<placename> |
|
54 |
<_alt> |
|
55 |
<0>$area|country|territory</0> |
|
56 |
<1>$country</1> |
|
57 |
</_alt> |
|
58 |
</placename> |
|
59 |
<parent_id> |
|
60 |
<namedplace> |
|
61 |
<rank>continent</rank> |
|
62 |
<placename>$continent</placename> |
|
63 |
</namedplace> |
|
64 |
</parent_id> |
|
65 |
</namedplace> |
|
66 |
</parent_id> |
|
67 |
</namedplace> |
|
68 |
</parent_id> |
|
69 |
</namedplace> |
|
70 |
</namedplace_id> |
|
37 |
<placepath_id> |
|
38 |
<placepath> |
|
39 |
<continent>$continent</continent> |
|
40 |
<country> |
|
41 |
<_alt> |
|
42 |
<0>$area|country|territory</0> |
|
43 |
<1>$country</1> |
|
44 |
</_alt> |
|
45 |
</country> |
|
46 |
<county>$county</county> |
|
47 |
<stateprovince> |
|
48 |
<_alt> |
|
49 |
<0>$region|state|province</0> |
|
50 |
<1>$stateprovince</1> |
|
51 |
</_alt> |
|
52 |
</stateprovince> |
|
53 |
</placepath> |
|
54 |
</placepath_id> |
|
71 | 55 |
</locationplace> |
72 | 56 |
<slopeaspect> |
73 | 57 |
<_alt> |
schemas/vegbien.my.sql | ||
---|---|---|
414 | 414 |
CREATE TABLE locationplace ( |
415 | 415 |
locationplace_id int(11) NOT NULL, |
416 | 416 |
location_id int(11) NOT NULL, |
417 |
namedplace_id int(11) NOT NULL
|
|
417 |
placepath_id int(11) NOT NULL
|
|
418 | 418 |
); |
419 | 419 |
|
420 | 420 |
|
... | ... | |
856 | 856 |
-- |
857 | 857 |
|
858 | 858 |
CREATE VIEW analytical_db_view AS |
859 |
SELECT datasource.organizationname AS `dataSourceName`, taxonpath.family, taxonpath.genus, taxonpath.species, COALESCE(taxonpath.scientificnamewithauthor, taxonpath.scientificname) AS taxon, taxonpath.scientificnameauthor AS `taxonAuthor`, taxonpath.variety AS `taxonMorphospecies`, country.placename AS country, stateprovince.placename AS `stateProvince`, county.placename AS `countyParish`, taxonoccurrence.verbatimcollectorname AS collector, plantobservation.collectionnumber AS `collectionNumber`, array_to_string(ARRAY[identifiedby.givenname, identifiedby.middlename, identifiedby.surname], CAST(' ' AS text)) AS `identifiedBy`, aggregateoccurrence.collectiondate AS `observationDate`, location.authorlocationcode AS `plotCode`, location.area AS `plotAreaHa`, method.name AS `plotMethod`, locationcoords.latitude, locationcoords.longitude, location.elevation AS elevation_m, taxonoccurrence.iscultivated AS `isCultivated`, taxonoccurrence.cultivatedbasis AS `isCultivatedReason`, aggregateoccurrence.cover AS `pctCover` FROM ((((((((((((((((((((location JOIN party datasource ON (((datasource.party_id = location.datasource_id) AND (datasource.organizationname IS NOT NULL)))) JOIN locationcoords USING (location_id)) JOIN locationplace USING (location_id)) LEFT JOIN namedplace_ancestor continent_ancestor ON ((continent_ancestor.namedplace_id = locationplace.namedplace_id))) LEFT JOIN namedplace continent ON (((continent.namedplace_id = continent_ancestor.ancestor_id) AND (continent.rank = CAST('continent' AS placerank))))) LEFT JOIN namedplace_ancestor country_ancestor ON ((country_ancestor.namedplace_id = locationplace.namedplace_id))) LEFT JOIN namedplace country ON (((country.namedplace_id = country_ancestor.ancestor_id) AND (country.rank = CAST('country' AS placerank))))) LEFT JOIN namedplace_ancestor stateprovince_ancestor ON ((stateprovince_ancestor.namedplace_id = locationplace.namedplace_id))) LEFT JOIN namedplace stateprovince ON (((stateprovince.namedplace_id = stateprovince_ancestor.ancestor_id) AND (stateprovince.rank = CAST('stateProvince' AS placerank))))) LEFT JOIN namedplace_ancestor county_ancestor ON ((county_ancestor.namedplace_id = locationplace.namedplace_id))) LEFT JOIN namedplace county ON (((county.namedplace_id = county_ancestor.ancestor_id) AND (county.rank = CAST('county' AS placerank))))) JOIN locationevent USING (location_id)) JOIN method USING (method_id)) JOIN taxonoccurrence USING (locationevent_id)) JOIN taxondetermination USING (taxonoccurrence_id)) LEFT JOIN party identifiedby ON ((identifiedby.party_id = taxondetermination.party_id))) JOIN taxonpath USING (taxonpath_id)) LEFT JOIN aggregateoccurrence USING (taxonoccurrence_id)) LEFT JOIN plantobservation USING (aggregateoccurrence_id)) LEFT JOIN specimenreplicate USING (plantobservation_id));
|
|
859 |
SELECT datasource.organizationname AS `dataSourceName`, taxonpath.family, taxonpath.genus, taxonpath.species, COALESCE(taxonpath.scientificnamewithauthor, taxonpath.scientificname) AS taxon, taxonpath.scientificnameauthor AS `taxonAuthor`, taxonpath.variety AS `taxonMorphospecies`, country.placename AS country, stateprovince.placename AS `stateProvince`, county.placename AS `countyParish`, taxonoccurrence.verbatimcollectorname AS collector, plantobservation.collectionnumber AS `collectionNumber`, array_to_string(ARRAY[identifiedby.givenname, identifiedby.middlename, identifiedby.surname], CAST(' ' AS text)) AS `identifiedBy`, aggregateoccurrence.collectiondate AS `observationDate`, location.authorlocationcode AS `plotCode`, location.area AS `plotAreaHa`, method.name AS `plotMethod`, locationcoords.latitude, locationcoords.longitude, location.elevation AS elevation_m, taxonoccurrence.iscultivated AS `isCultivated`, taxonoccurrence.cultivatedbasis AS `isCultivatedReason`, aggregateoccurrence.cover AS `pctCover` FROM ((((((((((((((((((((location JOIN party datasource ON (((datasource.party_id = location.datasource_id) AND (datasource.organizationname IS NOT NULL)))) JOIN locationcoords USING (location_id)) JOIN locationplace USING (location_id)) LEFT JOIN namedplace_ancestor continent_ancestor ON ((continent_ancestor.namedplace_id = locationplace.placepath_id))) LEFT JOIN namedplace continent ON (((continent.namedplace_id = continent_ancestor.ancestor_id) AND (continent.rank = CAST('continent' AS placerank))))) LEFT JOIN namedplace_ancestor country_ancestor ON ((country_ancestor.namedplace_id = locationplace.placepath_id))) LEFT JOIN namedplace country ON (((country.namedplace_id = country_ancestor.ancestor_id) AND (country.rank = CAST('country' AS placerank))))) LEFT JOIN namedplace_ancestor stateprovince_ancestor ON ((stateprovince_ancestor.namedplace_id = locationplace.placepath_id))) LEFT JOIN namedplace stateprovince ON (((stateprovince.namedplace_id = stateprovince_ancestor.ancestor_id) AND (stateprovince.rank = CAST('stateProvince' AS placerank))))) LEFT JOIN namedplace_ancestor county_ancestor ON ((county_ancestor.namedplace_id = locationplace.placepath_id))) LEFT JOIN namedplace county ON (((county.namedplace_id = county_ancestor.ancestor_id) AND (county.rank = CAST('county' AS placerank))))) JOIN locationevent USING (location_id)) JOIN method USING (method_id)) JOIN taxonoccurrence USING (locationevent_id)) JOIN taxondetermination USING (taxonoccurrence_id)) LEFT JOIN party identifiedby ON ((identifiedby.party_id = taxondetermination.party_id))) JOIN taxonpath USING (taxonpath_id)) LEFT JOIN aggregateoccurrence USING (taxonoccurrence_id)) LEFT JOIN plantobservation USING (aggregateoccurrence_id)) LEFT JOIN specimenreplicate USING (plantobservation_id));
|
|
860 | 860 |
|
861 | 861 |
|
862 | 862 |
-- |
... | ... | |
1594 | 1594 |
|
1595 | 1595 |
|
1596 | 1596 |
-- |
1597 |
-- Name: placepath; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
1598 |
-- |
|
1599 |
|
|
1600 |
CREATE TABLE placepath ( |
|
1601 |
placepath_id int(11) NOT NULL, |
|
1602 |
datasource_id int(11) NOT NULL, |
|
1603 |
placecode text, |
|
1604 |
namedplace_id int(11), |
|
1605 |
continent text, |
|
1606 |
country text, |
|
1607 |
stateprovince text, |
|
1608 |
county text, |
|
1609 |
municipality text, |
|
1610 |
site text |
|
1611 |
); |
|
1612 |
|
|
1613 |
|
|
1614 |
-- |
|
1615 |
-- Name: TABLE placepath; Type: COMMENT; Schema: public; Owner: - |
|
1616 |
-- |
|
1617 |
|
|
1618 |
|
|
1619 |
|
|
1620 |
|
|
1621 |
-- |
|
1622 |
-- Name: placepath_placepath_id_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
1623 |
-- |
|
1624 |
|
|
1625 |
|
|
1626 |
|
|
1627 |
|
|
1628 |
-- |
|
1629 |
-- Name: placepath_placepath_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - |
|
1630 |
-- |
|
1631 |
|
|
1632 |
|
|
1633 |
|
|
1634 |
|
|
1635 |
-- |
|
1597 | 1636 |
-- Name: plant; Type: TABLE; Schema: public; Owner: -; Tablespace: |
1598 | 1637 |
-- |
1599 | 1638 |
|
... | ... | |
2792 | 2831 |
|
2793 | 2832 |
|
2794 | 2833 |
-- |
2834 |
-- Name: placepath_id; Type: DEFAULT; Schema: public; Owner: - |
|
2835 |
-- |
|
2836 |
|
|
2837 |
|
|
2838 |
|
|
2839 |
|
|
2840 |
-- |
|
2795 | 2841 |
-- Name: plant_id; Type: DEFAULT; Schema: public; Owner: - |
2796 | 2842 |
-- |
2797 | 2843 |
|
... | ... | |
3221 | 3267 |
-- |
3222 | 3268 |
|
3223 | 3269 |
ALTER TABLE locationplace |
3224 |
ADD CONSTRAINT locationplace_unique UNIQUE (location_id, namedplace_id);
|
|
3270 |
ADD CONSTRAINT locationplace_unique UNIQUE (location_id, placepath_id);
|
|
3225 | 3271 |
|
3226 | 3272 |
|
3227 | 3273 |
-- |
... | ... | |
3313 | 3359 |
|
3314 | 3360 |
|
3315 | 3361 |
-- |
3362 |
-- Name: placepath_pkey; Type: CONSTRAINT; Schema: public; Owner: -; Tablespace: |
|
3363 |
-- |
|
3364 |
|
|
3365 |
ALTER TABLE placepath |
|
3366 |
ADD CONSTRAINT placepath_pkey PRIMARY KEY (placepath_id); |
|
3367 |
|
|
3368 |
|
|
3369 |
-- |
|
3370 |
-- Name: placepath_unique; Type: CONSTRAINT; Schema: public; Owner: -; Tablespace: |
|
3371 |
-- |
|
3372 |
|
|
3373 |
ALTER TABLE placepath |
|
3374 |
ADD CONSTRAINT placepath_unique UNIQUE (namedplace_id); |
|
3375 |
|
|
3376 |
|
|
3377 |
-- |
|
3316 | 3378 |
-- Name: plant_pkey; Type: CONSTRAINT; Schema: public; Owner: -; Tablespace: |
3317 | 3379 |
-- |
3318 | 3380 |
|
... | ... | |
3814 | 3876 |
|
3815 | 3877 |
|
3816 | 3878 |
-- |
3879 |
-- Name: placepath_unique_within_datasource_by_code; Type: INDEX; Schema: public; Owner: -; Tablespace: |
|
3880 |
-- |
|
3881 |
|
|
3882 |
|
|
3883 |
|
|
3884 |
|
|
3885 |
-- |
|
3886 |
-- Name: placepath_unique_within_datasource_by_name; Type: INDEX; Schema: public; Owner: -; Tablespace: |
|
3887 |
-- |
|
3888 |
|
|
3889 |
|
|
3890 |
|
|
3891 |
|
|
3892 |
-- |
|
3817 | 3893 |
-- Name: plantobservation_aggregateoccurrence_1_to_1; Type: INDEX; Schema: public; Owner: -; Tablespace: |
3818 | 3894 |
-- |
3819 | 3895 |
|
... | ... | |
4413 | 4489 |
|
4414 | 4490 |
|
4415 | 4491 |
-- |
4416 |
-- Name: locationplace_namedplace_id_fkey; Type: FK CONSTRAINT; Schema: public; Owner: -
|
|
4492 |
-- Name: locationplace_placepath_id_fkey; Type: FK CONSTRAINT; Schema: public; Owner: -
|
|
4417 | 4493 |
-- |
4418 | 4494 |
|
4419 | 4495 |
ALTER TABLE locationplace |
4420 |
ADD CONSTRAINT locationplace_namedplace_id_fkey FOREIGN KEY (namedplace_id) REFERENCES namedplace(namedplace_id) ON UPDATE CASCADE ON DELETE CASCADE;
|
|
4496 |
ADD CONSTRAINT locationplace_placepath_id_fkey FOREIGN KEY (placepath_id) REFERENCES placepath(placepath_id) ON UPDATE CASCADE ON DELETE CASCADE;
|
|
4421 | 4497 |
|
4422 | 4498 |
|
4423 | 4499 |
-- |
... | ... | |
4547 | 4623 |
|
4548 | 4624 |
|
4549 | 4625 |
-- |
4626 |
-- Name: placepath_datasource_id_fkey; Type: FK CONSTRAINT; Schema: public; Owner: - |
|
4627 |
-- |
|
4628 |
|
|
4629 |
|
|
4630 |
|
|
4631 |
|
|
4632 |
-- |
|
4633 |
-- Name: placepath_namedplace_id_fkey; Type: FK CONSTRAINT; Schema: public; Owner: - |
|
4634 |
-- |
|
4635 |
|
|
4636 |
ALTER TABLE placepath |
|
4637 |
ADD CONSTRAINT placepath_namedplace_id_fkey FOREIGN KEY (namedplace_id) REFERENCES namedplace(namedplace_id) ON UPDATE CASCADE ON DELETE CASCADE; |
|
4638 |
|
|
4639 |
|
|
4640 |
-- |
|
4550 | 4641 |
-- Name: plantcorrelation_plantstatus_id_fkey; Type: FK CONSTRAINT; Schema: public; Owner: - |
4551 | 4642 |
-- |
4552 | 4643 |
|
Also available in: Unified diff
schemas/vegbien.sql: Added placepath (analogous to taxonpath), and point locationplace to it instead of directly to namedplace