Project

General

Profile

« Previous | Next » 

Revision 5371

Added by berkley about 14 years ago

added systemMetadata table to the upgrade scripts

View differences:

src/xmltables-oracle.sql
61 61
DROP TABLE xml_replication;
62 62
DROP TABLE xml_catalog;
63 63
DROP TABLE identifier;
64
DROP TABLE systemMetadata;
64 65
DROP TABLE access_log;
65 66
DROP TABLE harvest_site_schedule;
66 67
DROP TABLE harvest_detail_log;
......
393 394
/
394 395

  
395 396
/*
397
 * Table used to store all document identifiers for system metadata objects
398
 * similar restraints to identifier.  Cannot use identifier table for this 
399
 * purpose because then you have to worry about whether you insert the
400
 * data first or the systemMetadata first.
401
 */
402
CREATE TABLE systemMetadata (
403
   guid   VARCHAR2(2000),    -- the globally unique string identifier
404
   docid  VARCHAR(250), 	 -- the local document id #
405
   rev    NUMBER(8)          -- the revision part of the local identifier
406
)
407

  
408
/*
396 409
 * Table used to store all document identifiers in metacat.  Each identifier
397 410
 * has a globally unique, unconstrained string, which we will refer to as a
398 411
 * GUID, and a local metacat identifier, which consists of the docid
src/upgrade-db-to-1.10.0-postgres.sql
1 1
DROP TABLE identifier;
2 2
DROP SEQUENCE identifier_id_seq;
3
DROP TABLE systemMetadata;
4
DROP SEQUENCE systemMetadata_id_seq;
3 5

  
6
CREATE TABLE systemMetadata (
7
   guid   text,          -- the globally unique string identifier
8
   docid  VARCHAR(250),	 -- the local document id #
9
   rev    INT8,          -- the revision part of the local identifier
10
   CONSTRAINT systemMetadata_pk PRIMARY KEY (guid)
11
);
12

  
4 13
CREATE TABLE identifier (
5 14
   guid   text,          -- the globally unique string identifier
6 15
   docid  VARCHAR(250),  -- the local document id #
src/upgrade-db-to-1.10.0-oracle.sql
1 1
DROP SEQUENCE identifier_id_seq;
2 2
DROP TRIGGER identifier_before_insert;
3 3
DROP TABLE identifier;
4
DROP SEQUENCE systemMetadata_id_seq;
5
DROP TRIGGER systemMetadata_before_insert;
6
DROP TABLE systemMetadata;
4 7

  
5
/*
6
 * Table used to store all document identifiers in metacat.  Each identifier
7
 * has a globally unique, unconstrained string, which we will refer to as a
8
 * GUID, and a local metacat identifier, which consists of the docid
9
 * and revision fields. Each row maps one global identifier to the local
10
 * identifier (docid) used within metacat.
11
 */
8
CREATE TABLE systemMetadata (
9
   guid   VARCHAR2(2000),    -- the globally unique string identifier
10
   docid  VARCHAR(250), 	 -- the local document id #
11
   rev    NUMBER(8)          -- the revision part of the local identifier
12
)
13

  
12 14
CREATE TABLE identifier (
13 15
   guid   VARCHAR2(2000), -- the globally unique string identifier
14 16
   docid  VARCHAR2(250),  -- the local document id #

Also available in: Unified diff