Revision 4621
Added by Aaron Marcuse-Kubitza almost 12 years ago
test.xml.ref | ||
---|---|---|
1 | 1 |
Put template: |
2 | 2 |
<VegBIEN> |
3 |
<location id="-1"> |
|
4 |
<parent_id><location><sourceaccessioncode>$PlotID</sourceaccessioncode></location></parent_id> |
|
5 |
<authorlocationcode>$QuadratID</authorlocationcode> |
|
6 |
<locationevent> |
|
7 |
<parent_id> |
|
3 |
<_simplifyPath id="-1"> |
|
4 |
<next>parent_id</next> |
|
5 |
<path> |
|
6 |
<location> |
|
7 |
<parent_id><location><sourceaccessioncode>$PlotID</sourceaccessioncode></location></parent_id> |
|
8 |
<authorlocationcode>$QuadratID</authorlocationcode> |
|
8 | 9 |
<locationevent> |
9 |
<location_id><location><sourceaccessioncode>$PlotID</sourceaccessioncode></location></location_id> |
|
10 |
<sourceaccessioncode>$CensusID</sourceaccessioncode> |
|
11 |
</locationevent> |
|
12 |
</parent_id> |
|
13 |
<taxonoccurrence> |
|
14 |
<aggregateoccurrence> |
|
15 |
<plantobservation> |
|
10 |
<parent_id> |
|
11 |
<locationevent> |
|
12 |
<location_id><location><sourceaccessioncode>$PlotID</sourceaccessioncode></location></location_id> |
|
13 |
<sourceaccessioncode>$CensusID</sourceaccessioncode> |
|
14 |
</locationevent> |
|
15 |
</parent_id> |
|
16 |
<taxonoccurrence> |
|
17 |
<aggregateoccurrence> |
|
18 |
<plantobservation> |
|
19 |
<sourceaccessioncode>$MeasureID</sourceaccessioncode> |
|
20 |
<stemobservation> |
|
21 |
<authorstemcode>$StemID</authorstemcode> |
|
22 |
<diameterbreastheight>$DBH</diameterbreastheight> |
|
23 |
<stemtag> |
|
24 |
<iscurrent>true</iscurrent> |
|
25 |
<tag> |
|
26 |
<_alt> |
|
27 |
<0>$StemTag</0> |
|
28 |
<1>$Tag</1> |
|
29 |
</_alt> |
|
30 |
</tag> |
|
31 |
</stemtag> |
|
32 |
<xposition>$x</xposition> |
|
33 |
<yposition>$y</yposition> |
|
34 |
</stemobservation> |
|
35 |
</plantobservation> |
|
36 |
</aggregateoccurrence> |
|
16 | 37 |
<sourceaccessioncode>$MeasureID</sourceaccessioncode> |
17 |
<stemobservation> |
|
18 |
<authorstemcode>$StemID</authorstemcode> |
|
19 |
<diameterbreastheight>$DBH</diameterbreastheight> |
|
20 |
<stemtag> |
|
21 |
<iscurrent>true</iscurrent> |
|
22 |
<tag> |
|
23 |
<_alt> |
|
24 |
<0>$StemTag</0> |
|
25 |
<1>$Tag</1> |
|
26 |
</_alt> |
|
27 |
</tag> |
|
28 |
</stemtag> |
|
29 |
<xposition>$x</xposition> |
|
30 |
<yposition>$y</yposition> |
|
31 |
</stemobservation> |
|
32 |
</plantobservation> |
|
33 |
</aggregateoccurrence> |
|
34 |
<sourceaccessioncode>$MeasureID</sourceaccessioncode> |
|
35 |
<taxondetermination> |
|
36 |
<plantconcept_id> |
|
37 |
<plantconcept> |
|
38 |
<plantname_id> |
|
39 |
<_simplifyPath> |
|
40 |
<next>parent_id</next> |
|
41 |
<path> |
|
42 |
<plantname> |
|
43 |
<rank>binomial</rank> |
|
44 |
<parent_id> |
|
38 |
<taxondetermination> |
|
39 |
<plantconcept_id> |
|
40 |
<plantconcept> |
|
41 |
<plantname_id> |
|
42 |
<_simplifyPath> |
|
43 |
<next>parent_id</next> |
|
44 |
<path> |
|
45 | 45 |
<plantname> |
46 |
<rank>authority</rank> |
|
47 |
<plantname>$SpeciesAuthority</plantname> |
|
46 |
<rank>binomial</rank> |
|
48 | 47 |
<parent_id> |
49 | 48 |
<plantname> |
50 |
<rank>subspecies</rank>
|
|
51 |
<plantname>$SubSpeciesName</plantname>
|
|
49 |
<rank>authority</rank>
|
|
50 |
<plantname>$SpeciesAuthority</plantname>
|
|
52 | 51 |
<parent_id> |
53 | 52 |
<plantname> |
54 |
<rank>species</rank> |
|
55 |
<plantname>$SpeciesName</plantname> |
|
53 |
<rank>subspecies</rank>
|
|
54 |
<plantname>$SubSpeciesName</plantname>
|
|
56 | 55 |
<parent_id> |
57 | 56 |
<plantname> |
58 |
<rank>genus</rank>
|
|
59 |
<plantname>$Genus</plantname>
|
|
57 |
<rank>species</rank>
|
|
58 |
<plantname>$SpeciesName</plantname>
|
|
60 | 59 |
<parent_id> |
61 | 60 |
<plantname> |
62 |
<rank>family</rank> |
|
63 |
<plantname>$Family</plantname> |
|
61 |
<rank>genus</rank> |
|
62 |
<plantname>$Genus</plantname> |
|
63 |
<parent_id> |
|
64 |
<plantname> |
|
65 |
<rank>family</rank> |
|
66 |
<plantname>$Family</plantname> |
|
67 |
</plantname> |
|
68 |
</parent_id> |
|
64 | 69 |
</plantname> |
65 | 70 |
</parent_id> |
66 | 71 |
</plantname> |
... | ... | |
70 | 75 |
</plantname> |
71 | 76 |
</parent_id> |
72 | 77 |
</plantname> |
73 |
</parent_id>
|
|
74 |
</plantname>
|
|
75 |
</path>
|
|
76 |
</_simplifyPath>
|
|
77 |
</plantname_id>
|
|
78 |
</plantconcept>
|
|
79 |
</plantconcept_id>
|
|
80 |
</taxondetermination>
|
|
81 |
</taxonoccurrence>
|
|
82 |
</locationevent>
|
|
83 |
</location>
|
|
78 |
</path>
|
|
79 |
</_simplifyPath>
|
|
80 |
</plantname_id>
|
|
81 |
</plantconcept>
|
|
82 |
</plantconcept_id>
|
|
83 |
</taxondetermination>
|
|
84 |
</taxonoccurrence>
|
|
85 |
</locationevent>
|
|
86 |
</location>
|
|
87 |
</path>
|
|
88 |
</_simplifyPath>
|
|
84 | 89 |
</VegBIEN> |
85 | 90 |
Inserted 19 new rows into database |
Also available in: Unified diff
mappings/VegCore-VegBIEN.csv: Added /_simplifyPath:[next=parent_id]/path to root so the returned subplot location will be its parent location if there is no subplot name or ID (indicating that that particular plot did not have subplots). Note that this also causes the parent_id forwarding effect to occur for all other tables containing parent_id, which will help prevent similar issues with subplot events, etc. This will hopefully fix the SALVIAS.plotObservations bug where some organisms did not have a subplot #, causing the subplot location to become NULL and causing the corresponding locationevent rows not to match the locationevent_unique_within_location index filter condition (which requires a parent_id), which caused multiple output table pkeys to be returned for those rows, violating the locationevent_pkeys temp table's primary key.