1
|
DROP SEQUENCE identifier_id_seq;
|
2
|
DROP TRIGGER identifier_before_insert;
|
3
|
DROP TABLE identifier;
|
4
|
|
5
|
CREATE TABLE systemMetadata (
|
6
|
guid VARCHAR2(2000), -- the globally unique string identifier
|
7
|
docid VARCHAR(250), -- the local document id #
|
8
|
rev NUMBER(8) -- the revision part of the local identifier
|
9
|
)
|
10
|
|
11
|
CREATE TABLE identifier (
|
12
|
guid VARCHAR2(2000), -- the globally unique string identifier
|
13
|
docid VARCHAR2(250), -- the local document id #
|
14
|
rev NUMBER(8) -- the revision part of the local identifier
|
15
|
);
|
16
|
|
17
|
/*
|
18
|
* Register the DataONE schemas
|
19
|
*/
|
20
|
INSERT INTO xml_catalog (entry_type, public_id, system_id)
|
21
|
VALUES ('Schema', 'http://dataone.org/service/types/SystemMetadata/0.1', '/schema/D1_SCHEMA_0_1/systemmetadata.xsd');
|
22
|
INSERT INTO xml_catalog (entry_type, public_id, system_id)
|
23
|
VALUES ('Schema', 'http://dataone.org/service/types/common/0.1', '/schema/D1_SCHEMA_0_1/common.xsd');
|
24
|
|
25
|
/*
|
26
|
* update the database version
|
27
|
*/
|
28
|
UPDATE db_version SET status=0;
|
29
|
|
30
|
INSERT INTO db_version (version, status, date_created)
|
31
|
VALUES ('1.10.0', 1, CURRENT_DATE);
|