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