Revision 533
Added by Aaron Marcuse-Kubitza almost 13 years ago
schemas/vegbien.my.sql | ||
---|---|---|
1 |
-- |
|
2 |
-- PostgreSQL database dump |
|
3 |
-- |
|
4 |
|
|
5 |
SET statement_timeout = 0; |
|
6 |
SET client_encoding = 'UTF8'; |
|
7 |
SET standard_conforming_strings = off; |
|
8 |
SET check_function_bodies = false; |
|
9 |
SET client_min_messages = warning; |
|
10 |
SET escape_string_warning = off; |
|
11 |
|
|
12 |
SET search_path = public, pg_catalog; |
|
13 |
|
|
14 |
-- |
|
15 |
-- Name: concat(text); Type: AGGREGATE; Schema: public; Owner: - |
|
16 |
-- |
|
17 |
|
|
18 |
CREATE AGGREGATE concat(text) ( |
|
19 |
SFUNC = textcat, |
|
20 |
STYPE = text, |
|
21 |
INITCOND = '' |
|
22 |
); |
|
23 |
|
|
24 |
|
|
25 |
SET default_tablespace = ''; |
|
26 |
|
|
27 |
SET default_with_oids = true; |
|
28 |
|
|
29 |
-- |
|
30 |
-- Name: address; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
31 |
-- |
|
32 |
|
|
33 |
CREATE TABLE address ( |
|
34 |
address_id int(11) NOT NULL, |
|
35 |
party_id int(11) NOT NULL, |
|
36 |
organization_id int(11), |
|
37 |
orgposition character varying(50), |
|
38 |
email character varying(100), |
|
39 |
deliverypoint character varying(200), |
|
40 |
city character varying(50), |
|
41 |
administrativearea character varying(50), |
|
42 |
postalcode character varying(10), |
|
43 |
country character varying(50), |
|
44 |
currentflag int(1), |
|
45 |
addressstartdate timestamp with time zone |
|
46 |
); |
|
47 |
|
|
48 |
|
|
49 |
-- |
|
50 |
-- Name: address_address_id_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
51 |
-- |
|
52 |
|
|
53 |
CREATE SEQUENCE address_address_id_seq |
|
54 |
START WITH 1 |
|
55 |
INCREMENT BY 1 |
|
56 |
NO MINVALUE |
|
57 |
NO MAXVALUE |
|
58 |
CACHE 1; |
|
59 |
|
|
60 |
|
|
61 |
-- |
|
62 |
-- Name: address_address_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - |
|
63 |
-- |
|
64 |
|
|
65 |
ALTER SEQUENCE address_address_id_seq OWNED BY address.address_id; |
|
66 |
|
|
67 |
|
|
68 |
-- |
|
69 |
-- Name: aggregateoccurrence; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
70 |
-- |
|
71 |
|
|
72 |
CREATE TABLE aggregateoccurrence ( |
|
73 |
aggregateoccurrence_id int(11) NOT NULL, |
|
74 |
taxonoccurrence_id int(11) NOT NULL, |
|
75 |
taxonbin_id int(11), |
|
76 |
cover double precision, |
|
77 |
basalarea double precision, |
|
78 |
biomass double precision, |
|
79 |
inferencearea double precision, |
|
80 |
stratumbase double precision, |
|
81 |
stratumheight double precision, |
|
82 |
emb_aggregateoccurrence int(11), |
|
83 |
covercode character varying(10), |
|
84 |
count int(11) NOT NULL, |
|
85 |
accessioncode character varying(255) |
|
86 |
); |
|
87 |
|
|
88 |
|
|
89 |
-- |
|
90 |
-- Name: TABLE aggregateoccurrence; Type: COMMENT; Schema: public; Owner: - |
|
91 |
-- |
|
92 |
|
|
93 |
COMMENT ON TABLE aggregateoccurrence IS 'VegBank''s taxonimportance table.'; |
|
94 |
|
|
95 |
|
|
96 |
-- |
|
97 |
-- Name: aggregateoccurrence_aggregateoccurrence_id_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
98 |
-- |
|
99 |
|
|
100 |
CREATE SEQUENCE aggregateoccurrence_aggregateoccurrence_id_seq |
|
101 |
START WITH 1 |
|
102 |
INCREMENT BY 1 |
|
103 |
NO MINVALUE |
|
104 |
NO MAXVALUE |
|
105 |
CACHE 1; |
|
106 |
|
|
107 |
|
|
108 |
-- |
|
109 |
-- Name: aggregateoccurrence_aggregateoccurrence_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - |
|
110 |
-- |
|
111 |
|
|
112 |
ALTER SEQUENCE aggregateoccurrence_aggregateoccurrence_id_seq OWNED BY aggregateoccurrence.aggregateoccurrence_id; |
|
113 |
|
|
114 |
|
|
115 |
-- |
|
116 |
-- Name: aux_role; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
117 |
-- |
|
118 |
|
|
119 |
CREATE TABLE aux_role ( |
|
120 |
role_id int(11) NOT NULL, |
|
121 |
rolecode character varying(30) NOT NULL, |
|
122 |
roledescription character varying(200), |
|
123 |
roleproject int(11), |
|
124 |
roleobservation int(11), |
|
125 |
roletaxonint int(11), |
|
126 |
roleclassint int(11), |
|
127 |
accessioncode character varying(255) |
|
128 |
); |
|
129 |
|
|
130 |
|
|
131 |
-- |
|
132 |
-- Name: aux_role_role_id_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
133 |
-- |
|
134 |
|
|
135 |
CREATE SEQUENCE aux_role_role_id_seq |
|
136 |
START WITH 1 |
|
137 |
INCREMENT BY 1 |
|
138 |
NO MINVALUE |
|
139 |
NO MAXVALUE |
|
140 |
CACHE 1; |
|
141 |
|
|
142 |
|
|
143 |
-- |
|
144 |
-- Name: aux_role_role_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - |
|
145 |
-- |
|
146 |
|
|
147 |
ALTER SEQUENCE aux_role_role_id_seq OWNED BY aux_role.role_id; |
|
148 |
|
|
149 |
|
|
150 |
-- |
|
151 |
-- Name: classcontributor; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
152 |
-- |
|
153 |
|
|
154 |
CREATE TABLE classcontributor ( |
|
155 |
classcontributor_id int(11) NOT NULL, |
|
156 |
commclass_id int(11) NOT NULL, |
|
157 |
party_id int(11) NOT NULL, |
|
158 |
role_id int(11), |
|
159 |
emb_classcontributor int(11) |
|
160 |
); |
|
161 |
|
|
162 |
|
|
163 |
-- |
|
164 |
-- Name: classcontributor_classcontributor_id_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
165 |
-- |
|
166 |
|
|
167 |
CREATE SEQUENCE classcontributor_classcontributor_id_seq |
|
168 |
START WITH 1 |
|
169 |
INCREMENT BY 1 |
|
170 |
NO MINVALUE |
|
171 |
NO MAXVALUE |
|
172 |
CACHE 1; |
|
173 |
|
|
174 |
|
|
175 |
-- |
|
176 |
-- Name: classcontributor_classcontributor_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - |
|
177 |
-- |
|
178 |
|
|
179 |
ALTER SEQUENCE classcontributor_classcontributor_id_seq OWNED BY classcontributor.classcontributor_id; |
|
180 |
|
|
181 |
|
|
182 |
-- |
|
183 |
-- Name: commclass; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
184 |
-- |
|
185 |
|
|
186 |
CREATE TABLE commclass ( |
|
187 |
commclass_id int(11) NOT NULL, |
|
188 |
locationevent_id int(11) NOT NULL, |
|
189 |
inspection int(1), |
|
190 |
tableanalysis int(1), |
|
191 |
multivariateanalysis int(1), |
|
192 |
classpublication_id int(11), |
|
193 |
classnotes text, |
|
194 |
commname character varying(200), |
|
195 |
commcode character varying(200), |
|
196 |
commframework character varying(200), |
|
197 |
commlevel character varying(200), |
|
198 |
classstartdate timestamp with time zone, |
|
199 |
classstopdate timestamp with time zone, |
|
200 |
emb_commclass int(11), |
|
201 |
expertsystem text, |
|
202 |
accessioncode character varying(255) |
|
203 |
); |
|
204 |
|
|
205 |
|
|
206 |
-- |
|
207 |
-- Name: commclass_commclass_id_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
208 |
-- |
|
209 |
|
|
210 |
CREATE SEQUENCE commclass_commclass_id_seq |
|
211 |
START WITH 1 |
|
212 |
INCREMENT BY 1 |
|
213 |
NO MINVALUE |
|
214 |
NO MAXVALUE |
|
215 |
CACHE 1; |
|
216 |
|
|
217 |
|
|
218 |
-- |
|
219 |
-- Name: commclass_commclass_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - |
|
220 |
-- |
|
221 |
|
|
222 |
ALTER SEQUENCE commclass_commclass_id_seq OWNED BY commclass.commclass_id; |
|
223 |
|
|
224 |
|
|
225 |
-- |
|
226 |
-- Name: commconcept; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
227 |
-- |
|
228 |
|
|
229 |
CREATE TABLE commconcept ( |
|
230 |
commconcept_id int(11) NOT NULL, |
|
231 |
commname_id int(11) NOT NULL, |
|
232 |
reference_id int(11), |
|
233 |
commdescription text, |
|
234 |
d_obscount int(11), |
|
235 |
commname text, |
|
236 |
d_currentaccepted int(1), |
|
237 |
accessioncode character varying(255) |
|
238 |
); |
|
239 |
|
|
240 |
|
|
241 |
-- |
|
242 |
-- Name: commconcept_commconcept_id_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
243 |
-- |
|
244 |
|
|
245 |
CREATE SEQUENCE commconcept_commconcept_id_seq |
|
246 |
START WITH 1 |
|
247 |
INCREMENT BY 1 |
|
248 |
NO MINVALUE |
|
249 |
NO MAXVALUE |
|
250 |
CACHE 1; |
|
251 |
|
|
252 |
|
|
253 |
-- |
|
254 |
-- Name: commconcept_commconcept_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - |
|
255 |
-- |
|
256 |
|
|
257 |
ALTER SEQUENCE commconcept_commconcept_id_seq OWNED BY commconcept.commconcept_id; |
|
258 |
|
|
259 |
|
|
260 |
-- |
|
261 |
-- Name: commcorrelation; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
262 |
-- |
|
263 |
|
|
264 |
CREATE TABLE commcorrelation ( |
|
265 |
commcorrelation_id int(11) NOT NULL, |
|
266 |
commstatus_id int(11) NOT NULL, |
|
267 |
commconcept_id int(11) NOT NULL, |
|
268 |
commconvergence character varying(20) NOT NULL, |
|
269 |
correlationstart timestamp with time zone NOT NULL, |
|
270 |
correlationstop timestamp with time zone |
|
271 |
); |
|
272 |
|
|
273 |
|
|
274 |
-- |
|
275 |
-- Name: commcorrelation_commcorrelation_id_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
276 |
-- |
|
277 |
|
|
278 |
CREATE SEQUENCE commcorrelation_commcorrelation_id_seq |
|
279 |
START WITH 1 |
|
280 |
INCREMENT BY 1 |
|
281 |
NO MINVALUE |
|
282 |
NO MAXVALUE |
|
283 |
CACHE 1; |
|
284 |
|
|
285 |
|
|
286 |
-- |
|
287 |
-- Name: commcorrelation_commcorrelation_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - |
|
288 |
-- |
|
289 |
|
|
290 |
ALTER SEQUENCE commcorrelation_commcorrelation_id_seq OWNED BY commcorrelation.commcorrelation_id; |
|
291 |
|
|
292 |
|
|
293 |
-- |
|
294 |
-- Name: commdetermination; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
295 |
-- |
|
296 |
|
|
297 |
CREATE TABLE commdetermination ( |
|
298 |
commdetermination_id int(11) NOT NULL, |
|
299 |
commclass_id int(11) NOT NULL, |
|
300 |
commconcept_id int(11), |
|
301 |
commcode character varying(34), |
|
302 |
commname character varying(200), |
|
303 |
classfit character varying(50), |
|
304 |
classconfidence character varying(15), |
|
305 |
commauthority_id int(11), |
|
306 |
notes text, |
|
307 |
type int(1), |
|
308 |
nomenclaturaltype int(1), |
|
309 |
emb_commdetermination int(11) |
|
310 |
); |
|
311 |
|
|
312 |
|
|
313 |
-- |
|
314 |
-- Name: commdetermination_commdetermination_id_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
315 |
-- |
|
316 |
|
|
317 |
CREATE SEQUENCE commdetermination_commdetermination_id_seq |
|
318 |
START WITH 1 |
|
319 |
INCREMENT BY 1 |
|
320 |
NO MINVALUE |
|
321 |
NO MAXVALUE |
|
322 |
CACHE 1; |
|
323 |
|
|
324 |
|
|
325 |
-- |
|
326 |
-- Name: commdetermination_commdetermination_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - |
|
327 |
-- |
|
328 |
|
|
329 |
ALTER SEQUENCE commdetermination_commdetermination_id_seq OWNED BY commdetermination.commdetermination_id; |
|
330 |
|
|
331 |
|
|
332 |
-- |
|
333 |
-- Name: commlineage; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
334 |
-- |
|
335 |
|
|
336 |
CREATE TABLE commlineage ( |
|
337 |
commlineage_id int(11) NOT NULL, |
|
338 |
parentcommstatus_id int(11) NOT NULL, |
|
339 |
childcommstatus_id int(11) NOT NULL |
|
340 |
); |
|
341 |
|
|
342 |
|
|
343 |
-- |
|
344 |
-- Name: commlineage_commlineage_id_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
345 |
-- |
|
346 |
|
|
347 |
CREATE SEQUENCE commlineage_commlineage_id_seq |
|
348 |
START WITH 1 |
|
349 |
INCREMENT BY 1 |
|
350 |
NO MINVALUE |
|
351 |
NO MAXVALUE |
|
352 |
CACHE 1; |
|
353 |
|
|
354 |
|
|
355 |
-- |
|
356 |
-- Name: commlineage_commlineage_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - |
|
357 |
-- |
|
358 |
|
|
359 |
ALTER SEQUENCE commlineage_commlineage_id_seq OWNED BY commlineage.commlineage_id; |
|
360 |
|
|
361 |
|
|
362 |
-- |
|
363 |
-- Name: commname; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
364 |
-- |
|
365 |
|
|
366 |
CREATE TABLE commname ( |
|
367 |
commname_id int(11) NOT NULL, |
|
368 |
commname text NOT NULL, |
|
369 |
reference_id int(11), |
|
370 |
dateentered timestamp with time zone DEFAULT now() |
|
371 |
); |
|
372 |
|
|
373 |
|
|
374 |
-- |
|
375 |
-- Name: commname_commname_id_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
376 |
-- |
|
377 |
|
|
378 |
CREATE SEQUENCE commname_commname_id_seq |
|
379 |
START WITH 1 |
|
380 |
INCREMENT BY 1 |
|
381 |
NO MINVALUE |
|
382 |
NO MAXVALUE |
|
383 |
CACHE 1; |
|
384 |
|
|
385 |
|
|
386 |
-- |
|
387 |
-- Name: commname_commname_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - |
|
388 |
-- |
|
389 |
|
|
390 |
ALTER SEQUENCE commname_commname_id_seq OWNED BY commname.commname_id; |
|
391 |
|
|
392 |
|
|
393 |
-- |
|
394 |
-- Name: commstatus; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
395 |
-- |
|
396 |
|
|
397 |
CREATE TABLE commstatus ( |
|
398 |
commstatus_id int(11) NOT NULL, |
|
399 |
commconcept_id int(11) NOT NULL, |
|
400 |
reference_id int(11), |
|
401 |
commconceptstatus character varying(20) NOT NULL, |
|
402 |
commparent_id int(11), |
|
403 |
commlevel character varying(80), |
|
404 |
commpartycomments text, |
|
405 |
party_id int(11) NOT NULL, |
|
406 |
startdate timestamp with time zone NOT NULL, |
|
407 |
stopdate timestamp with time zone, |
|
408 |
accessioncode character varying(255) |
|
409 |
); |
|
410 |
|
|
411 |
|
|
412 |
-- |
|
413 |
-- Name: commstatus_commstatus_id_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
414 |
-- |
|
415 |
|
|
416 |
CREATE SEQUENCE commstatus_commstatus_id_seq |
|
417 |
START WITH 1 |
|
418 |
INCREMENT BY 1 |
|
419 |
NO MINVALUE |
|
420 |
NO MAXVALUE |
|
421 |
CACHE 1; |
|
422 |
|
|
423 |
|
|
424 |
-- |
|
425 |
-- Name: commstatus_commstatus_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - |
|
426 |
-- |
|
427 |
|
|
428 |
ALTER SEQUENCE commstatus_commstatus_id_seq OWNED BY commstatus.commstatus_id; |
|
429 |
|
|
430 |
|
|
431 |
-- |
|
432 |
-- Name: commusage; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
433 |
-- |
|
434 |
|
|
435 |
CREATE TABLE commusage ( |
|
436 |
commusage_id int(11) NOT NULL, |
|
437 |
commname_id int(11) NOT NULL, |
|
438 |
commname text, |
|
439 |
commconcept_id int(11), |
|
440 |
commnamestatus character varying(20), |
|
441 |
classsystem character varying(50), |
|
442 |
party_id int(11), |
|
443 |
commstatus_id int(11), |
|
444 |
usagestart timestamp with time zone, |
|
445 |
usagestop timestamp with time zone |
|
446 |
); |
|
447 |
|
|
448 |
|
|
449 |
-- |
|
450 |
-- Name: commusage_commusage_id_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
451 |
-- |
|
452 |
|
|
453 |
CREATE SEQUENCE commusage_commusage_id_seq |
|
454 |
START WITH 1 |
|
455 |
INCREMENT BY 1 |
|
456 |
NO MINVALUE |
|
457 |
NO MAXVALUE |
|
458 |
CACHE 1; |
|
459 |
|
|
460 |
|
|
461 |
-- |
|
462 |
-- Name: commusage_commusage_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - |
|
463 |
-- |
|
464 |
|
|
465 |
ALTER SEQUENCE commusage_commusage_id_seq OWNED BY commusage.commusage_id; |
|
466 |
|
|
467 |
|
|
468 |
-- |
|
469 |
-- Name: coverindex; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
470 |
-- |
|
471 |
|
|
472 |
CREATE TABLE coverindex ( |
|
473 |
coverindex_id int(11) NOT NULL, |
|
474 |
covermethod_id int(11) NOT NULL, |
|
475 |
covercode character varying(10) NOT NULL, |
|
476 |
upperlimit double precision, |
|
477 |
lowerlimit double precision, |
|
478 |
coverpercent double precision NOT NULL, |
|
479 |
indexdescription text |
|
480 |
); |
|
481 |
|
|
482 |
|
|
483 |
-- |
|
484 |
-- Name: coverindex_coverindex_id_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
485 |
-- |
|
486 |
|
|
487 |
CREATE SEQUENCE coverindex_coverindex_id_seq |
|
488 |
START WITH 1 |
|
489 |
INCREMENT BY 1 |
|
490 |
NO MINVALUE |
|
491 |
NO MAXVALUE |
|
492 |
CACHE 1; |
|
493 |
|
|
494 |
|
|
495 |
-- |
|
496 |
-- Name: coverindex_coverindex_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - |
|
497 |
-- |
|
498 |
|
|
499 |
ALTER SEQUENCE coverindex_coverindex_id_seq OWNED BY coverindex.coverindex_id; |
|
500 |
|
|
501 |
|
|
502 |
-- |
|
503 |
-- Name: covermethod; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
504 |
-- |
|
505 |
|
|
506 |
CREATE TABLE covermethod ( |
|
507 |
covermethod_id int(11) NOT NULL, |
|
508 |
reference_id int(11), |
|
509 |
covertype character varying(30) NOT NULL, |
|
510 |
coverestimationmethod character varying(80), |
|
511 |
accessioncode character varying(255) |
|
512 |
); |
|
513 |
|
|
514 |
|
|
515 |
-- |
|
516 |
-- Name: covermethod_covermethod_id_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
517 |
-- |
|
518 |
|
|
519 |
CREATE SEQUENCE covermethod_covermethod_id_seq |
|
520 |
START WITH 1 |
|
521 |
INCREMENT BY 1 |
|
522 |
NO MINVALUE |
|
523 |
NO MAXVALUE |
|
524 |
CACHE 1; |
|
525 |
|
|
526 |
|
|
527 |
-- |
|
528 |
-- Name: covermethod_covermethod_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - |
|
529 |
-- |
|
530 |
|
|
531 |
ALTER SEQUENCE covermethod_covermethod_id_seq OWNED BY covermethod.covermethod_id; |
|
532 |
|
|
533 |
|
|
534 |
-- |
|
535 |
-- Name: dba_confidentialitystatus; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
536 |
-- |
|
537 |
|
|
538 |
CREATE TABLE dba_confidentialitystatus ( |
|
539 |
confidentialitystatus int(11) NOT NULL, |
|
540 |
confidentialitytext character varying(100), |
|
541 |
confidentialityshorttext character varying(100) |
|
542 |
); |
|
543 |
|
|
544 |
|
|
545 |
-- |
|
546 |
-- Name: dba_cookie; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
547 |
-- |
|
548 |
|
|
549 |
CREATE TABLE dba_cookie ( |
|
550 |
cookie_id int(11) NOT NULL, |
|
551 |
cookiename character varying(75) NOT NULL, |
|
552 |
defaultvalue character varying(75) NOT NULL, |
|
553 |
viewname character varying(25) NOT NULL, |
|
554 |
description text, |
|
555 |
examplepk int(11) NOT NULL, |
|
556 |
sortorder int(11), |
|
557 |
startgroup int(1), |
|
558 |
prefixhtml text, |
|
559 |
suffixhtml text |
|
560 |
); |
|
561 |
|
|
562 |
|
|
563 |
-- |
|
564 |
-- Name: dba_cookie_cookie_id_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
565 |
-- |
|
566 |
|
|
567 |
CREATE SEQUENCE dba_cookie_cookie_id_seq |
|
568 |
START WITH 1 |
|
569 |
INCREMENT BY 1 |
|
570 |
NO MINVALUE |
|
571 |
NO MAXVALUE |
|
572 |
CACHE 1; |
|
573 |
|
|
574 |
|
|
575 |
-- |
|
576 |
-- Name: dba_cookie_cookie_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - |
|
577 |
-- |
|
578 |
|
|
579 |
ALTER SEQUENCE dba_cookie_cookie_id_seq OWNED BY dba_cookie.cookie_id; |
|
580 |
|
|
581 |
|
|
582 |
-- |
|
583 |
-- Name: dba_cookielabels; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
584 |
-- |
|
585 |
|
|
586 |
CREATE TABLE dba_cookielabels ( |
|
587 |
cookielabel_id int(11) NOT NULL, |
|
588 |
vieworcookie character varying(50) NOT NULL, |
|
589 |
description text |
|
590 |
); |
|
591 |
|
|
592 |
|
|
593 |
-- |
|
594 |
-- Name: dba_cookielabels_cookielabel_id_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
595 |
-- |
|
596 |
|
|
597 |
CREATE SEQUENCE dba_cookielabels_cookielabel_id_seq |
|
598 |
START WITH 1 |
|
599 |
INCREMENT BY 1 |
|
600 |
NO MINVALUE |
|
601 |
NO MAXVALUE |
|
602 |
CACHE 1; |
|
603 |
|
|
604 |
|
|
605 |
-- |
|
606 |
-- Name: dba_cookielabels_cookielabel_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - |
|
607 |
-- |
|
608 |
|
|
609 |
ALTER SEQUENCE dba_cookielabels_cookielabel_id_seq OWNED BY dba_cookielabels.cookielabel_id; |
|
610 |
|
|
611 |
|
|
612 |
SET default_with_oids = false; |
|
613 |
|
|
614 |
-- |
|
615 |
-- Name: dba_datacache; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
616 |
-- |
|
617 |
|
|
618 |
CREATE TABLE dba_datacache ( |
|
619 |
dba_datacache_id int(11) NOT NULL, |
|
620 |
cache_key character varying(200) NOT NULL, |
|
621 |
cache_label character varying(200), |
|
622 |
cache_order double precision, |
|
623 |
data1 character varying(255), |
|
624 |
data2 character varying(255), |
|
625 |
data3 character varying(255), |
|
626 |
data4 character varying(255), |
|
627 |
data5 character varying(255), |
|
628 |
data6 character varying(255), |
|
629 |
data7 character varying(255), |
|
630 |
data8 character varying(255), |
|
631 |
data9 character varying(255), |
|
632 |
data10 character varying(255) |
|
633 |
); |
|
634 |
|
|
635 |
|
|
636 |
-- |
|
637 |
-- Name: dba_datacache_dba_datacache_id_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
638 |
-- |
|
639 |
|
|
640 |
CREATE SEQUENCE dba_datacache_dba_datacache_id_seq |
|
641 |
START WITH 1 |
|
642 |
INCREMENT BY 1 |
|
643 |
NO MINVALUE |
|
644 |
NO MAXVALUE |
|
645 |
CACHE 1; |
|
646 |
|
|
647 |
|
|
648 |
-- |
|
649 |
-- Name: dba_datacache_dba_datacache_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - |
|
650 |
-- |
|
651 |
|
|
652 |
ALTER SEQUENCE dba_datacache_dba_datacache_id_seq OWNED BY dba_datacache.dba_datacache_id; |
|
653 |
|
|
654 |
|
|
655 |
-- |
|
656 |
-- Name: dba_datamodelversion; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
657 |
-- |
|
658 |
|
|
659 |
CREATE TABLE dba_datamodelversion ( |
|
660 |
dba_datamodelversion_id int(11) NOT NULL, |
|
661 |
versiontext character varying(20) NOT NULL, |
|
662 |
versionimplemented timestamp with time zone DEFAULT now() |
|
663 |
); |
|
664 |
|
|
665 |
|
|
666 |
-- |
|
667 |
-- Name: dba_datamodelversion_dba_datamodelversion_id_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
668 |
-- |
|
669 |
|
|
670 |
CREATE SEQUENCE dba_datamodelversion_dba_datamodelversion_id_seq |
|
671 |
START WITH 1 |
|
672 |
INCREMENT BY 1 |
|
673 |
NO MINVALUE |
|
674 |
NO MAXVALUE |
|
675 |
CACHE 1; |
|
676 |
|
|
677 |
|
|
678 |
-- |
|
679 |
-- Name: dba_datamodelversion_dba_datamodelversion_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - |
|
680 |
-- |
|
681 |
|
|
682 |
ALTER SEQUENCE dba_datamodelversion_dba_datamodelversion_id_seq OWNED BY dba_datamodelversion.dba_datamodelversion_id; |
|
683 |
|
|
684 |
|
|
685 |
SET default_with_oids = true; |
|
686 |
|
|
687 |
-- |
|
688 |
-- Name: dba_dbstatstime; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
689 |
-- |
|
690 |
|
|
691 |
CREATE TABLE dba_dbstatstime ( |
|
692 |
stat_id int(11) NOT NULL, |
|
693 |
statdate timestamp with time zone, |
|
694 |
statpkg int(11), |
|
695 |
statname text, |
|
696 |
stattable character varying(100), |
|
697 |
minpk int(11), |
|
698 |
maxpk int(11), |
|
699 |
countrecs int(11) |
|
700 |
); |
|
701 |
|
|
702 |
|
|
703 |
-- |
|
704 |
-- Name: dba_dbstatstime_stat_id_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
705 |
-- |
|
706 |
|
|
707 |
CREATE SEQUENCE dba_dbstatstime_stat_id_seq |
|
708 |
START WITH 1 |
|
709 |
INCREMENT BY 1 |
|
710 |
NO MINVALUE |
|
711 |
NO MAXVALUE |
|
712 |
CACHE 1; |
|
713 |
|
|
714 |
|
|
715 |
-- |
|
716 |
-- Name: dba_dbstatstime_stat_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - |
|
717 |
-- |
|
718 |
|
|
719 |
ALTER SEQUENCE dba_dbstatstime_stat_id_seq OWNED BY dba_dbstatstime.stat_id; |
|
720 |
|
|
721 |
|
|
722 |
SET default_with_oids = false; |
|
723 |
|
|
724 |
-- |
|
725 |
-- Name: dba_fielddescription; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
726 |
-- |
|
727 |
|
|
728 |
CREATE TABLE dba_fielddescription ( |
|
729 |
dba_fielddescription_id int(11) NOT NULL, |
|
730 |
tablename character varying(75), |
|
731 |
fieldname character varying(75), |
|
732 |
fieldlabel character varying(200), |
|
733 |
fieldmodel character varying(50), |
|
734 |
fieldnulls character varying(10), |
|
735 |
fieldtype character varying(30), |
|
736 |
fieldkey character varying(10), |
|
737 |
fieldreferences character varying(200), |
|
738 |
fieldlist character varying(50), |
|
739 |
fieldnotes text, |
|
740 |
fielddefinition text, |
|
741 |
fieldkeywords text |
|
742 |
); |
|
743 |
|
|
744 |
|
|
745 |
-- |
|
746 |
-- Name: dba_fielddescription_dba_fielddescription_id_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
747 |
-- |
|
748 |
|
|
749 |
CREATE SEQUENCE dba_fielddescription_dba_fielddescription_id_seq |
|
750 |
START WITH 1 |
|
751 |
INCREMENT BY 1 |
|
752 |
NO MINVALUE |
|
753 |
NO MAXVALUE |
|
754 |
CACHE 1; |
|
755 |
|
|
756 |
|
|
757 |
-- |
|
758 |
-- Name: dba_fielddescription_dba_fielddescription_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - |
|
759 |
-- |
|
760 |
|
|
761 |
ALTER SEQUENCE dba_fielddescription_dba_fielddescription_id_seq OWNED BY dba_fielddescription.dba_fielddescription_id; |
|
762 |
|
|
763 |
|
|
764 |
-- |
|
765 |
-- Name: dba_fieldlist; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
766 |
-- |
|
767 |
|
|
768 |
CREATE TABLE dba_fieldlist ( |
|
769 |
dba_fieldlist_id int(11) NOT NULL, |
|
770 |
tablename character varying(75), |
|
771 |
fieldname character varying(75), |
|
772 |
listvalue character varying(255), |
|
773 |
listvaluedescription text, |
|
774 |
listvaluesortorder double precision |
|
775 |
); |
|
776 |
|
|
777 |
|
|
778 |
-- |
|
779 |
-- Name: dba_fieldlist_dba_fieldlist_id_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
780 |
-- |
|
781 |
|
|
782 |
CREATE SEQUENCE dba_fieldlist_dba_fieldlist_id_seq |
|
783 |
START WITH 1 |
|
784 |
INCREMENT BY 1 |
|
785 |
NO MINVALUE |
|
786 |
NO MAXVALUE |
|
787 |
CACHE 1; |
|
788 |
|
|
789 |
|
|
790 |
-- |
|
791 |
-- Name: dba_fieldlist_dba_fieldlist_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - |
|
792 |
-- |
|
793 |
|
|
794 |
ALTER SEQUENCE dba_fieldlist_dba_fieldlist_id_seq OWNED BY dba_fieldlist.dba_fieldlist_id; |
|
795 |
|
|
796 |
|
|
797 |
-- |
|
798 |
-- Name: dba_onerow; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
799 |
-- |
|
800 |
|
|
801 |
CREATE TABLE dba_onerow ( |
|
802 |
dba_onerow_id int(11) NOT NULL |
|
803 |
); |
|
804 |
|
|
805 |
|
|
806 |
-- |
|
807 |
-- Name: dba_onerow_dba_onerow_id_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
808 |
-- |
|
809 |
|
|
810 |
CREATE SEQUENCE dba_onerow_dba_onerow_id_seq |
|
811 |
START WITH 1 |
|
812 |
INCREMENT BY 1 |
|
813 |
NO MINVALUE |
|
814 |
NO MAXVALUE |
|
815 |
CACHE 1; |
|
816 |
|
|
817 |
|
|
818 |
-- |
|
819 |
-- Name: dba_onerow_dba_onerow_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - |
|
820 |
-- |
|
821 |
|
|
822 |
ALTER SEQUENCE dba_onerow_dba_onerow_id_seq OWNED BY dba_onerow.dba_onerow_id; |
|
823 |
|
|
824 |
|
|
825 |
-- |
|
826 |
-- Name: dba_preassignacccode; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
827 |
-- |
|
828 |
|
|
829 |
CREATE TABLE dba_preassignacccode ( |
|
830 |
dba_preassignacccode_id int(11) NOT NULL, |
|
831 |
dba_requestnumber int(11) NOT NULL, |
|
832 |
databasekey character varying(20) NOT NULL, |
|
833 |
tableabbrev character varying(10) NOT NULL, |
|
834 |
confirmcode character varying(70) DEFAULT ((replace(replace(replace(replace((now())::text, ' '::text, 'T'::text), '-'::text, ''::text), ':'::text, ''::text), '.'::text, 'd'::text) || 'R'::text) || (floor((random() * (1000000)::double precision)))::text) NOT NULL, |
|
835 |
codeisused int(1), |
|
836 |
accessioncode character varying(255) |
|
837 |
); |
|
838 |
|
|
839 |
|
|
840 |
-- |
|
841 |
-- Name: dba_preassignacccode_dba_preassignacccode_id_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
842 |
-- |
|
843 |
|
|
844 |
CREATE SEQUENCE dba_preassignacccode_dba_preassignacccode_id_seq |
|
845 |
START WITH 1 |
|
846 |
INCREMENT BY 1 |
|
847 |
NO MINVALUE |
|
848 |
NO MAXVALUE |
|
849 |
CACHE 1; |
|
850 |
|
|
851 |
|
|
852 |
-- |
|
853 |
-- Name: dba_preassignacccode_dba_preassignacccode_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - |
|
854 |
-- |
|
855 |
|
|
856 |
ALTER SEQUENCE dba_preassignacccode_dba_preassignacccode_id_seq OWNED BY dba_preassignacccode.dba_preassignacccode_id; |
|
857 |
|
|
858 |
|
|
859 |
-- |
|
860 |
-- Name: dba_preassignacccode_dba_requestnumber_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
861 |
-- |
|
862 |
|
|
863 |
CREATE SEQUENCE dba_preassignacccode_dba_requestnumber_seq |
|
864 |
START WITH 1 |
|
865 |
INCREMENT BY 1 |
|
866 |
NO MINVALUE |
|
867 |
NO MAXVALUE |
|
868 |
CACHE 1; |
|
869 |
|
|
870 |
|
|
871 |
-- |
|
872 |
-- Name: dba_tabledescription; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
873 |
-- |
|
874 |
|
|
875 |
CREATE TABLE dba_tabledescription ( |
|
876 |
dba_tabledescription_id int(11) NOT NULL, |
|
877 |
tablename character varying(75), |
|
878 |
tablelabel character varying(200), |
|
879 |
tablenotes text, |
|
880 |
tabledescription text, |
|
881 |
tablekeywords text |
|
882 |
); |
|
883 |
|
|
884 |
|
|
885 |
-- |
|
886 |
-- Name: dba_tabledescription_dba_tabledescription_id_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
887 |
-- |
|
888 |
|
|
889 |
CREATE SEQUENCE dba_tabledescription_dba_tabledescription_id_seq |
|
890 |
START WITH 1 |
|
891 |
INCREMENT BY 1 |
|
892 |
NO MINVALUE |
|
893 |
NO MAXVALUE |
|
894 |
CACHE 1; |
|
895 |
|
|
896 |
|
|
897 |
-- |
|
898 |
-- Name: dba_tabledescription_dba_tabledescription_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - |
|
899 |
-- |
|
900 |
|
|
901 |
ALTER SEQUENCE dba_tabledescription_dba_tabledescription_id_seq OWNED BY dba_tabledescription.dba_tabledescription_id; |
|
902 |
|
|
903 |
|
|
904 |
-- |
|
905 |
-- Name: dba_xmlcache; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
906 |
-- |
|
907 |
|
|
908 |
CREATE TABLE dba_xmlcache ( |
|
909 |
xml bytea, |
|
910 |
accessioncode character varying(255) |
|
911 |
); |
|
912 |
|
|
913 |
|
|
914 |
SET default_with_oids = true; |
|
915 |
|
|
916 |
-- |
|
917 |
-- Name: definedvalue; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
918 |
-- |
|
919 |
|
|
920 |
CREATE TABLE definedvalue ( |
|
921 |
definedvalue_id int(11) NOT NULL, |
|
922 |
userdefined_id int(11) NOT NULL, |
|
923 |
tablerecord_id int(11) NOT NULL, |
|
924 |
definedvalue text NOT NULL |
|
925 |
); |
|
926 |
|
|
927 |
|
|
928 |
-- |
|
929 |
-- Name: definedvalue_definedvalue_id_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
930 |
-- |
|
931 |
|
|
932 |
CREATE SEQUENCE definedvalue_definedvalue_id_seq |
|
933 |
START WITH 1 |
|
934 |
INCREMENT BY 1 |
|
935 |
NO MINVALUE |
|
936 |
NO MAXVALUE |
|
937 |
CACHE 1; |
|
938 |
|
|
939 |
|
|
940 |
-- |
|
941 |
-- Name: definedvalue_definedvalue_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - |
|
942 |
-- |
|
943 |
|
|
944 |
ALTER SEQUENCE definedvalue_definedvalue_id_seq OWNED BY definedvalue.definedvalue_id; |
|
945 |
|
|
946 |
|
|
947 |
-- |
|
948 |
-- Name: disturbanceobs; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
949 |
-- |
|
950 |
|
|
951 |
CREATE TABLE disturbanceobs ( |
|
952 |
disturbanceobs_id int(11) NOT NULL, |
|
953 |
locationevent_id int(11) NOT NULL, |
|
954 |
disturbancetype character varying(30) NOT NULL, |
|
955 |
disturbanceintensity character varying(30), |
|
956 |
disturbanceage double precision, |
|
957 |
disturbanceextent double precision, |
|
958 |
disturbancecomment text, |
|
959 |
emb_disturbanceobs int(11) |
|
960 |
); |
|
961 |
|
|
962 |
|
|
963 |
-- |
|
964 |
-- Name: disturbanceobs_disturbanceobs_id_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
965 |
-- |
|
966 |
|
|
967 |
CREATE SEQUENCE disturbanceobs_disturbanceobs_id_seq |
|
968 |
START WITH 1 |
|
969 |
INCREMENT BY 1 |
|
970 |
NO MINVALUE |
|
971 |
NO MAXVALUE |
|
972 |
CACHE 1; |
|
973 |
|
|
974 |
|
|
975 |
-- |
|
976 |
-- Name: disturbanceobs_disturbanceobs_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - |
|
977 |
-- |
|
978 |
|
|
979 |
ALTER SEQUENCE disturbanceobs_disturbanceobs_id_seq OWNED BY disturbanceobs.disturbanceobs_id; |
|
980 |
|
|
981 |
|
|
982 |
-- |
|
983 |
-- Name: embargo; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
984 |
-- |
|
985 |
|
|
986 |
CREATE TABLE embargo ( |
|
987 |
embargo_id int(11) NOT NULL, |
|
988 |
location_id int(11) NOT NULL, |
|
989 |
embargoreason text NOT NULL, |
|
990 |
defaultstatus int(11) NOT NULL, |
|
991 |
embargostart timestamp with time zone NOT NULL, |
|
992 |
embargostop timestamp with time zone NOT NULL |
|
993 |
); |
|
994 |
|
|
995 |
|
|
996 |
-- |
|
997 |
-- Name: embargo_embargo_id_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
998 |
-- |
|
999 |
|
|
1000 |
CREATE SEQUENCE embargo_embargo_id_seq |
|
1001 |
START WITH 1 |
|
1002 |
INCREMENT BY 1 |
|
1003 |
NO MINVALUE |
|
1004 |
NO MAXVALUE |
|
1005 |
CACHE 1; |
|
1006 |
|
|
1007 |
|
|
1008 |
-- |
|
1009 |
-- Name: embargo_embargo_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - |
|
1010 |
-- |
|
1011 |
|
|
1012 |
ALTER SEQUENCE embargo_embargo_id_seq OWNED BY embargo.embargo_id; |
|
1013 |
|
|
1014 |
|
|
1015 |
-- |
|
1016 |
-- Name: graphic; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
1017 |
-- |
|
1018 |
|
|
1019 |
CREATE TABLE graphic ( |
|
1020 |
graphic_id int(11) NOT NULL, |
|
1021 |
locationevent_id int(11) NOT NULL, |
|
1022 |
graphicname character varying(30), |
|
1023 |
graphiclocation text, |
|
1024 |
graphicdescription text, |
|
1025 |
graphictype character varying(20), |
|
1026 |
graphicdata oid, |
|
1027 |
graphicdate timestamp with time zone, |
|
1028 |
accessioncode character varying(255) |
|
1029 |
); |
|
1030 |
|
|
1031 |
|
|
1032 |
-- |
|
1033 |
-- Name: graphic_graphic_id_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
1034 |
-- |
|
1035 |
|
|
1036 |
CREATE SEQUENCE graphic_graphic_id_seq |
|
1037 |
START WITH 1 |
|
1038 |
INCREMENT BY 1 |
|
1039 |
NO MINVALUE |
|
1040 |
NO MAXVALUE |
|
1041 |
CACHE 1; |
|
1042 |
|
|
1043 |
|
|
1044 |
-- |
|
1045 |
-- Name: graphic_graphic_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - |
|
1046 |
-- |
|
1047 |
|
|
1048 |
ALTER SEQUENCE graphic_graphic_id_seq OWNED BY graphic.graphic_id; |
|
1049 |
|
|
1050 |
|
|
1051 |
-- |
|
1052 |
-- Name: individualplant; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
1053 |
-- |
|
1054 |
|
|
1055 |
CREATE TABLE individualplant ( |
|
1056 |
individualplant_id int(11) NOT NULL, |
|
1057 |
aggregateoccurrence_id int(11) NOT NULL, |
|
1058 |
height double precision, |
|
1059 |
heightaccuracy double precision, |
|
1060 |
emb_individualplant int(11), |
|
1061 |
sourceid character varying(20), |
|
1062 |
accessioncode character varying(255), |
|
1063 |
stemcount int(11) |
|
1064 |
); |
|
1065 |
|
|
1066 |
|
|
1067 |
-- |
|
1068 |
-- Name: TABLE individualplant; Type: COMMENT; Schema: public; Owner: - |
|
1069 |
-- |
|
1070 |
|
|
1071 |
COMMENT ON TABLE individualplant IS 'VegBank''s stemcount table.'; |
|
1072 |
|
|
1073 |
|
|
1074 |
-- |
|
1075 |
-- Name: individualplant_individualplant_id_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
1076 |
-- |
|
1077 |
|
|
1078 |
CREATE SEQUENCE individualplant_individualplant_id_seq |
|
1079 |
START WITH 1 |
|
1080 |
INCREMENT BY 1 |
|
1081 |
NO MINVALUE |
|
1082 |
NO MAXVALUE |
|
1083 |
CACHE 1; |
|
1084 |
|
|
1085 |
|
|
1086 |
-- |
|
1087 |
-- Name: individualplant_individualplant_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - |
|
1088 |
-- |
|
1089 |
|
|
1090 |
ALTER SEQUENCE individualplant_individualplant_id_seq OWNED BY individualplant.individualplant_id; |
|
1091 |
|
|
1092 |
|
|
1093 |
-- |
|
1094 |
-- Name: keywords; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
1095 |
-- |
|
1096 |
|
|
1097 |
CREATE TABLE keywords ( |
|
1098 |
table_id int(11) NOT NULL, |
|
1099 |
entity text NOT NULL, |
|
1100 |
keywords text |
|
1101 |
); |
|
1102 |
|
|
1103 |
|
|
1104 |
-- |
|
1105 |
-- Name: keywords_extra; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
1106 |
-- |
|
1107 |
|
|
1108 |
CREATE TABLE keywords_extra ( |
|
1109 |
table_id int(11) NOT NULL, |
|
1110 |
entity text NOT NULL, |
|
1111 |
keywords text |
|
1112 |
); |
|
1113 |
|
|
1114 |
|
|
1115 |
-- |
|
1116 |
-- Name: location; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
1117 |
-- |
|
1118 |
|
|
1119 |
CREATE TABLE location ( |
|
1120 |
location_id int(11) NOT NULL, |
|
1121 |
sourceid character varying(30), |
|
1122 |
reference_id int(11), |
|
1123 |
parent_id int(11), |
|
1124 |
reallatitude double precision, |
|
1125 |
reallongitude double precision, |
|
1126 |
locationaccuracy double precision, |
|
1127 |
confidentialitystatus int(11) NOT NULL, |
|
1128 |
confidentialityreason character varying(200), |
|
1129 |
latitude double precision, |
|
1130 |
longitude double precision, |
|
1131 |
authore character varying(20), |
|
1132 |
authorn character varying(20), |
|
1133 |
authorzone character varying(20), |
|
1134 |
authordatum character varying(20), |
|
1135 |
authorlocation character varying(200), |
|
1136 |
locationnarrative text, |
|
1137 |
azimuth double precision, |
|
1138 |
dsgpoly text, |
|
1139 |
shape character varying(50), |
|
1140 |
area double precision, |
|
1141 |
standsize character varying(50), |
|
1142 |
placementmethod character varying(50), |
|
1143 |
permanence int(1), |
|
1144 |
layoutnarrative text, |
|
1145 |
elevation double precision, |
|
1146 |
elevationaccuracy double precision, |
|
1147 |
elevationrange double precision, |
|
1148 |
slopeaspect double precision, |
|
1149 |
minslopeaspect double precision, |
|
1150 |
maxslopeaspect double precision, |
|
1151 |
slopegradient double precision, |
|
1152 |
minslopegradient double precision, |
|
1153 |
maxslopegradient double precision, |
|
1154 |
topoposition character varying(90), |
|
1155 |
landform character varying(50), |
|
1156 |
surficialdeposits character varying(90), |
|
1157 |
rocktype character varying(90), |
|
1158 |
stateprovince character varying(55), |
|
1159 |
country character varying(100), |
|
1160 |
submitter_surname character varying(100), |
|
1161 |
submitter_givenname character varying(100), |
|
1162 |
submitter_email character varying(100), |
|
1163 |
notespublic int(1), |
|
1164 |
notesmgt int(1), |
|
1165 |
revisions int(1), |
|
1166 |
dateentered timestamp with time zone DEFAULT now(), |
|
1167 |
emb_location int(11), |
|
1168 |
locationrationalenarrative text, |
|
1169 |
accessioncode character varying(255), |
|
1170 |
sublocationxposition double precision, |
|
1171 |
sublocationyposition double precision, |
|
1172 |
namedplace_id int(11) |
|
1173 |
); |
|
1174 |
|
|
1175 |
|
|
1176 |
-- |
|
1177 |
-- Name: location_location_id_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
1178 |
-- |
|
1179 |
|
|
1180 |
CREATE SEQUENCE location_location_id_seq |
|
1181 |
START WITH 1 |
|
1182 |
INCREMENT BY 1 |
|
1183 |
NO MINVALUE |
|
1184 |
NO MAXVALUE |
|
1185 |
CACHE 1; |
|
1186 |
|
|
1187 |
|
|
1188 |
-- |
|
1189 |
-- Name: location_location_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - |
|
1190 |
-- |
|
1191 |
|
|
1192 |
ALTER SEQUENCE location_location_id_seq OWNED BY location.location_id; |
|
1193 |
|
|
1194 |
|
|
1195 |
-- |
|
1196 |
-- Name: locationevent; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
1197 |
-- |
|
1198 |
|
|
1199 |
CREATE TABLE locationevent ( |
|
1200 |
locationevent_id int(11) NOT NULL, |
|
1201 |
previous_id int(11), |
|
1202 |
location_id int(11) NOT NULL, |
|
1203 |
project_id int(11), |
|
1204 |
sourceid character varying(30), |
|
1205 |
dateaccuracy character varying(30), |
|
1206 |
covermethod_id int(11), |
|
1207 |
coverdispersion character varying(30), |
|
1208 |
autotaxoncover int(1), |
|
1209 |
stratummethod_id int(11), |
|
1210 |
methodnarrative text, |
|
1211 |
taxonoccurrencearea double precision, |
|
1212 |
stemsizelimit double precision, |
|
1213 |
stemarea double precision, |
|
1214 |
stemsamplemethod character varying(30), |
|
1215 |
originaldata text, |
|
1216 |
effortlevel character varying(30), |
|
1217 |
locationvalidationlevel int(11), |
|
1218 |
floristicquality character varying(30), |
|
1219 |
bryophytequality character varying(30), |
|
1220 |
lichenquality character varying(30), |
|
1221 |
locationeventnarrative text, |
|
1222 |
landscapenarrative text, |
|
1223 |
homogeneity character varying(50), |
|
1224 |
phenologicaspect character varying(30), |
|
1225 |
representativeness character varying(255), |
|
1226 |
standmaturity character varying(50), |
|
1227 |
successionalstatus text, |
|
1228 |
basalarea double precision, |
|
1229 |
hydrologicregime character varying(30), |
|
1230 |
soilmoistureregime character varying(30), |
|
1231 |
soildrainage character varying(30), |
|
1232 |
watersalinity character varying(30), |
|
1233 |
waterdepth double precision, |
|
1234 |
shoredistance double precision, |
|
1235 |
soildepth double precision, |
|
1236 |
organicdepth double precision, |
|
1237 |
soiltaxon_id int(11), |
|
1238 |
soiltaxonsrc character varying(200), |
|
1239 |
percentbedrock double precision, |
|
1240 |
percentrockgravel double precision, |
|
1241 |
percentwood double precision, |
|
1242 |
percentlitter double precision, |
|
1243 |
percentbaresoil double precision, |
|
1244 |
percentwater double precision, |
|
1245 |
percentother double precision, |
|
1246 |
nameother character varying(30), |
|
1247 |
treeht double precision, |
|
1248 |
shrubht double precision, |
|
1249 |
fieldht double precision, |
|
1250 |
nonvascularht double precision, |
|
1251 |
submergedht double precision, |
|
1252 |
treecover double precision, |
|
1253 |
shrubcover double precision, |
|
1254 |
fieldcover double precision, |
|
1255 |
nonvascularcover double precision, |
|
1256 |
floatingcover double precision, |
|
1257 |
submergedcover double precision, |
|
1258 |
dominantstratum character varying(40), |
|
1259 |
growthform1type character varying(40), |
|
1260 |
growthform2type character varying(40), |
|
1261 |
growthform3type character varying(40), |
|
1262 |
growthform1cover double precision, |
|
1263 |
growthform2cover double precision, |
|
1264 |
growthform3cover double precision, |
|
1265 |
totalcover double precision, |
|
1266 |
notespublic int(1), |
|
1267 |
notesmgt int(1), |
|
1268 |
revisions int(1), |
|
1269 |
obsstartdate timestamp with time zone, |
|
1270 |
obsenddate timestamp with time zone, |
|
1271 |
dateentered timestamp with time zone DEFAULT now(), |
|
1272 |
emb_locationevent int(11), |
|
1273 |
interp_orig_ci_id int(11), |
|
1274 |
interp_orig_cc_id int(11), |
|
1275 |
interp_orig_sciname text, |
|
1276 |
interp_orig_code text, |
|
1277 |
interp_orig_party_id int(11), |
|
1278 |
interp_orig_partyname text, |
|
1279 |
interp_current_ci_id int(11), |
|
1280 |
interp_current_cc_id int(11), |
|
1281 |
interp_current_sciname text, |
|
1282 |
interp_current_code text, |
|
1283 |
interp_current_party_id int(11), |
|
1284 |
interp_current_partyname text, |
|
1285 |
interp_bestfit_ci_id int(11), |
|
1286 |
interp_bestfit_cc_id int(11), |
|
1287 |
interp_bestfit_sciname text, |
|
1288 |
interp_bestfit_code text, |
|
1289 |
interp_bestfit_party_id int(11), |
|
1290 |
interp_bestfit_partyname text, |
|
1291 |
toptaxon1name character varying(255), |
|
1292 |
toptaxon2name character varying(255), |
|
1293 |
toptaxon3name character varying(255), |
|
1294 |
toptaxon4name character varying(255), |
|
1295 |
toptaxon5name character varying(255), |
|
1296 |
numberoftaxa int(11), |
|
1297 |
accessioncode character varying(255) |
|
1298 |
); |
|
1299 |
|
|
1300 |
|
|
1301 |
-- |
|
1302 |
-- Name: TABLE locationevent; Type: COMMENT; Schema: public; Owner: - |
|
1303 |
-- |
|
1304 |
|
|
1305 |
COMMENT ON TABLE locationevent IS 'VegBank''s observation table.'; |
|
1306 |
|
|
1307 |
|
|
1308 |
-- |
|
1309 |
-- Name: locationevent_locationevent_id_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
1310 |
-- |
|
1311 |
|
|
1312 |
CREATE SEQUENCE locationevent_locationevent_id_seq |
|
1313 |
START WITH 1 |
|
1314 |
INCREMENT BY 1 |
|
1315 |
NO MINVALUE |
|
1316 |
NO MAXVALUE |
|
1317 |
CACHE 1; |
|
1318 |
|
|
1319 |
|
|
1320 |
-- |
|
1321 |
-- Name: locationevent_locationevent_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - |
|
1322 |
-- |
|
1323 |
|
|
1324 |
ALTER SEQUENCE locationevent_locationevent_id_seq OWNED BY locationevent.locationevent_id; |
|
1325 |
|
|
1326 |
|
|
1327 |
-- |
|
1328 |
-- Name: locationeventcontributor; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
1329 |
-- |
|
1330 |
|
|
1331 |
CREATE TABLE locationeventcontributor ( |
|
1332 |
locationeventcontributor_id int(11) NOT NULL, |
|
1333 |
locationevent_id int(11) NOT NULL, |
|
1334 |
party_id int(11) NOT NULL, |
|
1335 |
role_id int(11) NOT NULL, |
|
1336 |
contributiondate timestamp with time zone |
|
1337 |
); |
|
1338 |
|
|
1339 |
|
|
1340 |
-- |
|
1341 |
-- Name: locationeventcontributor_locationeventcontributor_id_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
1342 |
-- |
|
1343 |
|
|
1344 |
CREATE SEQUENCE locationeventcontributor_locationeventcontributor_id_seq |
|
1345 |
START WITH 1 |
|
1346 |
INCREMENT BY 1 |
|
1347 |
NO MINVALUE |
|
1348 |
NO MAXVALUE |
|
1349 |
CACHE 1; |
|
1350 |
|
|
1351 |
|
|
1352 |
-- |
|
1353 |
-- Name: locationeventcontributor_locationeventcontributor_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - |
|
1354 |
-- |
|
1355 |
|
|
1356 |
ALTER SEQUENCE locationeventcontributor_locationeventcontributor_id_seq OWNED BY locationeventcontributor.locationeventcontributor_id; |
|
1357 |
|
|
1358 |
|
|
1359 |
-- |
|
1360 |
-- Name: locationeventsynonym; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
1361 |
-- |
|
1362 |
|
|
1363 |
CREATE TABLE locationeventsynonym ( |
|
1364 |
locationeventsynonym_id int(11) NOT NULL, |
|
1365 |
synonymlocationevent_id int(11) NOT NULL, |
|
1366 |
primarylocationevent_id int(11) NOT NULL, |
|
1367 |
party_id int(11) NOT NULL, |
|
1368 |
role_id int(11) NOT NULL, |
|
1369 |
synonymcomment text, |
|
1370 |
classstartdate timestamp with time zone DEFAULT now() NOT NULL, |
|
1371 |
classstopdate timestamp with time zone, |
|
1372 |
accessioncode character varying(255) |
|
1373 |
); |
|
1374 |
|
|
1375 |
|
|
1376 |
-- |
|
1377 |
-- Name: locationeventsynonym_locationeventsynonym_id_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
1378 |
-- |
|
1379 |
|
|
1380 |
CREATE SEQUENCE locationeventsynonym_locationeventsynonym_id_seq |
|
1381 |
START WITH 1 |
|
1382 |
INCREMENT BY 1 |
|
1383 |
NO MINVALUE |
|
1384 |
NO MAXVALUE |
|
1385 |
CACHE 1; |
|
1386 |
|
|
1387 |
|
|
1388 |
-- |
|
1389 |
-- Name: locationeventsynonym_locationeventsynonym_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - |
|
1390 |
-- |
|
1391 |
|
|
1392 |
ALTER SEQUENCE locationeventsynonym_locationeventsynonym_id_seq OWNED BY locationeventsynonym.locationeventsynonym_id; |
|
1393 |
|
|
1394 |
|
|
1395 |
-- |
|
1396 |
-- Name: namedplace; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
1397 |
-- |
|
1398 |
|
|
1399 |
CREATE TABLE namedplace ( |
|
1400 |
namedplace_id int(11) NOT NULL, |
|
1401 |
placesystem character varying(50), |
|
1402 |
placename character varying(100) NOT NULL, |
|
1403 |
placedescription text, |
|
1404 |
placecode character varying(15), |
|
1405 |
owner character varying(100), |
|
1406 |
reference_id int(11), |
|
1407 |
d_obscount int(11), |
|
1408 |
accessioncode character varying(255) |
|
1409 |
); |
|
1410 |
|
|
1411 |
|
|
1412 |
-- |
|
1413 |
-- Name: namedplace_namedplace_id_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
1414 |
-- |
|
1415 |
|
|
1416 |
CREATE SEQUENCE namedplace_namedplace_id_seq |
|
1417 |
START WITH 1 |
|
1418 |
INCREMENT BY 1 |
|
1419 |
NO MINVALUE |
|
1420 |
NO MAXVALUE |
|
1421 |
CACHE 1; |
|
1422 |
|
|
1423 |
|
|
1424 |
-- |
|
1425 |
-- Name: namedplace_namedplace_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - |
|
1426 |
-- |
|
1427 |
|
|
1428 |
ALTER SEQUENCE namedplace_namedplace_id_seq OWNED BY namedplace.namedplace_id; |
|
1429 |
|
|
1430 |
|
|
1431 |
-- |
|
1432 |
-- Name: namedplacecorrelation; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
1433 |
-- |
|
1434 |
|
|
1435 |
CREATE TABLE namedplacecorrelation ( |
|
1436 |
namedplacecorrelation_id int(11) NOT NULL, |
|
1437 |
parentplace_id int(11) NOT NULL, |
|
1438 |
childplace_id int(11) NOT NULL, |
|
1439 |
placeconvergence character varying(20) NOT NULL |
|
1440 |
); |
|
1441 |
|
|
1442 |
|
|
1443 |
-- |
|
1444 |
-- Name: namedplacecorrelation_namedplacecorrelation_id_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
1445 |
-- |
|
1446 |
|
|
1447 |
CREATE SEQUENCE namedplacecorrelation_namedplacecorrelation_id_seq |
|
1448 |
START WITH 1 |
|
1449 |
INCREMENT BY 1 |
|
1450 |
NO MINVALUE |
|
1451 |
NO MAXVALUE |
|
1452 |
CACHE 1; |
|
1453 |
|
|
1454 |
|
|
1455 |
-- |
|
1456 |
-- Name: namedplacecorrelation_namedplacecorrelation_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - |
|
1457 |
-- |
|
1458 |
|
|
1459 |
ALTER SEQUENCE namedplacecorrelation_namedplacecorrelation_id_seq OWNED BY namedplacecorrelation.namedplacecorrelation_id; |
|
1460 |
|
|
1461 |
|
|
1462 |
-- |
|
1463 |
-- Name: note; Type: TABLE; Schema: public; Owner: -; Tablespace: |
|
1464 |
-- |
|
1465 |
|
|
1466 |
CREATE TABLE note ( |
|
1467 |
note_id int(11) NOT NULL, |
|
1468 |
notelink_id int(11) NOT NULL, |
|
1469 |
party_id int(11) NOT NULL, |
|
1470 |
role_id int(11) NOT NULL, |
|
1471 |
notetype character varying(20) NOT NULL, |
|
1472 |
notetext text NOT NULL, |
|
1473 |
notedate timestamp with time zone, |
|
1474 |
accessioncode character varying(255) |
|
1475 |
); |
|
1476 |
|
|
1477 |
|
|
1478 |
-- |
|
1479 |
-- Name: note_note_id_seq; Type: SEQUENCE; Schema: public; Owner: - |
|
1480 |
-- |
|
1481 |
|
|
1482 |
CREATE SEQUENCE note_note_id_seq |
|
1483 |
START WITH 1 |
|
1484 |
INCREMENT BY 1 |
|
1485 |
NO MINVALUE |
|
1486 |
NO MAXVALUE |
|
1487 |
CACHE 1; |
|
1488 |
|
|
1489 |
|
|
1490 |
-- |
|
1491 |
-- Name: note_note_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: - |
|
1492 |
-- |
|
1493 |
|
|
1494 |
ALTER SEQUENCE note_note_id_seq OWNED BY note.note_id; |
|
1495 |
|
|
1496 |
|
Also available in: Unified diff
Generate MySQL DDL schemas/vegbien.my.sql from vegbien.sql