Project

General

Profile

1 9630 aaronmk
-- MySQL dump 10.13  Distrib 5.5.31, for debian-linux-gnu (x86_64)
2 8928 aaronmk
--
3 9630 aaronmk
-- Host: localhost    Database: VegCore
4 8928 aaronmk
-- ------------------------------------------------------
5 9852 aaronmk
-- Server version	5.5.31-0ubuntu0.12.04.2
6 10446 aaronmk
7
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
8
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
9
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
10
/*!40101 SET NAMES utf8 */;
11 8928 aaronmk
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
12
/*!40103 SET TIME_ZONE='+00:00' */;
13
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
14
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
15 10446 aaronmk
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
16 8928 aaronmk
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
17 8336 aaronmk
18 8928 aaronmk
--
19 10446 aaronmk
-- Table structure for table `aggregate_observation`
20 8928 aaronmk
--
21 8336 aaronmk
22 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
23
/*!40101 SET character_set_client = utf8 */;
24 10446 aaronmk
CREATE TABLE `aggregate_observation` (
25
  `id` varbinary(767) NOT NULL,
26
  `taxon_concept` varbinary(767) NOT NULL,
27
  `traits` set('hstore') COLLATE utf8_bin DEFAULT NULL,
28
  PRIMARY KEY (`id`),
29
  KEY `fk_aggregate_observation_taxon_name1_idx` (`taxon_concept`),
30
  CONSTRAINT `fk_aggregate_observation_taxon_occurrence1` FOREIGN KEY (`id`) REFERENCES `taxon_observation` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
31
  CONSTRAINT `fk_aggregate_observation_taxon_name1` FOREIGN KEY (`taxon_concept`) REFERENCES `taxon_concept` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
32
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='"An observation applying to all occurrences of an organism based on an aggregation factor" ("VegX":http://wiki.tdwg.org/twiki/pub/Vegetation/WebHome/VegX_Schema_1.5.3_proposed.zip#/veg.xsd#/aggregateOrganismObservations/aggregateOrganismObservation)';
33 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
34 8632 aaronmk
35 8928 aaronmk
--
36 10446 aaronmk
-- Dumping data for table `aggregate_observation`
37 8928 aaronmk
--
38 8336 aaronmk
39 10446 aaronmk
/*!40000 ALTER TABLE `aggregate_observation` DISABLE KEYS */;
40
/*!40000 ALTER TABLE `aggregate_observation` ENABLE KEYS */;
41 8336 aaronmk
42 8928 aaronmk
--
43 10446 aaronmk
-- Table structure for table `base_class`
44 8928 aaronmk
--
45 8632 aaronmk
46 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
47
/*!40101 SET character_set_client = utf8 */;
48 10446 aaronmk
CREATE TABLE `base_class` (
49
  `id` varbinary(767) NOT NULL,
50
  `referenced_class` varbinary(767) NOT NULL,
51
  PRIMARY KEY (`id`),
52
  KEY `fk_base_class_referenced_class1_idx` (`referenced_class`),
53
  CONSTRAINT `fk_base_class_referenced_class1` FOREIGN KEY (`referenced_class`) REFERENCES `referenced_class` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
54
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
55 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
56 8336 aaronmk
57 8928 aaronmk
--
58 10446 aaronmk
-- Dumping data for table `base_class`
59 8928 aaronmk
--
60 8336 aaronmk
61 10446 aaronmk
/*!40000 ALTER TABLE `base_class` DISABLE KEYS */;
62
/*!40000 ALTER TABLE `base_class` ENABLE KEYS */;
63 8632 aaronmk
64 8928 aaronmk
--
65 10446 aaronmk
-- Table structure for table `collection`
66 8928 aaronmk
--
67 8623 aaronmk
68 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
69
/*!40101 SET character_set_client = utf8 */;
70 10446 aaronmk
CREATE TABLE `collection` (
71
  `id` varbinary(767) NOT NULL,
72
  `institution` varbinary(767) NOT NULL,
73
  `name` varbinary(767) NOT NULL,
74
  PRIMARY KEY (`id`),
75
  UNIQUE KEY `collection_unique` (`institution`,`name`),
76
  KEY `fk_collection_organization1_idx` (`institution`),
77
  KEY `fk_collection_source1_idx` (`id`),
78
  CONSTRAINT `fk_collection_source1` FOREIGN KEY (`id`) REFERENCES `record` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
79
  CONSTRAINT `fk_collection_organization1` FOREIGN KEY (`institution`) REFERENCES `organization` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
80
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='"the collection within the institution where a specimen is held" ("Brad Boyle":https://projects.nceas.ucsb.edu/nceas/attachments/download/621/vegbien_identifier_examples.xlsx#terms/collectionCode)';
81 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
82 8623 aaronmk
83 8928 aaronmk
--
84 10446 aaronmk
-- Dumping data for table `collection`
85 8928 aaronmk
--
86 8632 aaronmk
87 10446 aaronmk
/*!40000 ALTER TABLE `collection` DISABLE KEYS */;
88
/*!40000 ALTER TABLE `collection` ENABLE KEYS */;
89 8336 aaronmk
90 8928 aaronmk
--
91 10446 aaronmk
-- Table structure for table `community`
92 8928 aaronmk
--
93 8336 aaronmk
94 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
95
/*!40101 SET character_set_client = utf8 */;
96 10446 aaronmk
CREATE TABLE `community` (
97
  `id` varbinary(767) NOT NULL,
98
  `name` varbinary(767) NOT NULL,
99
  `info` set('hstore') COLLATE utf8_bin DEFAULT NULL,
100
  PRIMARY KEY (`id`),
101
  CONSTRAINT `fk_community_record1` FOREIGN KEY (`id`) REFERENCES `record` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
102
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='"A community type is an abstract grouping of organisms that tend to co-occur on the landscape due to shared ecological requirements or preferences. May be designated by syntaxon or physiognomic types." ([[VegCore#VegX|VegX]])';
103 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
104 8677 aaronmk
105 8928 aaronmk
--
106 10446 aaronmk
-- Dumping data for table `community`
107 8928 aaronmk
--
108 8677 aaronmk
109 10446 aaronmk
/*!40000 ALTER TABLE `community` DISABLE KEYS */;
110
/*!40000 ALTER TABLE `community` ENABLE KEYS */;
111 8677 aaronmk
112 8928 aaronmk
--
113 10446 aaronmk
-- Table structure for table `coordinates`
114 8928 aaronmk
--
115 8632 aaronmk
116 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
117
/*!40101 SET character_set_client = utf8 */;
118 10446 aaronmk
CREATE TABLE `coordinates` (
119
  `id` varbinary(767) NOT NULL,
120
  `latitude_deg` varbinary(767) DEFAULT NULL,
121
  `longitude_deg` varbinary(767) DEFAULT NULL,
122
  PRIMARY KEY (`id`)
123
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='A numerically-defined point';
124 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
125 8623 aaronmk
126 8928 aaronmk
--
127 10446 aaronmk
-- Dumping data for table `coordinates`
128 8928 aaronmk
--
129 8623 aaronmk
130 10446 aaronmk
/*!40000 ALTER TABLE `coordinates` DISABLE KEYS */;
131
/*!40000 ALTER TABLE `coordinates` ENABLE KEYS */;
132 8632 aaronmk
133 8928 aaronmk
--
134 10446 aaronmk
-- Table structure for table `derived_class`
135 8928 aaronmk
--
136 8554 aaronmk
137 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
138
/*!40101 SET character_set_client = utf8 */;
139 10446 aaronmk
CREATE TABLE `derived_class` (
140
  `id` varbinary(767) NOT NULL,
141
  PRIMARY KEY (`id`),
142
  CONSTRAINT `fk_derived_class_base_class1` FOREIGN KEY (`id`) REFERENCES `base_class` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
143
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
144 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
145 8554 aaronmk
146 8928 aaronmk
--
147 10446 aaronmk
-- Dumping data for table `derived_class`
148 8928 aaronmk
--
149 8676 aaronmk
150 10446 aaronmk
/*!40000 ALTER TABLE `derived_class` DISABLE KEYS */;
151
/*!40000 ALTER TABLE `derived_class` ENABLE KEYS */;
152 8676 aaronmk
153 8928 aaronmk
--
154 10446 aaronmk
-- Table structure for table `event`
155 8928 aaronmk
--
156 8676 aaronmk
157 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
158
/*!40101 SET character_set_client = utf8 */;
159 10446 aaronmk
CREATE TABLE `event` (
160
  `id` varbinary(767) NOT NULL,
161
  `parent` varbinary(767) NOT NULL,
162
  `name` varbinary(767) DEFAULT NULL,
163
  `date_range` varbinary(767) DEFAULT NULL,
164
  `place` varbinary(767) DEFAULT NULL,
165
  `method` varbinary(767) DEFAULT NULL,
166
  PRIMARY KEY (`id`),
167
  KEY `fk_event_place1_idx` (`place`),
168
  KEY `fk_event1_idx` (`parent`),
169
  KEY `fk_event_method1_idx` (`method`),
170
  CONSTRAINT `fk_event_record1` FOREIGN KEY (`id`) REFERENCES `record` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
171
  CONSTRAINT `fk_event_place1` FOREIGN KEY (`place`) REFERENCES `place` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
172
  CONSTRAINT `fk_event1` FOREIGN KEY (`parent`) REFERENCES `event` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
173
  CONSTRAINT `fk_event_method1` FOREIGN KEY (`method`) REFERENCES `method` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
174
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='"an action that occurs at a place and during a period of time" ("DwC":http://rs.tdwg.org/dwc/terms/#Event)';
175 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
176 8632 aaronmk
177 8928 aaronmk
--
178 10446 aaronmk
-- Dumping data for table `event`
179 8928 aaronmk
--
180 8554 aaronmk
181 10446 aaronmk
/*!40000 ALTER TABLE `event` DISABLE KEYS */;
182
/*!40000 ALTER TABLE `event` ENABLE KEYS */;
183 8554 aaronmk
184 8928 aaronmk
--
185 10446 aaronmk
-- Table structure for table `event_participant`
186 8928 aaronmk
--
187 8632 aaronmk
188 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
189
/*!40101 SET character_set_client = utf8 */;
190 10446 aaronmk
CREATE TABLE `event_participant` (
191
  `event` varbinary(767) NOT NULL,
192
  `party` varbinary(767) NOT NULL,
193
  `sort_order` int(11) DEFAULT NULL,
194
  PRIMARY KEY (`event`,`party`),
195
  KEY `fk_event_has_party_party1_idx` (`party`),
196
  KEY `fk_event_has_party_event1_idx` (`event`),
197
  CONSTRAINT `fk_event_has_party_event1` FOREIGN KEY (`event`) REFERENCES `event` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
198
  CONSTRAINT `fk_event_has_party_party1` FOREIGN KEY (`party`) REFERENCES `party` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
199
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
200 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
201 8552 aaronmk
202 8928 aaronmk
--
203 10446 aaronmk
-- Dumping data for table `event_participant`
204 8928 aaronmk
--
205 8552 aaronmk
206 10446 aaronmk
/*!40000 ALTER TABLE `event_participant` DISABLE KEYS */;
207
/*!40000 ALTER TABLE `event_participant` ENABLE KEYS */;
208 8632 aaronmk
209 8928 aaronmk
--
210 10446 aaronmk
-- Table structure for table `geological_context`
211 8928 aaronmk
--
212 8521 aaronmk
213 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
214
/*!40101 SET character_set_client = utf8 */;
215 10446 aaronmk
CREATE TABLE `geological_context` (
216
  `id` varbinary(767) NOT NULL,
217
  `name` varbinary(767) NOT NULL,
218
  `info` set('hstore') COLLATE utf8_bin DEFAULT NULL,
219
  PRIMARY KEY (`id`),
220
  CONSTRAINT `fk_geological_context_record1` FOREIGN KEY (`id`) REFERENCES `record` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
221
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='"information pertaining to a location within a geological context, such as stratigraphy" ("DwC":http://rs.tdwg.org/dwc/terms/#GeologicalContext)';
222 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
223 8521 aaronmk
224 8928 aaronmk
--
225 10446 aaronmk
-- Dumping data for table `geological_context`
226 8928 aaronmk
--
227 8632 aaronmk
228 10446 aaronmk
/*!40000 ALTER TABLE `geological_context` DISABLE KEYS */;
229
/*!40000 ALTER TABLE `geological_context` ENABLE KEYS */;
230 8336 aaronmk
231 8928 aaronmk
--
232 10446 aaronmk
-- Table structure for table `geovalidation`
233 8928 aaronmk
--
234 8336 aaronmk
235 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
236
/*!40101 SET character_set_client = utf8 */;
237 10446 aaronmk
CREATE TABLE `geovalidation` (
238
  `id` varbinary(767) NOT NULL,
239
  `geovalid` tinyint(1) NOT NULL,
240
  `lat_long_domain_valid` tinyint(1) NOT NULL,
241
  `lat_long_in_ranks` set('hstore') COLLATE utf8_bin DEFAULT NULL,
242
  PRIMARY KEY (`id`),
243
  CONSTRAINT `fk_geovalidation_validatable_place1` FOREIGN KEY (`id`) REFERENCES `validatable_place` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
244
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='The accuracy of the [[VegCore#Coordinates|Coordinates]], taking into account the [[VegCore#Placename|Placename]]';
245 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
246 8632 aaronmk
247 8928 aaronmk
--
248 10446 aaronmk
-- Dumping data for table `geovalidation`
249 8928 aaronmk
--
250 8567 aaronmk
251 10446 aaronmk
/*!40000 ALTER TABLE `geovalidation` DISABLE KEYS */;
252
/*!40000 ALTER TABLE `geovalidation` ENABLE KEYS */;
253 8567 aaronmk
254 8928 aaronmk
--
255 10446 aaronmk
-- Table structure for table `individual`
256 8928 aaronmk
--
257 8632 aaronmk
258 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
259
/*!40101 SET character_set_client = utf8 */;
260 10446 aaronmk
CREATE TABLE `individual` (
261
  `id` varbinary(767) NOT NULL,
262
  `tag` varbinary(767) DEFAULT NULL,
263
  PRIMARY KEY (`id`),
264
  CONSTRAINT `fk_individual_record1` FOREIGN KEY (`id`) REFERENCES `taxon_occurrence` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
265
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='A distinct biological organism';
266 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
267 8336 aaronmk
268 8928 aaronmk
--
269 10446 aaronmk
-- Dumping data for table `individual`
270 8928 aaronmk
--
271 8336 aaronmk
272 10446 aaronmk
/*!40000 ALTER TABLE `individual` DISABLE KEYS */;
273
/*!40000 ALTER TABLE `individual` ENABLE KEYS */;
274 8632 aaronmk
275 8928 aaronmk
--
276 10446 aaronmk
-- Table structure for table `individual_observation`
277 8928 aaronmk
--
278 8336 aaronmk
279 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
280
/*!40101 SET character_set_client = utf8 */;
281 10446 aaronmk
CREATE TABLE `individual_observation` (
282
  `id` varbinary(767) NOT NULL,
283
  `individual` varbinary(767) DEFAULT NULL,
284
  `code` varbinary(767) DEFAULT NULL,
285
  `traits` set('hstore') COLLATE utf8_bin DEFAULT NULL,
286
  PRIMARY KEY (`id`),
287
  KEY `fk_individual_observation_individual1_idx` (`individual`),
288
  CONSTRAINT `fk_individual_observation_taxon_occurrence1` FOREIGN KEY (`id`) REFERENCES `taxon_observation` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
289
  CONSTRAINT `fk_individual_observation_individual1` FOREIGN KEY (`individual`) REFERENCES `individual` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
290
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='An observation of an [[VegCore#Individual|Individual]]';
291 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
292 8336 aaronmk
293 8928 aaronmk
--
294 10446 aaronmk
-- Dumping data for table `individual_observation`
295 8928 aaronmk
--
296 8632 aaronmk
297 10446 aaronmk
/*!40000 ALTER TABLE `individual_observation` DISABLE KEYS */;
298
/*!40000 ALTER TABLE `individual_observation` ENABLE KEYS */;
299 8336 aaronmk
300 8928 aaronmk
--
301 10446 aaronmk
-- Table structure for table `method`
302 8928 aaronmk
--
303 8336 aaronmk
304 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
305
/*!40101 SET character_set_client = utf8 */;
306 10446 aaronmk
CREATE TABLE `method` (
307
  `id` varbinary(767) NOT NULL,
308
  `parent` varbinary(767) NOT NULL,
309
  `info` set('hstore') COLLATE utf8_bin DEFAULT NULL,
310
  PRIMARY KEY (`id`),
311
  KEY `fk_method_method1_idx` (`parent`),
312
  CONSTRAINT `fk_method_record1` FOREIGN KEY (`id`) REFERENCES `record` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
313
  CONSTRAINT `fk_method_method1` FOREIGN KEY (`parent`) REFERENCES `method` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
314
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='"A specific method definition followed in the creation of the dataset. Each method links to a protocol and literature citation reference. A protocol may have many method or steps." ("VegX":http://wiki.tdwg.org/twiki/pub/Vegetation/WebHome/VegX_Schema_1.5.3_proposed.zip#/veg.xsd#/methods/method)';
315 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
316 8632 aaronmk
317 8928 aaronmk
--
318 10446 aaronmk
-- Dumping data for table `method`
319 8928 aaronmk
--
320 8623 aaronmk
321 10446 aaronmk
/*!40000 ALTER TABLE `method` DISABLE KEYS */;
322
/*!40000 ALTER TABLE `method` ENABLE KEYS */;
323 8623 aaronmk
324 8928 aaronmk
--
325 10446 aaronmk
-- Table structure for table `organization`
326 8928 aaronmk
--
327 8632 aaronmk
328 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
329
/*!40101 SET character_set_client = utf8 */;
330 10446 aaronmk
CREATE TABLE `organization` (
331
  `id` varbinary(767) NOT NULL,
332
  `info` set('hstore') COLLATE utf8_bin DEFAULT NULL,
333
  PRIMARY KEY (`id`),
334
  CONSTRAINT `fk_organization_party1` FOREIGN KEY (`id`) REFERENCES `party` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
335
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
336 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
337 8581 aaronmk
338 8928 aaronmk
--
339 10446 aaronmk
-- Dumping data for table `organization`
340 8928 aaronmk
--
341 8581 aaronmk
342 10446 aaronmk
/*!40000 ALTER TABLE `organization` DISABLE KEYS */;
343
/*!40000 ALTER TABLE `organization` ENABLE KEYS */;
344 8632 aaronmk
345 8928 aaronmk
--
346 10446 aaronmk
-- Table structure for table `parsed_taxon_assertion`
347 8928 aaronmk
--
348 8581 aaronmk
349 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
350
/*!40101 SET character_set_client = utf8 */;
351 10446 aaronmk
CREATE TABLE `parsed_taxon_assertion` (
352
  `id` varbinary(767) NOT NULL,
353
  `matched_taxon_concept` varbinary(767) DEFAULT NULL,
354
  `match_score` float DEFAULT NULL,
355
  `match_info` set('hstore') COLLATE utf8_bin DEFAULT NULL,
356
  PRIMARY KEY (`id`),
357
  KEY `fk_parsed_taxon_assertion_taxon_name1_idx` (`matched_taxon_concept`),
358
  CONSTRAINT `fk_matched_taxon_qualified_taxon10` FOREIGN KEY (`id`) REFERENCES `taxon_assertion` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
359
  CONSTRAINT `fk_parsed_taxon_assertion_taxon_name1` FOREIGN KEY (`matched_taxon_concept`) REFERENCES `taxon_concept` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
360
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
361 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
362 8581 aaronmk
363 8928 aaronmk
--
364 10446 aaronmk
-- Dumping data for table `parsed_taxon_assertion`
365 8928 aaronmk
--
366 8632 aaronmk
367 10446 aaronmk
/*!40000 ALTER TABLE `parsed_taxon_assertion` DISABLE KEYS */;
368
/*!40000 ALTER TABLE `parsed_taxon_assertion` ENABLE KEYS */;
369 8336 aaronmk
370 8928 aaronmk
--
371 10446 aaronmk
-- Table structure for table `party`
372 8928 aaronmk
--
373 8336 aaronmk
374 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
375
/*!40101 SET character_set_client = utf8 */;
376 10446 aaronmk
CREATE TABLE `party` (
377
  `id` varbinary(767) NOT NULL,
378
  `info` set('hstore') COLLATE utf8_bin DEFAULT NULL,
379
  PRIMARY KEY (`id`),
380
  CONSTRAINT `fk_collection_source10` FOREIGN KEY (`id`) REFERENCES `record` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
381 10449 aaronmk
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
382 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
383 8632 aaronmk
384 8928 aaronmk
--
385 10446 aaronmk
-- Dumping data for table `party`
386 8928 aaronmk
--
387 8336 aaronmk
388 10446 aaronmk
/*!40000 ALTER TABLE `party` DISABLE KEYS */;
389
/*!40000 ALTER TABLE `party` ENABLE KEYS */;
390 8336 aaronmk
391 8928 aaronmk
--
392 10446 aaronmk
-- Table structure for table `place`
393 8928 aaronmk
--
394 8632 aaronmk
395 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
396
/*!40101 SET character_set_client = utf8 */;
397 10446 aaronmk
CREATE TABLE `place` (
398
  `id` varbinary(767) NOT NULL,
399
  `parent` varbinary(767) NOT NULL,
400
  `coordinates` varbinary(767) DEFAULT NULL,
401
  `path` varbinary(767) DEFAULT NULL,
402
  `locality` varbinary(767) DEFAULT NULL,
403
  PRIMARY KEY (`id`),
404
  KEY `fk_place_coordinates1_idx` (`coordinates`),
405
  KEY `fk_place1_idx` (`parent`),
406
  KEY `fk_place_place_path1_idx` (`path`),
407
  CONSTRAINT `fk_place_record1` FOREIGN KEY (`id`) REFERENCES `record` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
408
  CONSTRAINT `fk_place_coordinates1` FOREIGN KEY (`coordinates`) REFERENCES `coordinates` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
409
  CONSTRAINT `fk_place1` FOREIGN KEY (`parent`) REFERENCES `place` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
410
  CONSTRAINT `fk_place_place_path1` FOREIGN KEY (`path`) REFERENCES `place_path` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
411
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='"A spatial region" ("DwC":http://rs.tdwg.org/dwc/terms/#dcterms:Location) or point';
412 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
413 8336 aaronmk
414 8928 aaronmk
--
415 10446 aaronmk
-- Dumping data for table `place`
416 8928 aaronmk
--
417 8336 aaronmk
418 10446 aaronmk
/*!40000 ALTER TABLE `place` DISABLE KEYS */;
419
/*!40000 ALTER TABLE `place` ENABLE KEYS */;
420 8632 aaronmk
421 8928 aaronmk
--
422 10446 aaronmk
-- Table structure for table `place_observation`
423 8928 aaronmk
--
424 8573 aaronmk
425 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
426
/*!40101 SET character_set_client = utf8 */;
427 10446 aaronmk
CREATE TABLE `place_observation` (
428
  `id` varbinary(767) NOT NULL,
429
  `place` varbinary(767) NOT NULL,
430
  `elevation_m` double DEFAULT NULL,
431
  `slope_incline_deg` double DEFAULT NULL,
432
  `slope_direction_deg_N` double DEFAULT NULL,
433
  `geological_context` varbinary(767) DEFAULT NULL,
434
  `community` varbinary(767) DEFAULT NULL,
435
  `observations` set('hstore') COLLATE utf8_bin DEFAULT NULL,
436
  PRIMARY KEY (`id`),
437
  KEY `fk_place_observation_place1_idx` (`place`),
438
  KEY `fk_place_observation_geological_context1_idx` (`geological_context`),
439
  KEY `fk_place_observation_community1_idx` (`community`),
440
  KEY `fk_place_observation_event1_idx` (`id`),
441
  CONSTRAINT `fk_place_observation_place1` FOREIGN KEY (`place`) REFERENCES `place` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
442
  CONSTRAINT `fk_place_observation_geological_context1` FOREIGN KEY (`geological_context`) REFERENCES `geological_context` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
443
  CONSTRAINT `fk_place_observation_community1` FOREIGN KEY (`community`) REFERENCES `community` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
444
  CONSTRAINT `fk_place_observation_event1` FOREIGN KEY (`id`) REFERENCES `event` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
445
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='A sampling of a [[VegCore#Location|Location]]';
446 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
447 8573 aaronmk
448 8928 aaronmk
--
449 10446 aaronmk
-- Dumping data for table `place_observation`
450 8928 aaronmk
--
451 8632 aaronmk
452 10446 aaronmk
/*!40000 ALTER TABLE `place_observation` DISABLE KEYS */;
453
/*!40000 ALTER TABLE `place_observation` ENABLE KEYS */;
454 8336 aaronmk
455 8928 aaronmk
--
456 10446 aaronmk
-- Table structure for table `place_path`
457 8928 aaronmk
--
458 8336 aaronmk
459 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
460
/*!40101 SET character_set_client = utf8 */;
461 10446 aaronmk
CREATE TABLE `place_path` (
462
  `id` varbinary(767) NOT NULL,
463
  `continent` varbinary(767) DEFAULT NULL,
464
  `country` varbinary(767) DEFAULT NULL,
465
  `state_province` varbinary(767) DEFAULT NULL,
466
  `county` varbinary(767) DEFAULT NULL,
467
  `municipality` varbinary(767) DEFAULT NULL,
468
  `ranks` set('hstore') COLLATE utf8_bin DEFAULT NULL,
469
  PRIMARY KEY (`id`)
470
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='A named region';
471 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
472 8632 aaronmk
473 8928 aaronmk
--
474 10446 aaronmk
-- Dumping data for table `place_path`
475 8928 aaronmk
--
476 8336 aaronmk
477 10446 aaronmk
/*!40000 ALTER TABLE `place_path` DISABLE KEYS */;
478
/*!40000 ALTER TABLE `place_path` ENABLE KEYS */;
479 8336 aaronmk
480 8928 aaronmk
--
481 10446 aaronmk
-- Table structure for table `plot`
482 8928 aaronmk
--
483 8632 aaronmk
484 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
485
/*!40101 SET character_set_client = utf8 */;
486 10446 aaronmk
CREATE TABLE `plot` (
487
  `id` varbinary(767) NOT NULL,
488
  `name` varbinary(767) DEFAULT NULL,
489
  `area_m2` double DEFAULT NULL,
490
  `bounding_box` varbinary(767) DEFAULT NULL,
491
  PRIMARY KEY (`id`),
492
  CONSTRAINT `fk_subplot_place1` FOREIGN KEY (`id`) REFERENCES `place` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
493
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
494 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
495 8336 aaronmk
496 8928 aaronmk
--
497 10446 aaronmk
-- Dumping data for table `plot`
498 8928 aaronmk
--
499 8336 aaronmk
500 10446 aaronmk
/*!40000 ALTER TABLE `plot` DISABLE KEYS */;
501
/*!40000 ALTER TABLE `plot` ENABLE KEYS */;
502 8632 aaronmk
503 8928 aaronmk
--
504 10446 aaronmk
-- Table structure for table `project`
505 8928 aaronmk
--
506 8336 aaronmk
507 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
508
/*!40101 SET character_set_client = utf8 */;
509 10446 aaronmk
CREATE TABLE `project` (
510
  `id` varbinary(767) NOT NULL,
511
  `name` varbinary(767) NOT NULL,
512
  `info` set('hstore') COLLATE utf8_bin DEFAULT NULL,
513
  PRIMARY KEY (`id`),
514
  CONSTRAINT `fk_project_event1` FOREIGN KEY (`id`) REFERENCES `event` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
515
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='A "project established to collect vegetation plot data. Each plot originates as part of a project." ("VegBank":http://vegbank.org/vegbank/views/dba_tabledescription_detail.jsp?view=detail&wparam=project&entity=dba_tabledescription&where=where_tablename)';
516 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
517 8336 aaronmk
518 8928 aaronmk
--
519 10446 aaronmk
-- Dumping data for table `project`
520 8928 aaronmk
--
521 8632 aaronmk
522 10446 aaronmk
/*!40000 ALTER TABLE `project` DISABLE KEYS */;
523
/*!40000 ALTER TABLE `project` ENABLE KEYS */;
524 8336 aaronmk
525 8928 aaronmk
--
526 10446 aaronmk
-- Table structure for table `record`
527 8928 aaronmk
--
528 8336 aaronmk
529 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
530
/*!40101 SET character_set_client = utf8 */;
531 10446 aaronmk
CREATE TABLE `record` (
532
  `id` varbinary(767) NOT NULL,
533
  `source` varbinary(767) NOT NULL,
534
  `source_id_scope` varbinary(767) DEFAULT NULL,
535
  `source_record_id` varbinary(767) DEFAULT NULL,
536
  `info` set('hstore') COLLATE utf8_bin DEFAULT NULL,
537
  PRIMARY KEY (`id`),
538
  UNIQUE KEY `record_unique` (`source`,`source_id_scope`,`source_record_id`),
539
  KEY `fk_record_source1_idx` (`source`),
540
  CONSTRAINT `fk_record_source1` FOREIGN KEY (`source`) REFERENCES `source` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
541
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
542 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
543 8632 aaronmk
544 8928 aaronmk
--
545 10446 aaronmk
-- Dumping data for table `record`
546 8928 aaronmk
--
547 8532 aaronmk
548 10446 aaronmk
/*!40000 ALTER TABLE `record` DISABLE KEYS */;
549
/*!40000 ALTER TABLE `record` ENABLE KEYS */;
550 8532 aaronmk
551 8928 aaronmk
--
552 10446 aaronmk
-- Table structure for table `referenced_class`
553 8928 aaronmk
--
554 8632 aaronmk
555 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
556
/*!40101 SET character_set_client = utf8 */;
557 10446 aaronmk
CREATE TABLE `referenced_class` (
558
  `id` varbinary(767) NOT NULL,
559
  PRIMARY KEY (`id`),
560
  CONSTRAINT `fk_example_record10` FOREIGN KEY (`id`) REFERENCES `record` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
561
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
562 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
563 8565 aaronmk
564 8928 aaronmk
--
565 10446 aaronmk
-- Dumping data for table `referenced_class`
566 8928 aaronmk
--
567 8565 aaronmk
568 10446 aaronmk
/*!40000 ALTER TABLE `referenced_class` DISABLE KEYS */;
569
/*!40000 ALTER TABLE `referenced_class` ENABLE KEYS */;
570 8632 aaronmk
571 8928 aaronmk
--
572 10446 aaronmk
-- Table structure for table `relationship`
573 8928 aaronmk
--
574 8623 aaronmk
575 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
576
/*!40101 SET character_set_client = utf8 */;
577 10446 aaronmk
CREATE TABLE `relationship` (
578
  `id` varbinary(767) NOT NULL,
579
  `record` varbinary(767) NOT NULL,
580
  `related_record` varbinary(767) NOT NULL,
581
  `info` set('hstore') COLLATE utf8_bin DEFAULT NULL,
582
  PRIMARY KEY (`id`),
583
  KEY `fk_relationship_record1_idx` (`record`),
584
  KEY `fk_relationship_related_record_idx` (`related_record`),
585
  CONSTRAINT `fk_relationship_record1` FOREIGN KEY (`id`) REFERENCES `record` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
586
  CONSTRAINT `fk_relationship_record2` FOREIGN KEY (`record`) REFERENCES `record` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
587
  CONSTRAINT `fk_relationship_related_record` FOREIGN KEY (`related_record`) REFERENCES `record` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
588
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='"information pertaining to relationships between resources (instances of data records, such as Occurrences, Taxa, Locations, Events)" ("DwC":http://rs.tdwg.org/dwc/terms/#ResourceRelationship)';
589 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
590 8623 aaronmk
591 8928 aaronmk
--
592 10446 aaronmk
-- Dumping data for table `relationship`
593 8928 aaronmk
--
594 8632 aaronmk
595 10446 aaronmk
/*!40000 ALTER TABLE `relationship` DISABLE KEYS */;
596
/*!40000 ALTER TABLE `relationship` ENABLE KEYS */;
597 8623 aaronmk
598 8928 aaronmk
--
599 10446 aaronmk
-- Table structure for table `soil_observation`
600 8928 aaronmk
--
601 8623 aaronmk
602 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
603
/*!40101 SET character_set_client = utf8 */;
604 10446 aaronmk
CREATE TABLE `soil_observation` (
605
  `id` varbinary(767) NOT NULL,
606
  `observations` set('hstore') COLLATE utf8_bin DEFAULT NULL,
607
  PRIMARY KEY (`id`),
608
  CONSTRAINT `fk_soil_observation_place_observation1` FOREIGN KEY (`id`) REFERENCES `place_observation` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
609
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='A sampling of a [[VegCore#Location|Location]]''s soil';
610 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
611 8632 aaronmk
612 8928 aaronmk
--
613 10446 aaronmk
-- Dumping data for table `soil_observation`
614 8928 aaronmk
--
615 8623 aaronmk
616 10446 aaronmk
/*!40000 ALTER TABLE `soil_observation` DISABLE KEYS */;
617
/*!40000 ALTER TABLE `soil_observation` ENABLE KEYS */;
618 8623 aaronmk
619 8928 aaronmk
--
620 10446 aaronmk
-- Table structure for table `source`
621 8928 aaronmk
--
622 8632 aaronmk
623 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
624
/*!40101 SET character_set_client = utf8 */;
625 10446 aaronmk
CREATE TABLE `source` (
626
  `id` varbinary(767) NOT NULL,
627
  `parent` varbinary(767) NOT NULL,
628
  `name` varbinary(767) NOT NULL,
629
  `first_publisher` varbinary(767) DEFAULT NULL,
630
  `owner` varbinary(767) DEFAULT NULL,
631
  `info` set('hstore') COLLATE utf8_bin DEFAULT NULL,
632
  PRIMARY KEY (`id`),
633
  UNIQUE KEY `source_unique` (`parent`,`name`),
634
  KEY `fk_source1_idx` (`parent`),
635
  KEY `fk_source_party1_idx` (`owner`),
636
  KEY `fk_source_party2_idx` (`first_publisher`),
637
  CONSTRAINT `fk_source1` FOREIGN KEY (`parent`) REFERENCES `source` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
638
  CONSTRAINT `fk_source_party1` FOREIGN KEY (`owner`) REFERENCES `party` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
639
  CONSTRAINT `fk_source_party2` FOREIGN KEY (`first_publisher`) REFERENCES `party` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
640
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='a "reference [...] cited within the database" ("VegBank":http://vegbank.org/vegbank/views/dba_tabledescription_detail.jsp?view=detail&wparam=reference&entity=dba_tabledescription&where=where_tablename)';
641 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
642 8336 aaronmk
643 8928 aaronmk
--
644 10446 aaronmk
-- Dumping data for table `source`
645 8928 aaronmk
--
646 8336 aaronmk
647 10446 aaronmk
/*!40000 ALTER TABLE `source` DISABLE KEYS */;
648
/*!40000 ALTER TABLE `source` ENABLE KEYS */;
649 8632 aaronmk
650 8928 aaronmk
--
651 10446 aaronmk
-- Table structure for table `specimen`
652 8928 aaronmk
--
653 8336 aaronmk
654 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
655
/*!40101 SET character_set_client = utf8 */;
656 10446 aaronmk
CREATE TABLE `specimen` (
657
  `id` varbinary(767) NOT NULL,
658
  `individual` varbinary(767) DEFAULT NULL,
659
  `code_in_individual` varbinary(767) DEFAULT NULL,
660
  `collection_event` varbinary(767) DEFAULT NULL,
661
  `orig_collection` varbinary(767) DEFAULT NULL,
662
  `barcode` varbinary(767) DEFAULT NULL,
663
  `accession_number` varbinary(767) DEFAULT NULL,
664
  `current_collection` varbinary(767) DEFAULT NULL,
665
  `owner_collection` varbinary(767) DEFAULT NULL,
666
  PRIMARY KEY (`id`),
667
  UNIQUE KEY `specimen_unique_in_individual` (`individual`,`code_in_individual`),
668
  UNIQUE KEY `specimen_unique_by_collection_event` (`collection_event`),
669
  UNIQUE KEY `specimen_unique_in_collection_by_barcode` (`orig_collection`,`barcode`),
670
  UNIQUE KEY `specimen_unique_in_collection_by_accession_number` (`orig_collection`,`accession_number`),
671
  KEY `fk_specimen_collection1_idx` (`orig_collection`),
672
  KEY `fk_specimen_taxon_observation1_idx` (`collection_event`),
673
  KEY `fk_specimen_individual1_idx` (`individual`),
674
  KEY `fk_specimen_collection2_idx` (`current_collection`),
675
  KEY `fk_specimen_organization3_idx` (`owner_collection`),
676
  CONSTRAINT `fk_specimen_taxon_occurrence1` FOREIGN KEY (`id`) REFERENCES `taxon_occurrence` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
677
  CONSTRAINT `fk_specimen_collection1` FOREIGN KEY (`orig_collection`) REFERENCES `collection` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
678
  CONSTRAINT `fk_specimen_organization3` FOREIGN KEY (`owner_collection`) REFERENCES `collection` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
679
  CONSTRAINT `fk_specimen_taxon_observation1` FOREIGN KEY (`collection_event`) REFERENCES `taxon_observation` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
680
  CONSTRAINT `fk_specimen_individual1` FOREIGN KEY (`individual`) REFERENCES `individual` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
681
  CONSTRAINT `fk_specimen_collection2` FOREIGN KEY (`current_collection`) REFERENCES `collection` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
682
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='A "part of a plant" ("Wikipedia":http://en.wikipedia.org/wiki/Specimen) which was collected from it';
683 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
684 8521 aaronmk
685 8928 aaronmk
--
686 10446 aaronmk
-- Dumping data for table `specimen`
687 8928 aaronmk
--
688 8632 aaronmk
689 10446 aaronmk
/*!40000 ALTER TABLE `specimen` DISABLE KEYS */;
690
/*!40000 ALTER TABLE `specimen` ENABLE KEYS */;
691 8521 aaronmk
692 8928 aaronmk
--
693 10446 aaronmk
-- Table structure for table `specimen_observation`
694 8928 aaronmk
--
695 8521 aaronmk
696 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
697
/*!40101 SET character_set_client = utf8 */;
698 10446 aaronmk
CREATE TABLE `specimen_observation` (
699
  `id` varbinary(767) NOT NULL,
700
  `specimen` varbinary(767) NOT NULL,
701
  `traits` set('hstore') COLLATE utf8_bin DEFAULT NULL,
702
  PRIMARY KEY (`id`),
703
  KEY `fk_specimen_observation_specimen1_idx` (`specimen`),
704
  CONSTRAINT `fk_specimen_taxon_occurrence10` FOREIGN KEY (`id`) REFERENCES `taxon_observation` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
705
  CONSTRAINT `fk_specimen_observation_specimen1` FOREIGN KEY (`specimen`) REFERENCES `specimen` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
706
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
707 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
708 8632 aaronmk
709 8928 aaronmk
--
710 10446 aaronmk
-- Dumping data for table `specimen_observation`
711 8928 aaronmk
--
712 8521 aaronmk
713 10446 aaronmk
/*!40000 ALTER TABLE `specimen_observation` DISABLE KEYS */;
714
/*!40000 ALTER TABLE `specimen_observation` ENABLE KEYS */;
715 8521 aaronmk
716 8928 aaronmk
--
717 10446 aaronmk
-- Table structure for table `specimenholder_institution`
718 9617 aaronmk
--
719
720 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
721
/*!40101 SET character_set_client = utf8 */;
722 10446 aaronmk
CREATE TABLE `specimenholder_institution` (
723
  `specimen` varbinary(767) NOT NULL,
724
  `institution` varbinary(767) NOT NULL,
725
  `sort_order` int(11) DEFAULT NULL,
726
  PRIMARY KEY (`specimen`,`institution`),
727
  KEY `fk_specimen_has_organization_organization1_idx` (`institution`),
728
  KEY `fk_specimen_has_organization_specimen1_idx` (`specimen`),
729
  CONSTRAINT `fk_specimen_has_organization_specimen1` FOREIGN KEY (`specimen`) REFERENCES `specimen` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
730
  CONSTRAINT `fk_specimen_has_organization_organization1` FOREIGN KEY (`institution`) REFERENCES `organization` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
731
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
732 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
733 9617 aaronmk
734
--
735 10446 aaronmk
-- Dumping data for table `specimenholder_institution`
736 9617 aaronmk
--
737
738 10446 aaronmk
/*!40000 ALTER TABLE `specimenholder_institution` DISABLE KEYS */;
739
/*!40000 ALTER TABLE `specimenholder_institution` ENABLE KEYS */;
740 9617 aaronmk
741
--
742 10446 aaronmk
-- Table structure for table `stem`
743 8928 aaronmk
--
744 8632 aaronmk
745 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
746
/*!40101 SET character_set_client = utf8 */;
747 10446 aaronmk
CREATE TABLE `stem` (
748
  `id` varbinary(767) NOT NULL,
749
  `individual` varbinary(767) NOT NULL,
750
  PRIMARY KEY (`id`),
751
  KEY `fk_stem_individual1_idx` (`individual`),
752
  CONSTRAINT `fk_stem_individual1` FOREIGN KEY (`individual`) REFERENCES `individual` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
753
  CONSTRAINT `fk_stem_individual2` FOREIGN KEY (`id`) REFERENCES `individual` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
754
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='An "individual tree stem" ("VegBank":http://vegbank.org/vegbank/views/dba_tabledescription_detail.jsp?view=detail&wparam=stemlocation&entity=dba_tabledescription&where=where_tablename)';
755 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
756 8521 aaronmk
757 8928 aaronmk
--
758 10446 aaronmk
-- Dumping data for table `stem`
759 8928 aaronmk
--
760 8533 aaronmk
761 10446 aaronmk
/*!40000 ALTER TABLE `stem` DISABLE KEYS */;
762
/*!40000 ALTER TABLE `stem` ENABLE KEYS */;
763 8632 aaronmk
764 8928 aaronmk
--
765 10446 aaronmk
-- Table structure for table `stem_observation`
766 8928 aaronmk
--
767 8561 aaronmk
768 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
769
/*!40101 SET character_set_client = utf8 */;
770 10446 aaronmk
CREATE TABLE `stem_observation` (
771
  `id` varbinary(767) NOT NULL,
772
  `individual_observation` varbinary(767) NOT NULL,
773
  `stem` varbinary(767) DEFAULT NULL,
774
  `traits` set('hstore') COLLATE utf8_bin DEFAULT NULL,
775
  PRIMARY KEY (`id`),
776
  UNIQUE KEY `stem_observation_unique` (`individual_observation`,`stem`),
777
  KEY `fk_stem_observation_individual_observation1_idx` (`individual_observation`),
778
  KEY `fk_stem_observation_stem1_idx` (`stem`),
779
  CONSTRAINT `fk_stem_observation_individual_observation1` FOREIGN KEY (`individual_observation`) REFERENCES `individual_observation` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
780
  CONSTRAINT `fk_stem_observation_stem1` FOREIGN KEY (`stem`) REFERENCES `stem` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
781
  CONSTRAINT `fk_stem_observation_individual_observation2` FOREIGN KEY (`id`) REFERENCES `individual_observation` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
782
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='An observation of a [[VegCore#Stem|Stem]]';
783 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
784 8567 aaronmk
785 8928 aaronmk
--
786 10446 aaronmk
-- Dumping data for table `stem_observation`
787 8928 aaronmk
--
788 8632 aaronmk
789 10446 aaronmk
/*!40000 ALTER TABLE `stem_observation` DISABLE KEYS */;
790
/*!40000 ALTER TABLE `stem_observation` ENABLE KEYS */;
791 8567 aaronmk
792 8928 aaronmk
--
793 10446 aaronmk
-- Table structure for table `stratum`
794 8928 aaronmk
--
795 8573 aaronmk
796 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
797
/*!40101 SET character_set_client = utf8 */;
798 10446 aaronmk
CREATE TABLE `stratum` (
799
  `id` varbinary(767) NOT NULL,
800
  `name` varbinary(767) NOT NULL,
801
  `info` set('hstore') COLLATE utf8_bin DEFAULT NULL,
802
  PRIMARY KEY (`id`),
803
  CONSTRAINT `fk_place_path_record10` FOREIGN KEY (`id`) REFERENCES `method` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
804
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
805 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
806 8632 aaronmk
807 8928 aaronmk
--
808 10446 aaronmk
-- Dumping data for table `stratum`
809 8928 aaronmk
--
810 8573 aaronmk
811 10446 aaronmk
/*!40000 ALTER TABLE `stratum` DISABLE KEYS */;
812
/*!40000 ALTER TABLE `stratum` ENABLE KEYS */;
813 8581 aaronmk
814 8928 aaronmk
--
815 10446 aaronmk
-- Table structure for table `subplot`
816 8928 aaronmk
--
817 8632 aaronmk
818 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
819
/*!40101 SET character_set_client = utf8 */;
820 10446 aaronmk
CREATE TABLE `subplot` (
821
  `id` varbinary(767) NOT NULL,
822
  `x_m` double DEFAULT NULL,
823
  `y_m` double DEFAULT NULL,
824
  PRIMARY KEY (`id`),
825
  CONSTRAINT `fk_subplot_plot1` FOREIGN KEY (`id`) REFERENCES `plot` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
826
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='"subplot, line, or any other subsample  or subdivision of plot" ("SALVIAS":http://salvias.net/Documents/salvias_data_dictionary.html#Plot_data/subplot)';
827 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
828 8581 aaronmk
829 8928 aaronmk
--
830 10446 aaronmk
-- Dumping data for table `subplot`
831 8928 aaronmk
--
832 8593 aaronmk
833 10446 aaronmk
/*!40000 ALTER TABLE `subplot` DISABLE KEYS */;
834
/*!40000 ALTER TABLE `subplot` ENABLE KEYS */;
835 8632 aaronmk
836 8928 aaronmk
--
837 10446 aaronmk
-- Table structure for table `taxon_assertion`
838 8928 aaronmk
--
839 8593 aaronmk
840 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
841
/*!40101 SET character_set_client = utf8 */;
842 10446 aaronmk
CREATE TABLE `taxon_assertion` (
843
  `id` varbinary(767) NOT NULL,
844
  `string` varbinary(767) NOT NULL COMMENT 'for parsed_taxon_assertion, this is the TNRS input name, not the concatenated matched name',
845
  `taxon` varbinary(767) DEFAULT NULL,
846
  `cf_aff` varbinary(767) DEFAULT NULL,
847
  `annotations` set('hstore') COLLATE utf8_bin DEFAULT NULL,
848
  PRIMARY KEY (`id`),
849
  KEY `fk_taxon_assertion_taxon_string1_idx` (`string`),
850
  KEY `fk_taxon_assertion_taxon_name1_idx` (`taxon`),
851
  CONSTRAINT `fk_qualified_taxon_record1` FOREIGN KEY (`id`) REFERENCES `record` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
852
  CONSTRAINT `fk_taxon_assertion_taxon_string1` FOREIGN KEY (`string`) REFERENCES `taxon_string` (`string`) ON DELETE CASCADE ON UPDATE CASCADE,
853
  CONSTRAINT `fk_taxon_assertion_taxon_name1` FOREIGN KEY (`taxon`) REFERENCES `taxon_name` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
854
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
855 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
856 8594 aaronmk
857 8928 aaronmk
--
858 10446 aaronmk
-- Dumping data for table `taxon_assertion`
859 8928 aaronmk
--
860 8594 aaronmk
861 10446 aaronmk
/*!40000 ALTER TABLE `taxon_assertion` DISABLE KEYS */;
862
/*!40000 ALTER TABLE `taxon_assertion` ENABLE KEYS */;
863 8928 aaronmk
864
--
865 10446 aaronmk
-- Table structure for table `taxon_concept`
866 8928 aaronmk
--
867
868 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
869
/*!40101 SET character_set_client = utf8 */;
870 10446 aaronmk
CREATE TABLE `taxon_concept` (
871
  `id` varbinary(767) NOT NULL,
872
  `according_to` varbinary(767) NOT NULL,
873
  `parent` varbinary(767) NOT NULL,
874
  `accepted_taxon_concept` varbinary(767) DEFAULT NULL,
875
  PRIMARY KEY (`id`),
876
  UNIQUE KEY `taxon_concept_unique_name` (`according_to`),
877
  KEY `fk_taxon_taxon1_idx` (`parent`),
878
  KEY `fk_taxon_concept_source1_idx` (`according_to`),
879
  KEY `fk_taxon_concept_taxon_concept1_idx` (`accepted_taxon_concept`),
880
  CONSTRAINT `fk_taxon_taxon1` FOREIGN KEY (`parent`) REFERENCES `taxon_concept` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
881
  CONSTRAINT `fk_taxon_concept_source1` FOREIGN KEY (`according_to`) REFERENCES `source` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
882
  CONSTRAINT `fk_taxon_concept_taxon_concept1` FOREIGN KEY (`accepted_taxon_concept`) REFERENCES `taxon_concept` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
883
  CONSTRAINT `fk_taxon_concept_taxon_name1` FOREIGN KEY (`id`) REFERENCES `taxon_name` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
884
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='A [[VegCore#Taxon|Taxon]] described by a specific [[VegCore#Reference|Reference]]';
885 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
886 8928 aaronmk
887
--
888 10446 aaronmk
-- Dumping data for table `taxon_concept`
889 8928 aaronmk
--
890
891 10446 aaronmk
/*!40000 ALTER TABLE `taxon_concept` DISABLE KEYS */;
892
/*!40000 ALTER TABLE `taxon_concept` ENABLE KEYS */;
893 8928 aaronmk
894
--
895 10446 aaronmk
-- Table structure for table `taxon_determination`
896 8928 aaronmk
--
897
898 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
899
/*!40101 SET character_set_client = utf8 */;
900 10446 aaronmk
CREATE TABLE `taxon_determination` (
901
  `id` varbinary(767) NOT NULL,
902
  `taxon_assertion` varbinary(767) NOT NULL,
903
  `identified_by` varbinary(767) DEFAULT NULL,
904
  `fit_info` set('hstore') COLLATE utf8_bin DEFAULT NULL,
905
  PRIMARY KEY (`id`),
906
  UNIQUE KEY `taxon_determination_unique` (`taxon_assertion`,`identified_by`),
907
  KEY `fk_taxon_occurrence_has_qualified_taxon1_idx` (`taxon_assertion`),
908
  KEY `fk_taxon_determination_party1_idx` (`identified_by`),
909
  CONSTRAINT `fk_taxon_occurrence_has_qualified_taxon1` FOREIGN KEY (`taxon_assertion`) REFERENCES `taxon_assertion` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
910
  CONSTRAINT `fk_taxon_determination_record1` FOREIGN KEY (`id`) REFERENCES `taxon_observation` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
911
  CONSTRAINT `fk_taxon_determination_party1` FOREIGN KEY (`identified_by`) REFERENCES `party` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
912
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='An assertion that a [[VegCore#TaxonOccurrence|TaxonOccurrence]] is a particular [[VegCore#Taxon|Taxon]]';
913 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
914 8928 aaronmk
915
--
916 10446 aaronmk
-- Dumping data for table `taxon_determination`
917 8928 aaronmk
--
918
919 10446 aaronmk
/*!40000 ALTER TABLE `taxon_determination` DISABLE KEYS */;
920
/*!40000 ALTER TABLE `taxon_determination` ENABLE KEYS */;
921 8928 aaronmk
922
--
923 10446 aaronmk
-- Table structure for table `taxon_name`
924 8928 aaronmk
--
925
926 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
927
/*!40101 SET character_set_client = utf8 */;
928 10446 aaronmk
CREATE TABLE `taxon_name` (
929
  `id` varbinary(767) NOT NULL,
930
  `unique_name` varbinary(767) NOT NULL,
931
  `formal_name` varbinary(767) DEFAULT NULL,
932
  `taxon_name` varbinary(767) DEFAULT NULL,
933
  `author` varbinary(767) DEFAULT NULL,
934
  `common_name` varbinary(767) DEFAULT NULL,
935
  `rank` varbinary(767) DEFAULT NULL,
936
  PRIMARY KEY (`id`),
937
  KEY `fk_taxon_concept_taxon_string10_idx` (`unique_name`),
938
  CONSTRAINT `fk_taxon_record10` FOREIGN KEY (`id`) REFERENCES `record` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
939
  CONSTRAINT `fk_taxon_concept_taxon_string10` FOREIGN KEY (`unique_name`) REFERENCES `taxon_string` (`string`) ON DELETE CASCADE ON UPDATE CASCADE
940
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
941 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
942 8928 aaronmk
943
--
944 10446 aaronmk
-- Dumping data for table `taxon_name`
945 8928 aaronmk
--
946
947 10446 aaronmk
/*!40000 ALTER TABLE `taxon_name` DISABLE KEYS */;
948
/*!40000 ALTER TABLE `taxon_name` ENABLE KEYS */;
949 8928 aaronmk
950
--
951 10446 aaronmk
-- Table structure for table `taxon_observation`
952 8928 aaronmk
--
953
954 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
955
/*!40101 SET character_set_client = utf8 */;
956 10446 aaronmk
CREATE TABLE `taxon_observation` (
957
  `id` varbinary(767) NOT NULL,
958
  `taxon_occurrence` varbinary(767) NOT NULL,
959
  `collector` varbinary(767) DEFAULT NULL,
960
  `collector_number` varbinary(767) DEFAULT NULL,
961
  `voucher` varbinary(767) DEFAULT NULL,
962
  `growth_form` varbinary(767) DEFAULT NULL,
963
  `cultivated` tinyint(1) DEFAULT NULL,
964
  `traits` set('hstore') COLLATE utf8_bin DEFAULT NULL,
965
  PRIMARY KEY (`id`),
966
  KEY `fk_taxon_observation_taxon_occurrence2_idx` (`taxon_occurrence`),
967
  KEY `fk_taxon_observation_specimen1_idx` (`voucher`),
968
  KEY `fk_taxon_observation_party1_idx` (`collector`),
969
  CONSTRAINT `fk_taxon_observation_event1` FOREIGN KEY (`id`) REFERENCES `event` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
970
  CONSTRAINT `fk_taxon_observation_taxon_occurrence2` FOREIGN KEY (`taxon_occurrence`) REFERENCES `taxon_occurrence` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
971
  CONSTRAINT `fk_taxon_observation_specimen1` FOREIGN KEY (`voucher`) REFERENCES `specimen` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
972
  CONSTRAINT `fk_taxon_observation_party1` FOREIGN KEY (`collector`) REFERENCES `party` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
973
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
974 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
975 8928 aaronmk
976
--
977 10446 aaronmk
-- Dumping data for table `taxon_observation`
978 8928 aaronmk
--
979
980 10446 aaronmk
/*!40000 ALTER TABLE `taxon_observation` DISABLE KEYS */;
981
/*!40000 ALTER TABLE `taxon_observation` ENABLE KEYS */;
982 8928 aaronmk
983
--
984 10446 aaronmk
-- Table structure for table `taxon_occurrence`
985 8928 aaronmk
--
986
987 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
988
/*!40101 SET character_set_client = utf8 */;
989 10446 aaronmk
CREATE TABLE `taxon_occurrence` (
990
  `id` varbinary(767) NOT NULL,
991
  `current_determination` varbinary(767) DEFAULT NULL,
992
  `original_determination` varbinary(767) DEFAULT NULL,
993
  PRIMARY KEY (`id`),
994
  KEY `fk_taxon_occurrence_taxon_determination1_idx` (`original_determination`),
995
  KEY `fk_taxon_occurrence_taxon_determination2_idx` (`current_determination`),
996
  CONSTRAINT `fk_taxon_occurrence_taxon_determination1` FOREIGN KEY (`original_determination`) REFERENCES `taxon_determination` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
997
  CONSTRAINT `fk_taxon_occurrence_taxon_determination2` FOREIGN KEY (`current_determination`) REFERENCES `taxon_determination` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
998
  CONSTRAINT `fk_taxon_occurrence_event1` FOREIGN KEY (`id`) REFERENCES `record` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
999
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='Any entity on which [[VegCore#TaxonDetermination|TaxonDetermination]]s can be made';
1000 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
1001 8928 aaronmk
1002
--
1003 10446 aaronmk
-- Dumping data for table `taxon_occurrence`
1004 8928 aaronmk
--
1005
1006 10446 aaronmk
/*!40000 ALTER TABLE `taxon_occurrence` DISABLE KEYS */;
1007
/*!40000 ALTER TABLE `taxon_occurrence` ENABLE KEYS */;
1008 8928 aaronmk
1009
--
1010 10446 aaronmk
-- Table structure for table `taxon_path`
1011 8928 aaronmk
--
1012
1013 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
1014
/*!40101 SET character_set_client = utf8 */;
1015 10446 aaronmk
CREATE TABLE `taxon_path` (
1016
  `id` varbinary(767) NOT NULL,
1017
  `family` varbinary(767) DEFAULT NULL,
1018
  `genus` varbinary(767) DEFAULT NULL,
1019
  `specific_epithet` varbinary(767) DEFAULT NULL,
1020
  `ranks` set('hstore') COLLATE utf8_bin DEFAULT NULL,
1021
  PRIMARY KEY (`id`),
1022
  CONSTRAINT `fk_taxon_path_taxon_name1` FOREIGN KEY (`id`) REFERENCES `taxon_name` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
1023
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='"a group of one (or more) populations of organism(s), which a taxonomist adjudges to be a unit" ("Wikipedia":http://en.wikipedia.org/wiki/Taxon)';
1024 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
1025 8928 aaronmk
1026
--
1027 10446 aaronmk
-- Dumping data for table `taxon_path`
1028 8928 aaronmk
--
1029
1030 10446 aaronmk
/*!40000 ALTER TABLE `taxon_path` DISABLE KEYS */;
1031
/*!40000 ALTER TABLE `taxon_path` ENABLE KEYS */;
1032 8928 aaronmk
1033
--
1034 10446 aaronmk
-- Table structure for table `taxon_presence`
1035 8928 aaronmk
--
1036
1037 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
1038
/*!40101 SET character_set_client = utf8 */;
1039 10446 aaronmk
CREATE TABLE `taxon_presence` (
1040
  `id` varbinary(767) NOT NULL,
1041
  `taxon_concept` varbinary(767) NOT NULL,
1042
  `traits` set('hstore') COLLATE utf8_bin DEFAULT NULL,
1043
  PRIMARY KEY (`id`),
1044
  KEY `fk_taxon_presence_taxon_name1_idx` (`taxon_concept`),
1045
  CONSTRAINT `fk_taxon_observation_taxon_occurrence1` FOREIGN KEY (`id`) REFERENCES `taxon_observation` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
1046
  CONSTRAINT `fk_taxon_presence_taxon_name1` FOREIGN KEY (`taxon_concept`) REFERENCES `taxon_concept` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
1047
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='An observation of just a [[VegCore#Taxon|Taxon]]''s _presence_';
1048 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
1049 8928 aaronmk
1050
--
1051 10446 aaronmk
-- Dumping data for table `taxon_presence`
1052 8928 aaronmk
--
1053
1054 10446 aaronmk
/*!40000 ALTER TABLE `taxon_presence` DISABLE KEYS */;
1055
/*!40000 ALTER TABLE `taxon_presence` ENABLE KEYS */;
1056 8928 aaronmk
1057
--
1058 10446 aaronmk
-- Table structure for table `taxon_string`
1059 8928 aaronmk
--
1060
1061 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
1062
/*!40101 SET character_set_client = utf8 */;
1063 10446 aaronmk
CREATE TABLE `taxon_string` (
1064
  `string` varbinary(767) NOT NULL,
1065
  PRIMARY KEY (`string`)
1066 10449 aaronmk
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='to get the parsed_taxon_assertion (TNRS result) for a taxon_string, join using taxon_string.string<-taxon_assertion(string)::parsed_taxon_assertion[source=''TNRS.version''] (see wiki.vegpath.org/SQL_dotpaths)';
1067 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
1068 8928 aaronmk
1069
--
1070 10446 aaronmk
-- Dumping data for table `taxon_string`
1071 8928 aaronmk
--
1072
1073 10446 aaronmk
/*!40000 ALTER TABLE `taxon_string` DISABLE KEYS */;
1074
/*!40000 ALTER TABLE `taxon_string` ENABLE KEYS */;
1075 8928 aaronmk
1076
--
1077 10446 aaronmk
-- Table structure for table `validatable_place`
1078 8928 aaronmk
--
1079
1080 9630 aaronmk
/*!40101 SET @saved_cs_client     = @@character_set_client */;
1081
/*!40101 SET character_set_client = utf8 */;
1082 10446 aaronmk
CREATE TABLE `validatable_place` (
1083
  `id` varbinary(767) NOT NULL,
1084
  `coordinates` varbinary(767) NOT NULL,
1085
  `path` varbinary(767) NOT NULL,
1086
  PRIMARY KEY (`id`),
1087
  UNIQUE KEY `validatable_place_unique` (`path`,`coordinates`),
1088
  KEY `fk_geovalidation_place_path1_idx` (`path`),
1089
  KEY `fk_geovalidation_coordinates1_idx` (`coordinates`),
1090
  CONSTRAINT `fk_geovalidation_place_path1` FOREIGN KEY (`path`) REFERENCES `place_path` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
1091
  CONSTRAINT `fk_geovalidation_coordinates1` FOREIGN KEY (`coordinates`) REFERENCES `coordinates` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
1092
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
1093 9630 aaronmk
/*!40101 SET character_set_client = @saved_cs_client */;
1094 8928 aaronmk
1095
--
1096 10446 aaronmk
-- Dumping data for table `validatable_place`
1097 8928 aaronmk
--
1098
1099 10446 aaronmk
/*!40000 ALTER TABLE `validatable_place` DISABLE KEYS */;
1100
/*!40000 ALTER TABLE `validatable_place` ENABLE KEYS */;
1101 8928 aaronmk
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
1102
1103
/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
1104
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
1105
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
1106 10446 aaronmk
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
1107
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
1108
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
1109 8928 aaronmk
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
1110
1111
-- Dump completed