Warehouse Data Definition Language (DDL)

advertisement
THE DATA WAREHOUSE DEFINITIONS
To create the Data Warehouse schema the Data Definition Language (DDL) scripts included below will
generate the sequences, tables and constraints respectively in the first three sections. The description of the
elements in the in final fourth section.
1. Sequences
PROMPT Creating sequences for schema Warehouse
CREATE SEQUENCE SEQCOMPONENT_ID
MINVALUE
50
INCREMENT BY 1
ORDER NOCACHE;
CREATE SEQUENCE SEQ_DATA_ID
MINVALUE 19000
INCREMENT BY 1
ORDER NOCACHE;
CREATE SEQUENCE SEQ_DEPLOYMENT_ID
MINVALUE 13000
INCREMENT BY 1
ORDER NOCACHE;
CREATE SEQUENCE SEQ_TEMP_TABLE
MINVALUE 0
INCREMENT BY 1
ORDER NOCACHE;
2. Warehouse Tables
PROMPT Creating tables for schema warehouse
PROMPT Creating table ADCP_SHIP_DATA
CREATE TABLE ADCP_SHIP_DATA
(
DATA_ID
NUMBER(12)
NOT NULL,
CALCULATED_DEPTH
NUMBER(5,1)
NOT NULL,
BIN_NUMBER
NUMBER(4),
U_CORRECTED_VALUE
NUMBER(4,2),
V_CORRECTED_VALUE
NUMBER(4,2),
AV_QC
NUMBER(5,2),
BIN_ATTENDANCE_PERCENTAGE
NUMBER(3),
CONSTRAINT ADCP_SHIP_DATA_PK
PRIMARY KEY ( DATA_ID, CALCULATED_DEPTH )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
PROMPT Creating table
ADCP_SHIP_DEPLOYMENT
CREATE TABLE ADCP_SHIP_DEPLOYMENT
(
DEPLOYMENT_ID
NUMBER(8)
DEPTH_CELL_LENGTH
NUMBER(5),
NOT NULL,
BLANK_AFTER_TRANSMIT
NUMBER(5),
NOMINAL_ADCP_DEPTH
NUMBER(6),
NUMBER_DEPTH_CELLS
NUMBER(4),
PINGS_PER_ENSEMBLE
NUMBER(3),
TIME_BETWEEN_PINGS
NUMBER(5),
MAGNETIC_DECLINATION
NUMBER(4,2),
NOMINAL_SALINITY
NUMBER(5,2),
ENSEMBLE_PERIOD
NUMBER(10),
PROFILING_MODE
NUMBER(2),
METHOD_CODE
VARCHAR2(16),
CONFIGURATION_FILE
VARCHAR2(40),
LOCATION_COMMENT
VARCHAR2(80),
TIME_COMMENT
VARCHAR2(80),
CONSTRAINT ADCP_SHIP_DEPL_PK
PRIMARY KEY ( DEPLOYMENT_ID )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
PROMPT Creating table ADCP_SHIP_HEADER
CREATE TABLE ADCP_SHIP_HEADER
(
DATA_ID
NUMBER(12)
DEPLOYMENT_ID
NUMBER(8)
START_TIME
DATE,
MEAN_LAT
NUMBER(7,5),
MEAN_LON
NUMBER(8,5),
VELOCITY_REFERENCE
VARCHAR2(10),
HEADING_TYPE
VARCHAR2(10),
AVERAGING_PERIOD
NUMBER(5),
BIN_LENGTH
NUMBER(3),
PING_LENGTH
NUMBER(3),
DELAY
NUMBER(3),
PERCENT_COVER
NUMBER(3),
U_SHIP
NUMBER(4,2),
V_SHIP
NUMBER(4,2),
PERCENT_BT_COVER
NUMBER(3),
BT_DEPTH
NUMBER(5),
MEAN_BT_ERROR_VELOCITY
NUMBER(3),
MEAN_PERCENT_GOOD_BT_PINGS NUMBER(3),
PROJECT_ID
NUMBER(7)
MARLIN_ID
NUMBER(7)
SECURITY_CODE
NUMBER(1),
LICENCE_NOTE
VARCHAR(40),
CONSTRAINT ADCP_SHIP_HEADER_PK
PRIMARY KEY ( DATA_ID )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
NOT NULL,
NOT NULL,
NOT NULL,
NOT NULL,
PROMPT Creating table CAAB_GROUP
CREATE TABLE CAAB_GROUP
(
GROUP_NAME
REGULAR_START_CODE
REGULAR_END_CODE
VARCHAR2(50)
NUMBER(8),
NUMBER(8),
NOT NULL,
IRREGULAR_START_CODE
NUMBER(8),
IRREGULAR_END_CODE
NUMBER(8),
ASSIGNED_FAMILY_START
NUMBER(3),
ASSIGNED_FAMILY_END
NUMBER(3),
CONSTRAINT CAAB_GROUP_PK
PRIMARY KEY ( GROUP_NAME )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
PROMPT Creating table CAAB_SPECIES_LIST
CREATE TABLE CAAB_SPECIES_LIST
(
SPECIES_CODE
NUMBER(8)
SCIENTIFIC_NAME
VARCHAR2(255),
COMMON_NAME
VARCHAR2(255),
ASSIGNED_FAMILY_CODE
NUMBER(3),
IS_CURRENT
VARCHAR2(1)
SUPERCEDED_BY
NUMBER(8),
CONSTRAINT CAAB_SPECIES_LIST_PK
PRIMARY KEY ( SPECIES_CODE )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
NOT NULL,
NOT NULL,
PROMPT Creating table CATCH_ADD_ATTRIBUTE
CREATE TABLE CATCH_ADD_ATTRIBUTE
(
DATA_ID
NUMBER(12)
NOT NULL,
PARAMETER_CODE
VARCHAR2(20)
NOT NULL,
VALUE
VARCHAR(20)
NOT NULL,
CONSTRAINT CATCH_ADD_ATTRIBUTE_PK
PRIMARY KEY ( DATA_ID, PARAMETER_CODE )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
PROMPT Creating table CATCH_COMPOSITION_DATA
CREATE TABLE CATCH_COMPOSITION_DATA
(
DATA_ID
NUMBER(12)
NOT NULL,
QUANTITY_MEASURED_CODE
VARCHAR2(16)
NOT NULL,
CAAB_SPECIES_CODE
NUMBER(8)
NOT NULL,
ORIGINAL_SPECIES_CODE
NUMBER(8),
SPECIES_ID_QC_FLAG
NUMBER(3)
NOT NULL,
CATCH_COUNT
NUMBER(5),
CATCH_COUNT_QC_FLAG
NUMBER(3),
CATCH_WEIGHT
NUMBER(7,3),
CATCH_WEIGHT_QC_FLAG
NUMBER(3),
SPECIMEN_DATA_FLAG
VARCHAR2(1),
COMMENTS
VARCHAR2(255),
CONSTRAINT CATCH_COMPOSITION_DATA_PK
PRIMARY KEY ( DATA_ID, CAAB_SPECIES_CODE, QUANTITY_MEASURED_CODE )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
PROMPT Creating table CATCH_GEOMETRY
CREATE TABLE CATCH_GEOMETRY
(
DATA_ID
NUMBER(12)
NOT NULL,
SURVEY_NAME
VARCHAR2(12),
OPERATION_NO
NUMBER(4),
SECURITY_CODE
NUMBER(1),
LICENCE_NOTE
VARCHAR(40),
MI_PRINX
NUMBER
NOT NULL,
GEOLOC
MDSYS.SDO_GEOMETRY,
CONSTRAINT CATCH_GEOMETRY_PK
PRIMARY KEY ( DATA_ID )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
PROMPT Creating table CATCH_HEADER
CREATE TABLE CATCH_HEADER
(
DATA_ID
NUMBER(12)
DEPLOYMENT_ID
NUMBER(8)
COMPONENT_ID
NUMBER(6)
COMPONENT_NO
NUMBER(2),
SURVEY_NAME
VARCHAR2(12)
START_TIME
DATE,
END_TIME
DATE,
UTC_OFFSET
NUMBER(3,1),
START_LAT
NUMBER(7,5),
START_LON
NUMBER(8,5),
END_LAT
NUMBER(7,5),
END_LON
NUMBER(8,5),
START_DEPTH
NUMBER(5),
END_DEPTH
NUMBER(5),
MIN_DEPTH
NUMBER(5),
MAX_DEPTH
NUMBER(5),
TOTAL_CATCH_WT
NUMBER(7,3),
FRACTION_SAMPLED
NUMBER(4,1),
SAMPLED_CATCH_WT
NUMBER(7,3),
SUBSAMPLED_CATCH_WT
NUMBER(7,3),
DISCARDED_CATCH_WT
NUMBER(7,3),
ADD_ATTRIBUTE_FLAG
VARCHAR2(1),
CATCH_METHOD
VARCHAR(16),
CATCH_EFFORT
NUMBER(8),
COMMENTS
VARCHAR2(255),
PROJECT_ID
NUMBER(7)
GLOBAL_PROJECT_ID
NUMBER(7),
MARLIN_ID
NUMBER(7)
SECURITY_CODE
NUMBER(1),
RELEASE_DATE
DATE,
LICENCE_NOTE
VARCHAR(40),
CONSTRAINT CATCH_HEADER_PK
PRIMARY KEY ( DATA_ID )
USING INDEX PCTFREE 5
NOT NULL,
NOT NULL,
NOT NULL,
NOT NULL,
NOT NULL,
NOT NULL,
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K),
CONSTRAINT CATCH_HEADER_UK1
UNIQUE ( DEPLOYMENT_ID, COMPONENT_ID )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
PROMPT Creating index CATCH_HEADER_POS_INDX
CREATE INDEX CATCH_HEADER_POS_INDX ON CATCH_HEADER
( START_LAT ASC, START_LON ASC )
PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K);
PROMPT Creating index CATCH_HEADER_TIME_INDX
CREATE INDEX CATCH_HEADER_TIME_INDX ON CATCH_HEADER
( START_TIME ASC )
PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K);
PROMPT Creating table CATCH_MEASUREMENT_DATA
CREATE TABLE CATCH_MEASUREMENT_DATA
(
DATA_ID
NUMBER(12)
NOT NULL,
CAAB_SPECIES_CODE
NUMBER(8)
NOT NULL,
ORIGINAL_SPECIES_CODE
NUMBER(8),
SEX_CODE
VARCHAR2(10)
NOT NULL,
MEDIAN_LENGTH
NUMBER(7,2)
NOT NULL,
INTERVAL_WIDTH
NUMBER(2,2)
NOT NULL,
SPECIMEN_COUNT
NUMBER(5)
NOT NULL,
COUNT_QC_FLAG
NUMBER(3)
NOT NULL,
LENGTH_METHOD_CODE
VARCHAR2(2),
COMMENTS
VARCHAR2(255),
CONSTRAINT CATCH_MEASUREMENT_DATA_PK
PRIMARY KEY ( DATA_ID, CAAB_SPECIES_CODE, SEX_CODE, MEDIAN_LENGTH )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
PROMPT Creating table CATCH_SPECIMEN_DATA
CREATE TABLE CATCH_SPECIMEN_DATA
(
DATA_ID
NUMBER(12)
CAAB_SPECIES_CODE
NUMBER(8)
ORIGINAL_SPECIES_CODE
NUMBER(8),
QUANTITY_MEASURED_CODE
VARCHAR2(1)
SPECIMEN_NUMBER
NUMBER(3)
SEX_CODE
VARCHAR2(10),
LENGTH
NUMBER(7,2),
LENGTH_METHOD_CODE
VARCHAR2(2),
LENGTH_QC_FLAG
NUMBER(3),
NOT NULL,
NOT NULL,
NOT NULL,
NOT NULL,
WEIGHT
NUMBER(7,3),
WEIGHT_METHOD_CODE
VARCHAR2(2),
WEIGHT_QC_FLAG
NUMBER(3),
MATURATION_STAGE_CODE
VARCHAR2(6),
MAT_STAGE_QC_FLAG
NUMBER(3),
GONAD_WEIGHT
NUMBER(8,4),
GONAD_WT_QC_FLAG
NUMBER(3),
STOMACH_FULLNESS_CODE
VARCHAR2(6),
STOMACH_FULL_QC_FLAG
NUMBER(3),
COMMENTS
VARCHAR2(255),
CONSTRAINT CATCH_SPECIMEN_DATA_PK
PRIMARY KEY ( DATA_ID, CAAB_SPECIES_CODE, SPECIMEN_NUMBER )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
PROMPT Creating table CODE_LIST
CREATE TABLE CODE_LIST
(
CODE_NAME
VARCHAR2(16)
NOT NULL,
CODE_VALUE
VARCHAR2(16)
NOT NULL,
CODE_VALUE_DESCRIPTION
VARCHAR2(80),
CONSTRAINT CODE_LIST_PK
PRIMARY KEY ( CODE_NAME, CODE_VALUE )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
-- CONSTRAINT CODE_LIST_UK
-UNIQUE ( CODE_NAME )
-USING INDEX PCTFREE 5
-TABLESPACE
INDX
-STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
PROMPT Creating table CODE_NAME_LIST
CREATE TABLE CODE_NAME_LIST
(
CODE_NAME
VARCHAR2(16)
CODE_NAME_DESCRIPTION
VARCHAR2(80),
CONSTRAINT CODE_NAME_LIST_PK
PRIMARY KEY ( CODE_NAME )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
NOT NULL,
PROMPT Creating table COMPONENT
CREATE TABLE COMPONENT
(
COMPONENT_ID
SUB_COMPONENT_OF
COMMISSION_DATE
DECOMMISSION_DATE
MANUFACTURER
MODEL_NO
NUMBER(6)
NUMBER(6),
DATE,
DATE,
VARCHAR2(16),
VARCHAR2(16),
NOT NULL,
SERIAL_NO
VARCHAR2(16),
PARAMETER_CODE
VARCHAR2(20)
CSIRO_TRAWL_GEAR_CODE
NUMBER(4),
NAME
VARCHAR2(80),
DESCRIPTION
VARCHAR2(255),
CONSTRAINT COMPONENT_PK
PRIMARY KEY ( COMPONENT_ID )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
NOT NULL,
PROMPT Creating table CTD_DATA
CREATE TABLE CTD_DATA
(
DATA_ID
NUMBER(12)
NOT NULL,
PRESSURE
NUMBER(5,1)
NOT NULL,
PARAMETER_CODE
VARCHAR2(20)
NOT NULL,
VALUE
NUMBER(16,6),
QC_FLAG
NUMBER(3),
CONSTRAINT CTD_DATA_PK
PRIMARY KEY ( DATA_ID, PRESSURE, PARAMETER_CODE )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85 STORAGE (INITIAL 512K NEXT 512K PCTINCREASE 0);
PROMPT Creating table CTD_GEOMETRY
CREATE TABLE CTD_GEOMETRY
(
DATA_ID
NUMBER(12)
NOT NULL,
SURVEY_NAME
VARCHAR2(12)
NOT NULL,
STATION_NO
NUMBER(6),
MI_PRINX
NUMBER
NOT NULL,
GEOLOC
MDSYS.SDO_GEOMETRY,
SECURITY_CODE
NUMBER(1),
LICENCE_NOTE
VARCHAR(40),
CONSTRAINT CTD_GEOMETRY_PK
PRIMARY KEY ( DATA_ID )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
PROMPT Creating table CTD_HEADER
CREATE TABLE CTD_HEADER
(
DATA_ID
DEPLOYMENT_ID
CAST_NO
SURVEY_NAME
START_TIME
END_TIME
MIN_DEPTH
MAX_DEPTH
BOTTOM_DEPTH
BOTTOM_TIME
BOTTOM_LAT
NUMBER(12)
NUMBER(8)
NUMBER(4),
VARCHAR2(12)
DATE
DATE
NUMBER(5,1),
NUMBER(5,1),
NUMBER(5,1),
DATE,
NUMBER(7,5),
NOT NULL,
NOT NULL,
NOT NULL,
NOT NULL,
NOT NULL,
BOTTOM_LON
NUMBER(8,5),
END_LAT
NUMBER(7,5),
END_LON
NUMBER(8,5),
START_LAT
NUMBER(7,5),
START_LON
NUMBER(8,5),
PROJECT_ID
NUMBER(7)
NOT NULL,
GLOBAL_PROJECT_ID
NUMBER(7),
MARLIN_ID
NUMBER(7)
NOT NULL,
SECURITY_CODE
NUMBER(1),
RELEASE_DATE
DATE,
LICENCE_NOTE
VARCHAR(40),
COMMENTS
VARCHAR2(255),
CONSTRAINT CTD_HEADER_PK
PRIMARY KEY ( DATA_ID )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K),
CONSTRAINT CTD_HEADER_UK
UNIQUE ( SURVEY_NAME, DEPLOYMENT_ID, CAST_NO )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
PROMPT Creating index CTD_HEADER_POS_INDX
CREATE INDEX CTD_HEADER_POS_INDX ON CTD_HEADER
( START_LAT ASC, START_LON ASC )
PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K);
PROMPT Creating index CTD_HEADER_TIME_INDX
CREATE INDEX CTD_HEADER_TIME_INDX ON CTD_HEADER
( START_TIME ASC )
PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K);
PROMPT Creating table DATA_SUMMARY
CREATE TABLE DATA_SUMMARY
(
DATA_ID
NUMBER(12)
DATA_STREAM_TYPE
VARCHAR2(16)
SURVEY_NAME
VARCHAR2(12),
DEPLOYMENT_ID
NUMBER(8),
PROJECT_ID
NUMBER(7)
START_TIME
DATE,
END_TIME
DATE,
MIN_DEPTH
NUMBER(5,1),
MAX_DEPTH
NUMBER(5,1),
MIN_LAT
NUMBER(7,5),
MAX_LAT
NUMBER(7,5),
MIN_LON
NUMBER(8,5),
MAX_LON
NUMBER(8,5),
DESCRIPTION
VARCHAR2(200),
CONSTRAINT DATA_SUMMARY_PK
PRIMARY KEY ( DATA_ID )
USING INDEX PCTFREE 5
TABLESPACE
INDX
NOT NULL,
NOT NULL,
NOT NULL,
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
PROMPT Creating index DATA_SUMMARY_MAXPOS_INDX
CREATE INDEX DATA_SUMMARY_MAXPOS_INDX ON
DATA_SUMMARY ( MAX_LAT ASC, MAX_LON ASC )
PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K);
PROMPT Creating index DATA_SUMMARY_MINPOS_INDX
CREATE INDEX DATA_SUMMARY_MINPOS_INDX ON
DATA_SUMMARY ( MIN_LAT ASC, MIN_LON ASC )
PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K);
PROMPT Creating index DATA_SUMM_HEADER_TIME_INDX
CREATE INDEX DATA_SUMM_HEADER_TIME_INDX ON
DATA_SUMMARY ( START_TIME ASC )
PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K);
PROMPT Creating table DEPLOYMENT
CREATE TABLE DEPLOYMENT
(
DEPLOYMENT_ID
NUMBER(8)
DEPLOYMENT_TYPE
VARCHAR2(16)
SOURCE_ID
NUMBER(7),
PROJECT_ID
NUMBER(7),
SURVEY_NAME
VARCHAR2(12)
START_TIME
DATE,
END_TIME
DATE,
OPERATION_NO
NUMBER(4),
MAX_DEPTH
NUMBER(5,1),
STATION_NO
NUMBER(10),
START_LAT
NUMBER(7,5),
START_LON
NUMBER(8,5),
END_LAT
NUMBER(7,5),
END_LON
NUMBER(8,5),
LOCATION_SELECTION
VARCHAR2(16),
DESCRIPTION
VARCHAR2(80),
COMMENTS
VARCHAR2(255),
CONSTRAINT DEPLOYMENT_PK
PRIMARY KEY ( DEPLOYMENT_ID )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
NOT NULL,
NOT NULL,
NOT NULL,
PROMPT Creating index DEPLOYMENT_POS_INDX
CREATE INDEX DEPLOYMENT_POS_INDX ON DEPLOYMENT
( START_LAT ASC, START_LON ASC )
PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K);
PROMPT Creating index DEPLOYMENT_TIME_INDX
CREATE INDEX DEPLOYMENT_TIME_INDX ON DEPLOYMENT
( START_TIME ASC )
PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K);
PROMPT Creating table DEPLOYMENT_COMPONENT
CREATE TABLE DEPLOYMENT_COMPONENT
(
DEPLOYMENT_ID
NUMBER(8)
NOT NULL,
COMPONENT_NO
NUMBER(2)
NOT NULL,
COMPONENT_ID
NUMBER(6)
NOT NULL,
CONSTRAINT DEPLOYMENT_COMPONENT_PK
PRIMARY KEY ( DEPLOYMENT_ID, COMPONENT_ID, COMPONENT_NO )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85 ;
PROMPT Creating table DEPLOYMENT_OBSERVATION
CREATE TABLE DEPLOYMENT_OBSERVATION
(
DEPLOYMENT_ID
NUMBER(8)
NOT NULL,
PARAMETER_CODE
VARCHAR2(20)
NOT NULL,
VALUE
VARCHAR2(20)
NOT NULL,
QC_FLAG
NUMBER(3)
NOT NULL,
CONSTRAINT DEPLOYMENT_OBSERVATION_PK
PRIMARY KEY ( DEPLOYMENT_ID, PARAMETER_CODE )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
PROMPT Creating table GIS_DATA
CREATE TABLE GIS_DATA
(
DATA_ID
NUMBER(12)
NOT NULL,
SOURCE_FILE_NAME
VARCHAR(100),
SOURCE_FILE_DESCRIPTION VARCHAR(256),
CONSTRAINT GIS_DATA_PK
PRIMARY KEY ( DATA_ID, SOURCE_FILE_NAME )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
PROMPT Creating table GIS_HEADER
CREATE TABLE GIS_HEADER
(
DATA_ID
NUMBER(12)
GIS_TYPE
VARCHAR(10)
PARAMETER_CODE
VARCHAR(20),
DOWNLOAD_FILE
VARCHAR(100),
LAYER_DESCRIPTION
VARCHAR(200),
LAYER_LABEL
VARCHAR(30),
PROJECT_ID
NUMBER(7)
GLOBAL_PROJECT_ID
NUMBER(7),
MARLIN_ID
NUMBER(7)
SECURITY_CODE
NUMBER(1),
RELEASE_DATE
DATE,
LICENCE_NOTE
VARCHAR(40),
CONSTRAINT GIS_HEADER_PK
PRIMARY KEY ( DATA_ID )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
NOT NULL,
NOT NULL,
NOT NULL,
NOT NULL,
PROMPT Creating table GLOBAL_PROJECT
CREATE TABLE GLOBAL_PROJECT
(
GLOBAL_PROJECT_ID
NUMBER(7)
GLOBAL_PROJECT_NAME
VARCHAR2(20),
DESCRIPTION
VARCHAR2(120),
CONSTRAINT PROJECT_PK
PRIMARY KEY ( GLOBAL_PROJECT_ID )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
NOT NULL,
PROMPT Creating table HYDROCHEM_ANALYTICAL_METHOD
CREATE TABLE HYDROCHEM_ANALYTICAL_METHOD
(
METHOD_CODE
VARCHAR2(16)
NOT NULL,
APPLICATION_DATE
DATE
NOT NULL,
DESCRIPTION
VARCHAR2(80),
REFERENCE
VARCHAR2(80),
CONSTRAINT HYDRCHEM_METHOD_PK
PRIMARY KEY ( METHOD_CODE, APPLICATION_DATE )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
PROMPT Creating table HYDROLOGY_ANALYSIS
CREATE TABLE HYDROLOGY_ANALYSIS
(
DATA_ID
NUMBER(12)
ANALYTE_CODE
VARCHAR2(16)
METHOD_CODE
VARCHAR2(16)
NOT NULL,
NOT NULL,
NOT NULL,
APPLICATION_DATE DATE NOT NULL,
CONSTRAINT HYDROALYSIS_METHOD_PK
PRIMARY KEY ( DATA_ID, ANALYTE_CODE, METHOD_CODE, APPLICATION_DATE
)
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
PROMPT Creating table HYDROLOGY_DATA
CREATE TABLE HYDROLOGY_DATA
(
DATA_ID
NUMBER(12)
NOT NULL,
PRESSURE
NUMBER(5,1)
NOT NULL,
PARAMETER_CODE
VARCHAR2(20)
NOT NULL,
BOTTLE_NUMBER
NUMBER(6)
NOT NULL,
VALUE
NUMBER(16,6),
QC_FLAG
NUMBER(3),
CONSTRAINT HYDROLOGY_DATA_PK
PRIMARY KEY ( DATA_ID, PRESSURE, BOTTLE_NUMBER, PARAMETER_CODE )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
PROMPT Creating table HYDROLOGY_GEOMETRY
CREATE TABLE HYDROLOGY_GEOMETRY
(
DATA_ID
NUMBER(12)
NOT NULL,
MI_PRINX
NUMBER
NOT NULL,
GEOLOC
MDSYS.SDO_GEOMETRY,
SECURITY_CODE
NUMBER(1),
LICENCE_NOTE
VARCHAR(40),
CONSTRAINT HYDROLOGY_GEOMETRY_PK
PRIMARY KEY ( DATA_ID )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
PROMPT Creating table HYDROLOGY_HEADER
CREATE TABLE HYDROLOGY_HEADER
(
DATA_ID
NUMBER(12)
DEPLOYMENT_ID
NUMBER(8)
SURVEY_NAME
VARCHAR2(12)
CAST_NO
NUMBER(10),
START_TIME
DATE
END_TIME
DATE
MIN_DEPTH
NUMBER(5,1),
MAX_DEPTH
NUMBER(5,1),
BOTTOM_DEPTH
NUMBER(5,1),
BOTTOM_TIME
DATE,
BOTTOM_LAT
NUMBER(7,5),
BOTTOM_LON
NUMBER(8,5),
END_LAT
NUMBER(7,5),
END_LON
NUMBER(8,5),
NOT NULL,
NOT NULL,
NOT NULL,
NOT NULL,
NOT NULL,
START_LAT
NUMBER(7,5),
START_LON
NUMBER(8,5),
PROJECT_ID
NUMBER(7)
GLOBAL_PROJECT_ID
NUMBER(7),
MARLIN_ID
NUMBER(7)
SECURITY_CODE
NUMBER(1),
RELEASE_DATE
DATE,
LICENCE_NOTE
VARCHAR(40),
CONSTRAINT HYDROLOGY_HEADER_PK
PRIMARY KEY ( DATA_ID )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K),
CONSTRAINT HYDROLOGY_HEADER_UK
UNIQUE ( SURVEY_NAME, CAST_NO )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
NOT NULL,
NOT NULL,
PROMPT Creating index HYDROLOGY_HEADER_POS_INDX
CREATE INDEX HYDROLOGY_HEADER_POS_INDX ON HYDROLOGY_HEADER
( START_LAT ASC, START_LON ASC )
PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K);
PROMPT Creating index HYDROLOGY_HEADER_TIME_INDX
CREATE INDEX HYDROLOGY_HEADER_TIME_INDX ON
HYDROLOGY_HEADER ( START_TIME ASC )
PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K);
PROMPT Creating table MOORED_INSTRUMENT_DATA
CREATE TABLE MOORED_INSTRUMENT_DATA
(
DATA_ID
NUMBER(12)
NOT NULL,
TIME_SECONDS
NUMBER
NOT NULL,
TIME
DATE,
TIME_QC_FLAG
NUMBER(3),
EAST_COMPONENT
NUMBER(5,2),
EAST_COMPONENT_QC_FLAG
NUMBER(3),
NORTH_COMPONENT
NUMBER(5,2),
NORTH_COMPONENT_QC_FLAG NUMBER(3),
PRESSURE
NUMBER(5,2),
PRESSURE_QC_FLAG
NUMBER(3),
TEMPERATURE
NUMBER(5,2),
TEMPERATURE_QC_FLAG
NUMBER(3),
SALINITY
NUMBER(4,2),
SALINITY_QC_FLAG
NUMBER(3),
CONSTRAINT MOORED_INSTRUMENT_PK
PRIMARY KEY ( DATA_ID, TIME_SECONDS )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
PROMPT Creating table MOORED_INSTRUMENT_GEOMETRY
CREATE TABLE MOORED_INSTRUMENT_GEOMETRY
(
DATA_ID
NUMBER(12)
NOT NULL,
MI_PRINX
NUMBER
NOT NULL,
GEOLOC
MDSYS.SDO_GEOMETRY,
SECURITY_CODE
NUMBER(1),
LICENCE_NOTE
VARCHAR(40),
CONSTRAINT MOORED_INSTRUMENT_GEOMETRY_PK
PRIMARY KEY ( DATA_ID )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
PROMPT Creating table MOORED_INSTRUMENT_HEADER
CREATE TABLE MOORED_INSTRUMENT_HEADER
(
DATA_ID
NUMBER(12)
DEPLOYMENT_ID
NUMBER(8)
SURVEY_NAME
VARCHAR(12),
METER_TYPE
VARCHAR2(20)
NOMINAL_METER_DEPTH
NUMBER(5),
START_TIME
DATE
END_TIME
DATE
START_LAT
NUMBER(7,5),
START_LON
NUMBER(8,5),
MAGNETIC_DECLINATION
NUMBER(6,3),
SAMPLE_INTERVAL
NUMBER(6),
FILTER_ID
VARCHAR2(25),
DATA_PROCESSOR
VARCHAR2(40),
COMMENTS
VARCHAR2(225),
PROJECT_ID
NUMBER(7)
GLOBAL_PROJECT_ID
NUMBER(7),
MARLIN_ID
NUMBER(7)
SECURITY_CODE
NUMBER(1),
RELEASE_DATE
DATE,
LICENCE_NOTE
VARCHAR(40),
WATER_DEPTH
NUMBER(5,1),
CONSTRAINT MOORED_INSTRUMENT_HEADER_PK
PRIMARY KEY ( DATA_ID )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
NOT NULL,
NOT NULL,
NOT NULL,
NOT NULL,
NOT NULL,
NOT NULL,
NOT NULL,
PROMPT Creating table NETCDF_HEADER
CREATE TABLE NETCDF_HEADER
(
DATA_ID
FILENAME
SUMMARY
PROJECT_ID
GLOBAL_PROJECT_ID
MARLIN_ID
SECURITY_CODE
RELEASE_DATE
NUMBER(12)
NOT NULL,
VARCHAR2(255),
VARCHAR2(2000),
NUMBER(7)
NOT NULL,
NUMBER(7),
NUMBER(7)
NOT NULL,
NUMBER(1),
DATE,
LICENCE_NOTE
VARCHAR(40),
CONSTRAINT NETCDF_HEADER_PK
PRIMARY KEY ( DATA_ID )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
PROMPT Creating table NETCDF_PARAMETER
CREATE TABLE NETCDF_PARAMETER
(
DATA_ID
NUMBER(12)
FILEVARIABLE
VARCHAR2(50)
PARAMETER_CODE
VARCHAR2(20),
CONSTRAINT NETCDF_PARAMETER_PK
PRIMARY KEY ( DATA_ID,FILEVARIABLE )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
NOT NULL,
NOT NULL,
PROMPT Creating table PARAMETER_SET
CREATE TABLE PARAMETER_SET
(
PARAMETER_CODE
VARCHAR2(20)
PARAMETER_UNITS
VARCHAR2(40),
PARAMETER_LABEL
VARCHAR2(40),
COMMON_NAME
VARCHAR2(40),
DESCRIPTION
VARCHAR2(100),
MINIMUM_VALUE
NUMBER(20,6),
MAXIMUM_VALUE
NUMBER(20,6),
VALUE_TYPE
VARCHAR2(10),
CONSTRAINT PARAMETER_CODES_PK
PRIMARY KEY ( PARAMETER_CODE )
USING INDEX PCTFREE 5
TABLESPACE
INDX
) PCTFREE 5 PCTUSED 85;
NOT NULL,
PROMPT Creating table PARAMETER_SYNONYM_LIST
CREATE TABLE PARAMETER_SYNONYM_LIST
(
PARAMETER_CODE
VARCHAR2(20)
NOT NULL,
PARAMETER_SYNONYM
VARCHAR2(40),
CONSTRAINT PARAMETER_SYNONYM_LIST_PK
PRIMARY KEY ( PARAMETER_CODE, PARAMETER_SYNONYM )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
PROMPT Creating table PHOTO_FRAME_BIOTA_COUNT
CREATE TABLE PHOTO_FRAME_BIOTA_COUNT
(
DATA_ID
NUMBER(12)
FRAME_NUMBER
NUMBER(10)
CAAB_SPECIES_CODE
NUMBER(8)
ORIGINAL_SPECIES_CODE
NUMBER(8),
NOT NULL,
NOT NULL,
NOT NULL,
ITEM_COUNT
NUMBER(7)
NOT NULL,
QC_FLAG
NUMBER(3)
NOT NULL,
CONSTRAINT PHOTO_FRAME_BIOTA_COUNT_PK
PRIMARY KEY ( DATA_ID, FRAME_NUMBER, CAAB_SPECIES_CODE )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
PROMPT Creating table PHOTO_FRAME_BIOTA_PRES_ABS
CREATE TABLE PHOTO_FRAME_BIOTA_PRES_ABS
(
DATA_ID
NUMBER(12)
NOT NULL,
FRAME_NUMBER
NUMBER(10)
NOT NULL,
CAAB_SPECIES_CODE
NUMBER(8)
NOT NULL,
ORIGINAL_SPECIES_CODE
NUMBER(8),
PRESENCE_CODE
VARCHAR2(16)
NOT NULL,
QC_FLAG
NUMBER(3)
NOT NULL,
CONSTRAINT PHOTO_FRAME_BIOTA_PRES_ABS_PK
PRIMARY KEY ( DATA_ID, FRAME_NUMBER, CAAB_SPECIES_CODE )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
PROMPT Creating table PHOTO_FRAME_BIOTA_SCORE
CREATE TABLE PHOTO_FRAME_BIOTA_SCORE
(
DATA_ID
NUMBER(12)
NOT NULL,
FRAME_NUMBER
NUMBER(10)
NOT NULL,
CAAB_SPECIES_CODE
NUMBER(8)
NOT NULL,
ORIGINAL_SPECIES_CODE
NUMBER(8),
SCORE_CODE
VARCHAR2(2)
NOT NULL,
QC_FLAG
NUMBER(3)
NOT NULL,
CONSTRAINT PHOTO_FRAME_BIOTA_SCORE_PK
PRIMARY KEY ( DATA_ID, FRAME_NUMBER, CAAB_SPECIES_CODE )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
PROMPT Creating table PHOTO_FRAME_HEADER
CREATE TABLE PHOTO_FRAME_HEADER
(
DATA_ID
NUMBER(12)
FRAME_NUMBER
NUMBER(10)
LABEL
VARCHAR2(20),
TIME
DATE,
LAT
NUMBER(7,5),
LON
NUMBER(8,5),
DEPTH
NUMBER(6),
LINK_URL
VARCHAR2(20),
LINK_NAME
VARCHAR2(30),
COMMENTS
VARCHAR2(255),
CONSTRAINT PHOTO_FRAME_HEADER_PK
PRIMARY KEY ( DATA_ID, FRAME_NUMBER )
USING INDEX PCTFREE 5
TABLESPACE
INDX
NOT NULL,
NOT NULL,
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
PROMPT Creating table PHOTO_FRAME_TOPO_COUNT
CREATE TABLE PHOTO_FRAME_TOPO_COUNT
(
DATA_ID
NUMBER(12)
NOT NULL,
FRAME_NUMBER
NUMBER(10)
NOT NULL,
PARAMETER_CODE
VARCHAR2(20)
NOT NULL,
ITEM_COUNT
NUMBER(7)
NOT NULL,
QC_FLAG
NUMBER(3)
NOT NULL,
CONSTRAINT PHOTO_FRAME_TOPO_COUNT_PK
PRIMARY KEY ( DATA_ID, FRAME_NUMBER, PARAMETER_CODE )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
PROMPT Creating table PHOTO_FRAME_TOPO_PRES_ABS
CREATE TABLE PHOTO_FRAME_TOPO_PRES_ABS
(
DATA_ID
NUMBER(12)
NOT NULL,
FRAME_NUMBER
NUMBER(10)
NOT NULL,
PARAMETER_CODE
VARCHAR2(20)
NOT NULL,
PRESENCE_CODE
VARCHAR2(16)
NOT NULL,
QC_FLAG
NUMBER(3)
NOT NULL,
CONSTRAINT PHOTO_FRAME_TOPO_PRES_ABS_PK
PRIMARY KEY ( DATA_ID, FRAME_NUMBER, PARAMETER_CODE )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
PROMPT Creating table PHOTO_FRAME_TOPO_SCORE
CREATE TABLE PHOTO_FRAME_TOPO_SCORE
(
DATA_ID
NUMBER(12)
NOT NULL,
FRAME_NUMBER
NUMBER(10)
NOT NULL,
PARAMETER_CODE
VARCHAR2(20)
NOT NULL,
SCORE_CODE
NUMBER(2)
NOT NULL,
QC_FLAG
NUMBER(3)
NOT NULL,
CONSTRAINT PHOTO_FRAME_TOPO_SCORE_PK
PRIMARY KEY ( DATA_ID, FRAME_NUMBER, PARAMETER_CODE )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
PROMPT Creating table PHOTO_SEQUENCE_HEADER
CREATE TABLE PHOTO_SEQUENCE_HEADER
(
DATA_ID
NUMBER(12)
DEPLOYMENT_ID
NUMBER(8)
SURVEY_NAME
VARCHAR(12),
PHOTO_TYPE_CODE
VARCHAR2(6)
NOT NULL,
NOT NULL,
NOT NULL,
LABEL
VARCHAR2(20),
START_TIME
DATE,
END_TIME
DATE,
UTC_OFFSET
NUMBER(3,1),
START_LAT
NUMBER(7,5),
START_LON
NUMBER(8,5),
END_LAT
NUMBER(7,5),
END_LON
NUMBER(8,5),
START_DEPTH
NUMBER(5),
END_DEPTH
NUMBER(5),
COMMENTS
VARCHAR2(255),
PROJECT_ID
NUMBER(7)
GLOBAL_PROJECT_ID
NUMBER(7),
MARLIN_ID
NUMBER(7)
SECURITY_CODE
NUMBER(1),
RELEASE_DATE
DATE,
LICENCE_NOTE
VARCHAR(40),
CONSTRAINT PHOTO_SEQUENCE_HEADER_PK
PRIMARY KEY ( DATA_ID )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
NOT NULL,
NOT NULL,
PROMPT Creating table PROJECT
CREATE TABLE PROJECT
(
PROJECT_ID
NUMBER(7)
NOT NULL,
PROJECT_NAME
VARCHAR2(100) NOT NULL,
PROJECT_DESCRIPTION
VARCHAR(2000),
CONSTRAINT PARAMETER_PROJECT_PK
PRIMARY KEY ( PROJECT_ID )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
PROMPT Creating table QC_FLAGS
CREATE TABLE QC_FLAGS
(
)
QC_FLAG
NUMBER(3),
DATA_STATE
VARCHAR2(8),
OPERATION
VARCHAR2(20),
ERROR_TYPE
VARCHAR2(60),
CONSTRAINT QC_FLAGS_PK
PRIMARY KEY ( QC_FLAG )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 6K NEXT 6K)
PCTFREE 5 PCTUSED 95;
PROMPT Creating table SOURCE
CREATE TABLE SOURCE
(
SOURCE_ID
SOURCE_NAME
NUMBER(7)
VARCHAR2(40),
NOT NULL,
SOURCE_TYPE
VARCHAR2(40),
CONSTRAINT SOURCE_PK
PRIMARY KEY ( SOURCE_ID )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
PROMPT Creating table SURVEY
CREATE TABLE SURVEY
(
SURVEY_NAME
VARCHAR2(12)
SOURCE_ID
NUMBER(7)
SURVEY_TYPE
VARCHAR2(16)
MARLIN_SURVEY_ID
NUMBER(7),
PROJECT_ID
NUMBER(7)
START_TIME
DATE
END_TIME
DATE
START_LAT
NUMBER(7,5),
START_LON
NUMBER(8,5),
END_LAT
NUMBER(7,5),
END_LON
NUMBER(8,5),
START_LOCATION
VARCHAR2(80),
END_LOCATION
VARCHAR2(80),
COMMENTS
VARCHAR2(255),
CONSTRAINT SURVEY_PK
PRIMARY KEY ( SURVEY_NAME )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
NOT NULL,
NOT NULL,
NOT NULL,
NOT NULL,
NOT NULL,
NOT NULL,
PROMPT Creating index SURVEY_POS_INDX
CREATE INDEX SURVEY_POS_INDX ON SURVEY
( START_LAT ASC, START_LON ASC )
PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K);
PROMPT Creating index SURVEY_TIME_INDX
CREATE INDEX SURVEY_TIME_INDX ON SURVEY
( START_TIME ASC )
PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K);
PROMPT Creating table UNDERWAY_DATA
CREATE TABLE UNDERWAY_DATA
(
DATA_ID
TIME
PARAMETER_CODE
NUMBER(12)
DATE
VARCHAR2(20)
NOT NULL,
NOT NULL,
NOT NULL,
VALUE
NUMBER(10,5),
QC_FLAG
NUMBER(3),
CONSTRAINT UNDERWAY_DATA_PK
PRIMARY KEY ( DATA_ID, TIME, PARAMETER_CODE )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 120K NEXT 120K)
) PCTFREE 5 PCTUSED 85 STORAGE (INITIAL 512K NEXT 512 K PCTINCREASE 0);
PROMPT Creating index UW_DATA_TIME_INDX
CREATE INDEX UW_DATA_TIME_INDX ON
UNDERWAY_DATA ( TIME ASC )
PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 24K NEXT 12K);
PROMPT Creating table UNDERWAY_GEOMETRY
CREATE TABLE UNDERWAY_GEOMETRY
(
DATA_ID
NUMBER(12)
NOT NULL,
PARAMETER_CODE
VARCHAR2(20)
NOT NULL,
MI_PRINX
NUMBER
NOT NULL,
GEOLOC
MDSYS.SDO_GEOMETRY,
SECURITY_CODE
NUMBER(1),
LICENCE_NOTE
VARCHAR(40),
CONSTRAINT UNDERWAY_GEOMETRY_PK
PRIMARY KEY ( DATA_ID, PARAMETER_CODE )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
PROMPT Creating table UNDERWAY_GPS
CREATE TABLE UNDERWAY_GPS
(
TIME
DATE
LAT
NUMBER(9,5)
LON
NUMBER(10,5)
DATA_ID
NUMBER(12)
QC_FLAG
NUMBER(3),
CONSTRAINT UNDERWAY_GPS_PK
PRIMARY KEY ( TIME, LAT, LON )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
NOT NULL,
NOT NULL,
NOT NULL,
NOT NULL,
PROMPT Creating table UNDERWAY_HEADER
CREATE TABLE UNDERWAY_HEADER
(
DATA_ID
NUMBER(12)
DEPLOYMENT_ID
NUMBER(8)
SURVEY_NAME
VARCHAR2(12)
START_TIME
DATE
NOT
NOT
NOT
NOT
NULL,
NULL,
NULL,
NULL,
END_TIME
DATE
START_LAT
NUMBER(7,5),
START_LON
NUMBER(8,5),
END_LAT
NUMBER(7,5),
END_LON
NUMBER(8,5),
PROJECT_ID
NUMBER(7)
GLOBAL_PROJECT_ID
NUMBER(7),
MARLIN_ID
NUMBER(7)
SECURITY_CODE
NUMBER(1),
RELEASE_DATE
DATE,
LICENCE_NOTE
VARCHAR(40),
CONSTRAINT UNDERWAY_HEADER_PK
PRIMARY KEY ( DATA_ID )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
NOT NULL,
NOT NULL,
NOT NULL,
PROMPT Creating index UNDERWAY_HEADER_POS_INDX
CREATE INDEX UW_HEADER_POS_INDX ON
UNDERWAY_HEADER ( START_LAT ASC, START_LON ASC )
PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K);
PROMPT Creating index UW_HEADER_TIME_INDX
CREATE INDEX UW_HEADER_TIME_INDX ON
UNDERWAY_HEADER ( START_TIME ASC )
PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K);
2.1 Warehouse Application specific tables
PROMPT Creating table MAP_LAYER
CREATE TABLE MAP_LAYER
(
LAYER_ID
NUMBER(10)
LAYER_NAME
VARCHAR2(50)
DRAW_ORDER
NUMBER(10)
SOURCE_TYPE
VARCHAR2(10)
CONSTRAINT MAP_LAYER_PK
PRIMARY KEY ( LAYER_ID )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
NOT
NOT
NOT
NOT
NULL,
NULL,
NULL,
NULL,
PROMPT Creating table MAP_LAYER_PARAMETER
CREATE TABLE MAP_LAYER_PARAMETER
(
LAYER_ID
NUMBER(10)
PARAMETER_NAME
VARCHAR2(20)
NOT NULL,
NOT NULL,
PARAMETER_VALUE
VARCHAR2(50)
NOT NULL,
CONSTRAINT MAP_LAYER_PARAMETER_PK
PRIMARY KEY ( LAYER_ID, PARAMETER_NAME )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
PROMPT Creating table APP_CATEGORY
CREATE TABLE APP_CATEGORY
(
CATEGORY_ID
NUMBER(10)
CATEGORY_NAME
VARCHAR2(20)
PARENT_CATEGORY_ID
NUMBER(10),
CONSTRAINT APP_CATEGORY_PK
PRIMARY KEY ( CATEGORY_ID )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
NOT NULL,
NOT NULL,
PROMPT Creating table APP_CATEGORY_LOOKUP
CREATE TABLE APP_CATEGORY_LOOKUP
(
DATA_ID
NUMBER(12)
CATEGORY_ID
NUMBER(10)
CONSTRAINT APP_CATEGORY_LOOKUP_PK
PRIMARY KEY ( DATA_ID, CATEGORY_ID )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
NOT NULL,
NOT NULL,
PROMPT Creating table APP_USER
CREATE TABLE APP_USER
(
USER_ID
NUMBER(10)
LOGIN
VARCHAR2(30)
PASSWORD
VARCHAR2(10)
ADMINISTRATOR
VARCHAR2(3),
CONSTRAINT APP_USER_PK
PRIMARY KEY ( USER_ID )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
NOT NULL,
NOT NULL,
NOT NULL,
PROMPT Creating table APP_ACCESS
CREATE TABLE APP_ACCESS
(
USER_ID
NUMBER(10)
NOT NULL,
SECURITY_CODE
NUMBER(1)
NOT NULL,
CONSTRAINT APP_ACCESS_PK
PRIMARY KEY ( USER_ID, SECURITY_CODE )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
PROMPT Creating table APP_CTD_SUMMARY
CREATE TABLE APP_CTD_SUMMARY
(
DATA_ID
NUMBER(12)
PARAMETER_CODE
VARCHAR2(20)
COUNT
NUMBER(8)
CONSTRAINT APP_CTD_SUMMARY_PK
PRIMARY KEY ( DATA_ID, PARAMETER_CODE
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
NOT NULL,
NOT NULL,
NOT NULL,
)
PROMPT Creating table APP_HTML_KEY_LOOKUP
CREATE TABLE APP_HTML_KEY_LOOKUP
(
CATEGORY_ID
NUMBER(10),
HTML_KEY
VARCHAR2(60)
) PCTFREE 5 PCTUSED 85;
PROMPT Creating table APP_SEARCH_DEFINITION
CREATE TABLE APP_SEARCH_DEFINITION
(
HTML_KEY
VARCHAR2(15),
CLASS_NAME
VARCHAR2(60)
) PCTFREE 5 PCTUSED 85;
PROMPT Creating table APP_LOG
CREATE TABLE APP_LOG
(
SESSION_ID
VARCHAR2(50)
EXPIRED
VARCHAR2(1)
SNIPPET
VARCHAR2(1000)
TRANSACTION_DATE
DATE
CONSTRAINT APP_LOG_PK
PRIMARY KEY ( SESSION_ID )
USING INDEX PCTFREE 5
TABLESPACE
INDX
STORAGE (INITIAL 12K NEXT 6K)
) PCTFREE 5 PCTUSED 85;
3. Constraints
PROMPT Creating constraints for schema warehouse
PROMPT Adding constraints to ADCP_SHIP_DEPLOYMENT
ALTER TABLE ADCP_SHIP_DEPLOYMENT
ADD (
CONSTRAINT ADCP_SHIP_DEPLOYMENT_FK
FOREIGN KEY ( DEPLOYMENT_ID )
REFERENCES DEPLOYMENT
);
NOT
NOT
NOT
NOT
NULL,
NULL,
NULL,
NULL,
PROMPT Adding constraints CATCH_ADD_ATTRIBUTE
ALTER TABLE CATCH_ADD_ATTRIBUTE
ADD (
CONSTRAINT CATCH_ADD_CATHEAD_FK
FOREIGN KEY ( DATA_ID )
REFERENCES CATCH_HEADER,
CONSTRAINT CATCH_ADD_PARSET_FK
FOREIGN KEY ( PARAMETER_CODE )
REFERENCES PARAMETER_SET
);
PROMPT Adding constraints CATCH_COMPOSITION_DATA
ALTER TABLE CATCH_COMPOSITION_DATA
ADD (
CONSTRAINT CATCH_COMP_CATHEAD_FK
FOREIGN KEY ( DATA_ID )
REFERENCES CATCH_HEADER,
CONSTRAINT CATCH_COMP_SPLIST_FK
FOREIGN KEY ( CAAB_SPECIES_CODE )
REFERENCES CAAB_SPECIES_LIST ( SPECIES_CODE )
);
PROMPT Adding constraints CATCH_GEOMETRY
ALTER TABLE CATCH_GEOMETRY
ADD (
CONSTRAINT CATCH_GEOM_CATHEAD_FK
FOREIGN KEY ( DATA_ID )
REFERENCES CATCH_HEADER
);
PROMPT Adding constraints CATCH_HEADER
ALTER TABLE CATCH_HEADER
ADD (
CONSTRAINT CATCH_HEADER_DATASUM_FK
FOREIGN KEY ( DATA_ID )
REFERENCES DATA_SUMMARY,
CONSTRAINT CATCH_HEADER_DEPL_FK
FOREIGN KEY ( DEPLOYMENT_ID )
REFERENCES DEPLOYMENT,
CONSTRAINT CATCH_HEADER_PROJ_FK
FOREIGN KEY ( PROJECT_ID )
REFERENCES PROJECT
);
PROMPT Adding constraints CATCH_MEASUREMENT_DATA
ALTER TABLE CATCH_MEASUREMENT_DATA
ADD (
CONSTRAINT CATCH_MEAS_CATHEAD_FK
FOREIGN KEY ( DATA_ID )
REFERENCES CATCH_HEADER,
CONSTRAINT CATCH_MEAS_SPEC_LIST_FK
FOREIGN KEY ( CAAB_SPECIES_CODE )
REFERENCES CAAB_SPECIES_LIST ( SPECIES_CODE )
);
PROMPT Adding constraints CATCH_SPECIMEN_DATA
ALTER TABLE CATCH_SPECIMEN_DATA
ADD (
CONSTRAINT CATCH_SPEC_CATHEAD_FK
FOREIGN KEY ( DATA_ID )
REFERENCES CATCH_HEADER,
CONSTRAINT CATCH_SPEC_SPLIST_FK
FOREIGN KEY ( CAAB_SPECIES_CODE )
REFERENCES CAAB_SPECIES_LIST ( SPECIES_CODE )
);
PROMPT Adding constraints CODE_LIST
ALTER TABLE CODE_LIST
ADD (
CONSTRAINT CODE_LIST_CODENAMELIST_FK
FOREIGN KEY ( CODE_NAME )
REFERENCES CODE_NAME_LIST
);
--PROMPT Adding constraints CODE_NAME_LIST
--PROMPT Adding constraints COMPONENT
PROMPT Adding constraints CTD_DATA
ALTER TABLE CTD_DATA
ADD (
CONSTRAINT CTD_DATA_CTDHEAD_FK
FOREIGN KEY ( DATA_ID )
REFERENCES CTD_HEADER,
CONSTRAINT CTD_DATA_PARSET_FK
FOREIGN KEY ( PARAMETER_CODE )
REFERENCES PARAMETER_SET
);
PROMPT Adding constraints CTD_GEOMETRY
ALTER TABLE CTD_GEOMETRY
ADD (
CONSTRAINT CTD_GEOM_CTDHEAD_FK
FOREIGN KEY ( DATA_ID )
REFERENCES CTD_HEADER
);
PROMPT Adding constraints CTD_HEADER
ALTER TABLE CTD_HEADER
ADD (
CONSTRAINT CTD_HEAD_DATASUM_FK
FOREIGN KEY ( DATA_ID )
REFERENCES DATA_SUMMARY,
CONSTRAINT CTD_HEAD_SURVEY_FK
FOREIGN KEY ( SURVEY_NAME )
REFERENCES SURVEY,
CONSTRAINT CTD_HEAD_DEPL_FK
FOREIGN KEY ( DEPLOYMENT_ID )
REFERENCES DEPLOYMENT,
CONSTRAINT CTD_HEAD_PROJ_FK
FOREIGN KEY ( PROJECT_ID )
REFERENCES PROJECT
);
--PROMPT Adding constraints DATA_SUMMARY
PROMPT Adding constraints DEPLOYMENT
ALTER TABLE DEPLOYMENT
ADD (
CONSTRAINT DEPLOYMENT_SURVEY_FK
FOREIGN KEY ( SURVEY_NAME )
REFERENCES SURVEY,
CONSTRAINT DEPLOYMENT_SOURCE_FK
FOREIGN KEY ( SOURCE_ID )
REFERENCES SOURCE,
CONSTRAINT DEPLOYMENT_PROJECT_FK
FOREIGN KEY ( PROJECT_ID )
REFERENCES PROJECT
);
PROMPT Adding constraints DEPLOYMENT_COMPONENT
ALTER TABLE DEPLOYMENT_COMPONENT
ADD (
CONSTRAINT DEPL_COMP_DEPLOYMENT_FK
FOREIGN KEY ( DEPLOYMENT_ID )
REFERENCES DEPLOYMENT,
CONSTRAINT DEPL_COMP_COMPONENT_FK
FOREIGN KEY ( COMPONENT_ID )
REFERENCES COMPONENT
);
PROMPT Adding constraints DEPLOYMENT_OBSERVATION
ALTER TABLE DEPLOYMENT_OBSERVATION
ADD (
CONSTRAINT DEPL_OBS_DEPL_FK
FOREIGN KEY ( DEPLOYMENT_ID )
REFERENCES DEPLOYMENT,
CONSTRAINT DEPL_OBS_PARSET_FK
FOREIGN KEY ( PARAMETER_CODE )
REFERENCES PARAMETER_SET
);
PROMPT Adding constraints GIS_DATA
ALTER TABLE GIS_DATA
ADD (
CONSTRAINT GIS_DATA_GISHEAD_FK
FOREIGN KEY ( DATA_ID )
REFERENCES GIS_HEADER
);
PROMPT Adding constraints GIS_HEADER
ALTER TABLE GIS_HEADER
ADD (
CONSTRAINT GIS_HEAD_DATASUM_FK
FOREIGN KEY ( DATA_ID )
REFERENCES DATA_SUMMARY,
CONSTRAINT GIS_HEAD_PARSET_FK
FOREIGN KEY ( PARAMETER_CODE )
REFERENCES PARAMETER_SET,
CONSTRAINT GIS_HEAD_PROJ_FK
FOREIGN KEY ( PROJECT_ID )
REFERENCES PROJECT
);
--PROMPT Adding constraints GLOBAL_PROJECT
--PROMPT Adding constraints HYDROCHEM_ANALYTICAL_METHOD
PROMPT Adding constraints HYDROLOGY_ANALYSIS
ALTER TABLE HYDROLOGY_ANALYSIS
ADD (
CONSTRAINT HYDROALYSIS_METHOD_FK
FOREIGN KEY ( METHOD_CODE, APPLICATION_DATE )
REFERENCES HYDROCHEM_ANALYTICAL_METHOD,
CONSTRAINT HYDROANALYSIS_HYDROHEAD_FK
FOREIGN KEY ( DATA_ID )
REFERENCES HYDROLOGY_HEADER
);
PROMPT Adding constraints HYDROLOGY_DATA
ALTER TABLE HYDROLOGY_DATA
ADD (
CONSTRAINT HYD_DATA_HYDHEAD_FK
FOREIGN KEY ( DATA_ID )
REFERENCES HYDROLOGY_HEADER
);
PROMPT Adding constraints HYDROLOGY_HEADER
ALTER TABLE HYDROLOGY_HEADER
ADD (
CONSTRAINT HYD_HEAD_DATASUM_FK
FOREIGN KEY ( DATA_ID )
REFERENCES DATA_SUMMARY,
CONSTRAINT HYD_HEAD_SURVEY_FK
FOREIGN KEY ( SURVEY_NAME )
REFERENCES SURVEY,
CONSTRAINT HYD_HEAD_DEPL_FK
FOREIGN KEY ( DEPLOYMENT_ID )
REFERENCES DEPLOYMENT,
CONSTRAINT HYD_HEAD_PROJ_FK
FOREIGN KEY ( PROJECT_ID )
REFERENCES PROJECT
);
PROMPT Adding constraints MOORED_INSTRUMENT_DATA
ALTER TABLE MOORED_INSTRUMENT_DATA
ADD (
CONSTRAINT MOOR_INST_MOORHEAD_FK
FOREIGN KEY ( DATA_ID )
REFERENCES MOORED_INSTRUMENT_HEADER
);
PROMPT Adding constraints MOORED_INSTRUMENT_GEOMETRY
ALTER TABLE MOORED_INSTRUMENT_GEOMETRY
ADD (
CONSTRAINT MOOR_INST_GEOM_MOORHEAD_FK
FOREIGN KEY ( DATA_ID )
REFERENCES MOORED_INSTRUMENT_HEADER
);
PROMPT Adding constraints MOORED_INSTRUMENT_HEADER
ALTER TABLE MOORED_INSTRUMENT_HEADER
ADD (
CONSTRAINT MOOR_HEAD_DATASUM_FK
FOREIGN KEY ( DATA_ID )
REFERENCES DATA_SUMMARY,
CONSTRAINT MOOR_HEAD_DEPL_FK
FOREIGN KEY ( DEPLOYMENT_ID )
REFERENCES DEPLOYMENT,
CONSTRAINT MOOR_HEAD_PROJ_FK
FOREIGN KEY ( PROJECT_ID )
REFERENCES PROJECT
);
--PROMPT Adding constraints PARAMETER_SET
PROMPT Adding constraints PARAMETER_SYNONYM_LIST
ALTER TABLE PARAMETER_SYNONYM_LIST
ADD (
CONSTRAINT PAR_SYN_LIST_PARSET_FK
FOREIGN KEY ( PARAMETER_CODE )
REFERENCES PARAMETER_SET
);
PROMPT Adding constraints PHOTO_FRAME_BIOTA_COUNT
ALTER TABLE PHOTO_FRAME_BIOTA_COUNT
ADD (
CONSTRAINT PHOTO_FRAME_BCOUNT_PSEQHEAD_FK
FOREIGN KEY ( DATA_ID )
REFERENCES PHOTO_SEQUENCE_HEADER,
CONSTRAINT PHOTO_FRAME_BCOUNT_SPLIST_FK
FOREIGN KEY ( CAAB_SPECIES_CODE )
REFERENCES CAAB_SPECIES_LIST ( SPECIES_CODE )
);
PROMPT Adding constraints PHOTO_FRAME_BIOTA_PRES_ABS
ALTER TABLE PHOTO_FRAME_BIOTA_PRES_ABS
ADD (
CONSTRAINT PHOTO_FRAME_BPA_PSEQHEAD_FK
FOREIGN KEY ( DATA_ID )
REFERENCES PHOTO_SEQUENCE_HEADER,
CONSTRAINT PHOTO_FRAME_BPA_PARSET_FK
FOREIGN KEY ( CAAB_SPECIES_CODE )
REFERENCES CAAB_SPECIES_LIST ( SPECIES_CODE )
);
PROMPT Adding constraints PHOTO_FRAME_BIOTA_SCORE
ALTER TABLE PHOTO_FRAME_BIOTA_SCORE
ADD (
CONSTRAINT PHOTO_FRAME_BSCORE_PSEQHEAD_FK
FOREIGN KEY ( DATA_ID )
REFERENCES PHOTO_SEQUENCE_HEADER,
CONSTRAINT PHOTO_FRAME_BSCORE_SPLIST_FK
FOREIGN KEY ( CAAB_SPECIES_CODE )
REFERENCES CAAB_SPECIES_LIST ( SPECIES_CODE )
);
PROMPT Adding constraints PHOTO_FRAME_HEADER
ALTER TABLE PHOTO_FRAME_HEADER
ADD (
CONSTRAINT PHOTO_FRAME_HEAD_PSEQHEAD_FK
FOREIGN KEY ( DATA_ID )
REFERENCES PHOTO_SEQUENCE_HEADER
);
PROMPT Adding constraints PHOTO_FRAME_TOPO_COUNT
ALTER TABLE PHOTO_FRAME_TOPO_COUNT
ADD (
CONSTRAINT PHOTO_FRAME_TCOUNT_PSEQHEAD_FK
FOREIGN KEY ( DATA_ID )
REFERENCES PHOTO_SEQUENCE_HEADER,
CONSTRAINT PHOTO_FRAME_TCOUNT_PARSET_FK
FOREIGN KEY ( PARAMETER_CODE )
REFERENCES PARAMETER_SET
);
PROMPT Adding constraints PHOTO_FRAME_TOPO_PRES_ABS
ALTER TABLE PHOTO_FRAME_TOPO_PRES_ABS
ADD (
CONSTRAINT PHOTO_FRAME_TPA_PSEQHEAD_FK
FOREIGN KEY ( DATA_ID )
REFERENCES PHOTO_SEQUENCE_HEADER,
CONSTRAINT PHOTO_FRAME_TPA_PARSET_FK
FOREIGN KEY ( PARAMETER_CODE )
REFERENCES PARAMETER_SET
);
PROMPT Adding constraints PHOTO_FRAME_TOPO_SCORE
ALTER TABLE PHOTO_FRAME_TOPO_SCORE
ADD (
CONSTRAINT PHOTO_FRAME_TSCORE_PSEQHEAD_FK
FOREIGN KEY ( DATA_ID )
REFERENCES PHOTO_SEQUENCE_HEADER,
CONSTRAINT PHOTO_FRAME_TSCORE_PARSET_FK
FOREIGN KEY ( PARAMETER_CODE )
REFERENCES PARAMETER_SET
);
PROMPT Adding constraints PHOTO_SEQUENCE_HEADER
ALTER TABLE PHOTO_SEQUENCE_HEADER
ADD (
CONSTRAINT PHOTO_SEQ_HEADER_DATASUM_FK
FOREIGN KEY ( DATA_ID )
REFERENCES DATA_SUMMARY,
CONSTRAINT PHOTO_SEQ_HEAD_GPROJECT_FK
FOREIGN KEY ( GLOBAL_PROJECT_ID )
REFERENCES GLOBAL_PROJECT,
CONSTRAINT PHOTO_SEQ_HEAD_DEPL_FK
FOREIGN KEY ( DEPLOYMENT_ID )
REFERENCES DEPLOYMENT,
CONSTRAINT PHOTO_SEQ_HEAD_PROJ_FK
FOREIGN KEY ( PROJECT_ID )
REFERENCES PROJECT
);
--PROMPT Adding constraints PROJECT
--PROMPT Adding constraints QC_FLAGS
--PROMPT Adding constraints SOURCE
PROMPT Adding constraints SURVEY
ALTER TABLE SURVEY
ADD (
CONSTRAINT SURVEY_PROJECT_FK
FOREIGN KEY ( PROJECT_ID )
REFERENCES PROJECT,
CONSTRAINT SURVEY_SOURCE_FK
FOREIGN KEY ( SOURCE_ID )
REFERENCES SOURCE
);
PROMPT Adding constraints UNDERWAY_DATA
ALTER TABLE UNDERWAY_DATA
ADD (
CONSTRAINT UWY_DATA_UWYHEAD_FK
FOREIGN KEY ( DATA_ID )
REFERENCES UNDERWAY_HEADER
);
PROMPT Adding constraints UNDERWAY_GEOMETRY
ALTER TABLE UNDERWAY_GEOMETRY
ADD (
CONSTRAINT UWY_GEOM_UWYHEAD_FK
FOREIGN KEY ( DATA_ID )
REFERENCES UNDERWAY_HEADER
);
PROMPT Adding constraints UNDERWAY_GPS
ALTER TABLE UNDERWAY_GPS
ADD (
CONSTRAINT UWY_GPS_UWYHEAD_FK
FOREIGN KEY ( DATA_ID )
REFERENCES UNDERWAY_HEADER
);
PROMPT Adding constraints UNDERWAY_HEADER
ALTER TABLE UNDERWAY_HEADER
ADD (
CONSTRAINT UWY_HEADER_DATASUM_FK
FOREIGN KEY ( DATA_ID )
REFERENCES DATA_SUMMARY,
CONSTRAINT UWY_HEADER_SURVEY_FK
FOREIGN KEY ( SURVEY_NAME )
REFERENCES SURVEY,
CONSTRAINT UWY_SEQ_HEAD_PROJ_FK
FOREIGN KEY ( PROJECT_ID )
REFERENCES PROJECT
);
PROMPT Addition of constraints complete
4. Data Dictionary
A fourth script, WHComments, forms the basis of the Data Dictionary. A Data Dictionary is a set of data
element definitions. This documents the content of the repository such as the units of a value and the
parameters which can be assigned values. Elements parameter_set and code_list are important for data
loading - they ensure content is controlled.
PROMPT Commenting table ADCP_SHIP_DATA
comment on table ADCP_SHIP_DATA is 'table of adcp ship data';
comment on column ADCP_SHIP_DATA.DATA_ID is 'unique identifier for adcp ship header record';
comment on column ADCP_SHIP_DATA.CALCULATED_DEPTH is 'calculation of depth to centre of bin';
comment on column ADCP_SHIP_DATA.BIN_NUMBER is 'number of depth cell';
comment on column ADCP_SHIP_DATA.U_CORRECTED_VALUE is 'absolute east velocity component of current
(east+/west-) unless VELOCITY_REFERENCE "unc" or "rel"';
comment on column ADCP_SHIP_DATA.V_CORRECTED_VALUE is 'absolute north velocity component of current
(north+/south-) unless VELOCITY_REFERENCE "unc" or "rel"';
comment on column ADCP_SHIP_DATA.AV_QC is 'sum of 3 minute averaged values of (percent good/error
velocity +0.05)';
comment on column ADCP_SHIP_DATA.BIN_ATTENDANCE_PERCENTAGE is 'percentage of profile period for
which there was good data in this bin';
PROMPT Commenting table ADCP_SHIP_DEPLOYMENT
comment on table ADCP_SHIP_DEPLOYMENT is 'table of adcp ship deployment details';
comment on column ADCP_SHIP_DEPLOYMENT.DEPLOYMENT_ID is 'unique identifier for an adcp ship
deployment record';
comment on column ADCP_SHIP_DEPLOYMENT.DEPTH_CELL_LENGTH is 'vertical size of depth cells';
comment on column ADCP_SHIP_DEPLOYMENT.BLANK_AFTER_TRANSMIT is 'period of no data processing to
prevent processing the ringing of the transmit signal';
comment on column ADCP_SHIP_DEPLOYMENT.NOMINAL_ADCP_DEPTH is 'ADCP depth from configuration file';
comment on column ADCP_SHIP_DEPLOYMENT.NUMBER_DEPTH_CELLS is 'number of depth cells';
comment on column ADCP_SHIP_DEPLOYMENT.PINGS_PER_ENSEMBLE is 'number of pings for each ensemble';
comment on column ADCP_SHIP_DEPLOYMENT.TIME_BETWEEN_PINGS is 'time between pings';
comment on column ADCP_SHIP_DEPLOYMENT.MAGNETIC_DECLINATION is 'magnetic offset from config file';
comment on column ADCP_SHIP_DEPLOYMENT.NOMINAL_SALINITY is 'salinity estimate for speed of sound
calculation from config file';
comment on column ADCP_SHIP_DEPLOYMENT.ENSEMBLE_PERIOD is 'interval of time between ensembles';
comment on column ADCP_SHIP_DEPLOYMENT.PROFILING_MODE is 'profile configuration setting (eg 4)';
comment on column ADCP_SHIP_DEPLOYMENT.METHOD_CODE is 'unique identifier for record describing data
processing or analytical method';
comment on column ADCP_SHIP_DEPLOYMENT.CONFIGURATION_FILE is 'path to file containing moored adcp
instrument configuration data';
comment on column ADCP_SHIP_DEPLOYMENT.LOCATION_COMMENT is 'location comment';
comment on column ADCP_SHIP_DEPLOYMENT.TIME_COMMENT is 'time comment';
PROMPT Commenting table ADCP_SHIP_HEADER
comment on table ADCP_SHIP_HEADER is 'table of ADCP ship header details';
comment on column ADCP_SHIP_HEADER.DATA_ID is 'unique identifier for individual data stream record';
comment on column ADCP_SHIP_HEADER.DEPLOYMENT_ID is 'unique identifier for a deployment record';
comment on column ADCP_SHIP_HEADER.PROJECT_ID is 'unique identifier for a project record';
comment on column ADCP_SHIP_HEADER.MARLIN_ID is 'unique identifier for a marlin record';
comment on column ADCP_SHIP_HEADER.SECURITY_CODE is 'security code assigned to dataset 1-public 2data centre only 3-jems group only 4-CMR staff only';
comment on column ADCP_SHIP_HEADER.LICENCE_NOTE is '"licence agreement applies: check Marlin" where
one exists or else null';
comment on column ADCP_SHIP_HEADER.START_TIME is 'start date and time of adcp data sampling';
comment on column ADCP_SHIP_HEADER.MEAN_LAT is 'latitude at start of averaging period';
comment on column ADCP_SHIP_HEADER.MEAN_LON is 'longitude at start of averaging period';
comment on column ADCP_SHIP_HEADER.VELOCITY_REFERENCE is 'code for velocity correction (eg:B is
bottom track velocity); P is GPS position derived velocity D is GPS direct velocity; UNC - No
navigation velocity (uncorrected); "rel" - reference layer velocity';
comment on column ADCP_SHIP_HEADER.HEADING_TYPE is 'gyro or 3DF GPS heading source';
comment on column ADCP_SHIP_HEADER.AVERAGING_PERIOD is 'duration of averaging period';
comment on column ADCP_SHIP_HEADER.BIN_LENGTH is 'vertical size of depth cell';
comment on column ADCP_SHIP_HEADER.PING_LENGTH is 'vertical size of pulses';
comment on column ADCP_SHIP_HEADER.DELAY is 'delay after transmit';
comment on column ADCP_SHIP_HEADER.PERCENT_COVER is 'percentage of averaging period covered by
acceptable ensembles';
comment on column ADCP_SHIP_HEADER.U_SHIP is 'east velocity component of ship(east+/west)';
comment on column ADCP_SHIP_HEADER.V_SHIP is 'north velocity component of shipt(east+/west)';
comment on column ADCP_SHIP_HEADER.PERCENT_BT_COVER is 'percentage of averaging period for which
there was bottom track data';
comment on column ADCP_SHIP_HEADER.BT_DEPTH is 'mean bottom depth of ensembles for which bottom
depth was available';
comment on column ADCP_SHIP_HEADER.MEAN_BT_ERROR_VELOCITY is 'mean of bottom track error velocity';
comment on column ADCP_SHIP_HEADER.MEAN_PERCENT_GOOD_BT_PINGS is 'mean of ensemble percent good
bottom track pings';
PROMPT Commenting table CAAB_SPECIES_LIST
comment on table CAAB_SPECIES_LIST is 'table of caab species information';
comment on column CAAB_SPECIES_LIST.SPECIES_CODE is 'numeric version of current CAAB code for the
species e.g. 37004001 for CAAB species 37 004001';
comment on column CAAB_SPECIES_LIST.SCIENTIFIC_NAME is 'latest scientific name for the species
(periodically refreshed from CAAB database)';
comment on column CAAB_SPECIES_LIST.COMMON_NAME is 'latest common name for the species (periodically
refreshed from CAAB database)';
PROMPT Commenting table CATCH_ADD_ATTRIBUTE
comment on table CATCH_ADD_ATTRIBUTE is 'table of additional catch data';
comment on column CATCH_ADD_ATTRIBUTE.DATA_ID is 'ID of the record in table CATCH_HEADER to which
this attribute belongs';
comment on column CATCH_ADD_ATTRIBUTE.PARAMETER_CODE is 'standardised code (=name) of the parameter
represented from table PARAMETER_SET';
comment on column CATCH_ADD_ATTRIBUTE.VALUE is 'value recorded or setting used';
PROMPT Commenting table CATCH_COMPOSITION_DATA
comment on table CATCH_COMPOSITION_DATA is 'table of catch composition data';
comment on column CATCH_COMPOSITION_DATA.DATA_ID is 'ID of the record in table CATCH_HEADER to which
this data set belongs';
comment on column CATCH_COMPOSITION_DATA.QUANTITY_MEASURED_CODE is 'e.g. indicates total or
subsample used for the measurement(s)';
comment on column CATCH_COMPOSITION_DATA.CAAB_SPECIES_CODE is 'numeric version of current CAAB code
for the species e.g. 37004001 for CAAB species 37 004001';
comment on column CATCH_COMPOSITION_DATA.SPECIES_ID_QC_FLAG is 'quality flag associated with
species identification';
comment on column CATCH_COMPOSITION_DATA.CATCH_COUNT is 'count of individuals of this species in
sample';
comment on column CATCH_COMPOSITION_DATA.CATCH_COUNT_QC_FLAG is 'quality flag associated with catch
count';
comment on column CATCH_COMPOSITION_DATA.CATCH_WEIGHT is 'weight of this species in sample (kg)';
comment on column CATCH_COMPOSITION_DATA.CATCH_WEIGHT_QC_FLAG is 'quality flag associated with catch
weight';
comment on column CATCH_COMPOSITION_DATA.SPECIMEN_DATA_FLAG is 'indicates that biological sample or
measurement exists for specimen/s from this species and catch referenced in table
CATCH_SPECIMEN_DATA';
comment on column CATCH_COMPOSITION_DATA.ORIGINAL_SPECIES_CODE is 'species codes which appeared in
the original data';
comment on column CATCH_COMPOSITION_DATA.COMMENTS is 'field for comments';
PROMPT Commenting table CATCH_GEOMETRY
comment on table CATCH_GEOMETRY is 'geometry information for CATCH_HEADER table';
comment on column CATCH_GEOMETRY.DATA_ID is 'unique identifier for catch header records';
comment on column CATCH_GEOMETRY.MI_PRINX is 'mapinfo unique index for table';
comment on column CATCH_GEOMETRY.GEOLOC is 'oracle spatial object';
comment on column CATCH_GEOMETRY.SECURITY_CODE is 'security code assigned to dataset, 1-public, 2data centre only, 3-jems group only, 4-CMR staff only';
comment on column CATCH_GEOMETRY.LICENCE_NOTE is '"licence agreement applies: check Marlin" where
one exists or else null';
comment on column CATCH_GEOMETRY.SURVEY_NAME is 'name given to vessel based survey expedition';
comment on column CATCH_GEOMETRY.OPERATION_NO is 'fisheries operation number';
PROMPT Commenting table CATCH_HEADER
comment on table CATCH_HEADER is 'table of header catch information';
comment on column CATCH_HEADER.DATA_ID is 'unique identifier for catch header records';
comment on column CATCH_HEADER.SURVEY_NAME is 'name given to vessel based survey expedition';
comment on column CATCH_HEADER.SECURITY_CODE is 'security code assigned to dataset 1-public 2-data
centre only 3-jems group only 4-CMR staff only';
comment on column CATCH_HEADER.RELEASE_DATE is 'allows an expiry date to be applied to embargoed
data';
comment on column CATCH_HEADER.LICENCE_NOTE is '"licence agreement applies: check Marlin" where one
exists or else null';
comment on column CATCH_HEADER.PROJECT_ID is 'ID of the project of which this catch is part';
comment on column CATCH_HEADER.MARLIN_ID is 'ID of the MarLIN record which describes this ctd: link
to table MARLIN: DATA_SETS';
comment on column CATCH_HEADER.GLOBAL_PROJECT_ID is 'ID of the global project of which this catch is
part (if applicable): link to table GLOBAL_PROJECT';
comment on column CATCH_HEADER.DEPLOYMENT_ID is 'ID of the deployment of which this catch is part:
link to table DEPLOYMENT';
comment on column CATCH_HEADER.COMPONENT_ID is 'unique ID of this gear component';
comment on column CATCH_HEADER.START_TIME is 'start date/time of catch (UTC)';
comment on column CATCH_HEADER.END_TIME is 'end date/time of catch (UTC)';
comment on column CATCH_HEADER.UTC_OFFSET is 'offset in hours to UTC required to give local time';
comment on column CATCH_HEADER.START_LAT is 'catch start latitude (decimal degrees)';
comment on column CATCH_HEADER.START_LON is 'catch start longitude (decimal degrees)';
comment on column CATCH_HEADER.END_LAT is 'catch end latitude (decimal degrees)';
comment on column CATCH_HEADER.END_LON is 'catch end longitude (decimal degrees)';
comment on column CATCH_HEADER.START_DEPTH is 'catch start depth in m if available';
comment on column CATCH_HEADER.END_DEPTH is 'catch end depth in m if available';
comment on column CATCH_HEADER.MIN_DEPTH is 'catch minimum depth in m if available';
comment on column CATCH_HEADER.MAX_DEPTH is 'catch maximum depth in m if available';
comment on column CATCH_HEADER.TOTAL_CATCH_WT is 'weight of total catch (kg)';
comment on column CATCH_HEADER.FRACTION_SAMPLED is 'fraction of catch sampled (fraction of 1.000)';
comment on column CATCH_HEADER.SAMPLED_CATCH_WT is 'weight of sampled catch fraction (kg)';
comment on column CATCH_HEADER.SUBSAMPLED_CATCH_WT is 'weight of subsampled catch fraction (kg)';
comment on column CATCH_HEADER.DISCARDED_CATCH_WT is 'weight of discarded catch fraction (kg)';
comment on column CATCH_HEADER.ADD_ATTRIBUTE_FLAG is 'flag indicating further attributes for this
data set are available for this catch referenced in table CATCH_ADD_ATTRIBUTE';
comment on column CATCH_HEADER.COMPONENT_NO is 'sequence number assigned to gear component';
comment on column CATCH_HEADER.CATCH_METHOD is 'method by which catch was obtained';
comment on column CATCH_HEADER.COMMENTS is 'description of fishing effort - content of field depends
on catch method';
PROMPT Commenting table CATCH_MEASUREMENT_DATA
comment on table CATCH_MEASUREMENT_DATA is 'table of catch measurement information';
comment on column CATCH_MEASUREMENT_DATA.DATA_ID is 'unique ID of the record in table CATCH_HEADER
to which this data set belongs';
comment on column CATCH_MEASUREMENT_DATA.CAAB_SPECIES_CODE is 'numeric version of current CAAB code
for the species e.g. 37004001 for CAAB species 37 004001';
comment on column CATCH_MEASUREMENT_DATA.MEDIAN_LENGTH is 'mid-point of the length class for which
the count applies (cm)';
comment on column CATCH_MEASUREMENT_DATA.INTERVAL_WIDTH is 'total width of the length class for
which the count applies (cm)';
comment on column CATCH_MEASUREMENT_DATA.SPECIMEN_COUNT is 'number of individuals of this species in
specified length class of specified sex';
comment on column CATCH_MEASUREMENT_DATA.COUNT_QC_FLAG is 'quality flag associated with this data
item';
comment on column CATCH_MEASUREMENT_DATA.SEX_CODE is 'indicates sex of individuals counted';
comment on column CATCH_MEASUREMENT_DATA.LENGTH_METHOD_CODE is 'indicates measurement method e.g.
fork length total length etc';
comment on column CATCH_MEASUREMENT_DATA.ORIGINAL_SPECIES_CODE is 'species codes which appeared in
the original data';
comment on column CATCH_MEASUREMENT_DATA.COMMENTS is 'field for comments';
PROMPT Commenting table CATCH_SPECIMEN_DATA
comment on table CATCH_SPECIMEN_DATA is 'table of catch specimen data';
comment on column CATCH_SPECIMEN_DATA.DATA_ID is 'ID of the record in table CATCH_HEADER to which
this data set belongs';
comment on column CATCH_SPECIMEN_DATA.QUANTITY_MEASURED_CODE is 'e.g. indicates total or subsample
used for the measurement(s)';
comment on column CATCH_SPECIMEN_DATA.CAAB_SPECIES_CODE is 'numeric version of current CAAB code for
the species e.g. 37004001 for CAAB species 37 004001';
comment on column CATCH_SPECIMEN_DATA.SPECIMEN_NUMBER is 'sequential number of individual being
measured';
comment on column CATCH_SPECIMEN_DATA.SEX_CODE is 'indicates sex of individuals counted';
comment on column CATCH_SPECIMEN_DATA.LENGTH is 'length of the specimen (cm)';
comment on column CATCH_SPECIMEN_DATA.LENGTH_METHOD_CODE is 'indicates measurement method e.g. fork
length total length etc';
comment on column CATCH_SPECIMEN_DATA.LENGTH_QC_FLAG is 'quality flag associated with catch
lengths';
comment on column CATCH_SPECIMEN_DATA.WEIGHT is 'weight of the specimen (g)';
comment on column CATCH_SPECIMEN_DATA.WEIGHT_METHOD_CODE is 'indicates measurement method e.g.
whole fish part only etc';
comment on column CATCH_SPECIMEN_DATA.WEIGHT_QC_FLAG is 'quality flag associated with catch
weights';
comment on column CATCH_SPECIMEN_DATA.MATURATION_STAGE_CODE is 'indicates maturation stage of the
specimen';
comment on column CATCH_SPECIMEN_DATA.MAT_STAGE_QC_FLAG is 'quality flag associated with maturation
stage of the specimen';
comment on column CATCH_SPECIMEN_DATA.GONAD_WEIGHT is 'weight of the gonads of specimen (g)';
comment on column CATCH_SPECIMEN_DATA.GONAD_WT_QC_FLAG is 'quality flag associated with gonad
weights';
comment on column CATCH_SPECIMEN_DATA.STOMACH_FULLNESS_CODE is 'indicates stomach fullness of the
specimen';
comment on column CATCH_SPECIMEN_DATA.STOMACH_FULL_QC_FLAG is 'quality flag associated with stomach
fullness';
comment on column CATCH_SPECIMEN_DATA.ORIGINAL_SPECIES_CODE is 'species codes which appeared in the
original data';
comment on column CATCH_SPECIMEN_DATA.COMMENTS is 'field for comments';
PROMPT Commenting table CODE_LIST
comment on table CODE_LIST is 'table of codes';
comment on column CODE_LIST.CODE_NAME is 'name given to code category';
comment on column CODE_LIST.CODE_VALUE is 'a value that is acceptable in a given code category';
comment on column CODE_LIST.CODE_VALUE_DESCRIPTION is 'Textual narrative describing the code value';
PROMPT Commenting table CODE_NAME_LIST
comment on table CODE_NAME_LIST is 'table of code name descriptions';
comment on column CODE_NAME_LIST.CODE_NAME is 'name given to code category';
comment on column CODE_NAME_LIST.CODE_NAME_DESCRIPTION is 'textual narrative describing the code
name';
PROMPT Commenting table COMPONENT
comment on table COMPONENT is 'table of component information';
comment on column COMPONENT.COMPONENT_ID is 'unique identifier for an equipment or instrument
record';
comment on column COMPONENT.SUB_COMPONENT_OF is 'reference back to component_id';
comment on column COMPONENT.COMMISSION_DATE is 'date on which equipment/instrument was brought into
service';
comment on column COMPONENT.DECOMMISSION_DATE is 'date on which equipment/instrument was taken out
of service';
comment on column COMPONENT.MANUFACTURER is 'manufacturer details (e.g. Aanderaa for moored
instruments)';
comment on column COMPONENT.MODEL_NO is 'model number';
comment on column COMPONENT.SERIAL_NO is 'equipment/instrument serial number e.g. meter number for
moored instruments';
comment on column COMPONENT.PARAMETER_CODE is 'parameter measured by instrument';
comment on column COMPONENT.NAME is 'common name of equipment or instrument. (Meter Type in case of
moorings e.g. current meter)';
comment on column COMPONENT.CSIRO_TRAWL_GEAR_CODE is 'csiro code used to describe trawl gear';
comment on column COMPONENT.DESCRIPTION is 'general description of equipment or instrument';
PROMPT Commenting table CTD_DATA
comment on table CTD_DATA is 'table of CTD data';
comment on column CTD_DATA.DATA_ID is 'unique ID of the record in table CTD_HEADER to which this
data set belongs';
comment on column CTD_DATA.PRESSURE is 'pressure value';
comment on column CTD_DATA.PARAMETER_CODE is 'parameter measured';
comment on column CTD_DATA.VALUE is 'measured value';
comment on column CTD_DATA.QC_FLAG is 'quality flag for this value';
PROMPT Commenting table CTD_GEOMETRY
comment on table CTD_GEOMETRY is 'geometry information for CTD_HEADER table';
comment on column CTD_GEOMETRY.DATA_ID is 'unique ID of the record in table CTD_HEADER to which
this data set belongs';
comment on column CTD_GEOMETRY.MI_PRINX is 'mapinfo unique index for table';
comment on column CTD_GEOMETRY.GEOLOC is 'oracle spatial object';
comment on column CTD_GEOMETRY.SECURITY_CODE is 'security code assigned to dataset 1-public 2-data
centre only 3-jems group only 4-CMR staff only';
comment on column CTD_GEOMETRY.LICENCE_NOTE is 'licence agreement applies: check Marlin" where one
exists or else null';
comment on column CTD_GEOMETRY.SURVEY_NAME is 'name given to vessel based survey expedition';
comment on column CTD_GEOMETRY.STATION_NO is 'oceanographic station number';
PROMPT Commenting table CTD_HEADER
comment on table CTD_HEADER is 'table of CTD header information';
comment on column CTD_HEADER.DATA_ID is 'unique identifier for CTD header record';
comment on column CTD_HEADER.DEPLOYMENT_ID is 'unique identifier for a deployment record';
comment on column CTD_HEADER.SECURITY_CODE is 'security code assigned to dataset 1-public 2-data
centre only 3-jems group only 4-CMR staff only';
comment on column CTD_HEADER.RELEASE_DATE is 'allows an expiry date to be applied to embargoed
data';
comment on column CTD_HEADER.LICENCE_NOTE is '"licence agreement applies: check Marlin" where one
exists or else null';
comment on column CTD_HEADER.PROJECT_ID is 'ID of the project of which this catch is part: link to
table PROJECTS';
comment on column CTD_HEADER.MARLIN_ID is 'ID of the MarLIN record which describes this catch: link
to table MARLIN: DATA_SETS';
comment on column CTD_HEADER.GLOBAL_PROJECT_ID is 'ID of the global project of which this catch is
part (if applicable): link to table GLOBAL_PROJECT';
comment on column CTD_HEADER.CAST_NO is 'sequential station number';
comment on column CTD_HEADER.START_TIME is 'start time of dip';
comment on column CTD_HEADER.END_TIME is 'end time of dip';
comment on column CTD_HEADER.MIN_DEPTH is 'minimum depth';
comment on column CTD_HEADER.MAX_DEPTH is 'maximum depth';
comment on column CTD_HEADER.BOTTOM_DEPTH is 'water depth at start of dip';
comment on column CTD_HEADER.SURVEY_NAME is 'name given to vessel based survey expedition';
comment on column CTD_HEADER.BOTTOM_TIME is 'time of maximum depth of dip';
comment on column CTD_HEADER.BOTTOM_LAT is 'latitude at time of maximum ctd depth';
comment on column CTD_HEADER.BOTTOM_LON is 'longitude at time of maximum ctd depth';
comment on column CTD_HEADER.START_LAT is 'latitude at start of dip';
comment on column CTD_HEADER.START_LON is 'longitude at start of dip';
comment on column CTD_HEADER.END_LAT is 'latitude at end of dip';
comment on column CTD_HEADER.END_LON is 'longitude at end of dip';
comment on column CTD_HEADER.POSITION_QC_FLAG is 'quality flag for positions';
comment on column CTD_HEADER.TIME_QC_FLAG is 'quality flag for times';
comment on column CTD_HEADER.COMMENTS is 'comments for CTD header record';
PROMPT Commenting table DATA_SUMMARY
comment on table DATA_SUMMARY is 'table holding the data summary information for the database';
comment on column DATA_SUMMARY.DATA_ID is 'unique identifier for individual data stream record';
comment on column DATA_SUMMARY.DATA_STREAM_TYPE is 'type code identifying major category of data';
comment on column DATA_SUMMARY.SURVEY_NAME is 'name given to vessel based survey expedition';
comment on column DATA_SUMMARY.DEPLOYMENT_ID is 'unique identifier for a deployment record';
comment on column DATA_SUMMARY.PROJECT_ID is 'unique identifier for a project record';
comment on column DATA_SUMMARY.START_TIME is 'time data sampling commenced';
comment on column DATA_SUMMARY.END_TIME is 'time data sampling finished';
comment on column DATA_SUMMARY.MIN_DEPTH is 'minimum depth recorded';
comment on column DATA_SUMMARY.MAX_DEPTH is 'maximum depth recorded';
comment on column DATA_SUMMARY.MIN_LAT is 'minimum latitude recorded';
comment on column DATA_SUMMARY.MAX_LAT is 'maximum latitude recorded';
comment on column DATA_SUMMARY.MIN_LON is 'minimum longitude recorded';
comment on column DATA_SUMMARY.MAX_LON is 'maximum longitude recorded';
comment on column DATA_SUMMARY.DESCRIPTION is 'narrative available to more expansively define type
of data';
comment on table DEPLOYMENT is 'table holding deployment information';
comment on column DEPLOYMENT.DEPLOYMENT_ID is 'unique identifier for a deployment record';
comment on column DEPLOYMENT.DEPLOYMENT_TYPE is 'type of this deployment (trawl sled etc)';
comment on column DEPLOYMENT.SOURCE_ID is 'unique identifier for a source record';
comment on column DEPLOYMENT.PROJECT_ID is 'project with which data for this instrument deployment
is associated';
comment on column DEPLOYMENT.SURVEY_NAME is 'name given to vessel based survey expedition';
comment on column DEPLOYMENT.START_TIME is 'time instrument in water';
comment on column DEPLOYMENT.END_TIME is 'time instrument out of water';
comment on column DEPLOYMENT.OPERATION_NO is 'fisheries operation number';
comment on column DEPLOYMENT.MAX_DEPTH is 'maximum depth of deployment';
comment on column DEPLOYMENT.STATION_NO is 'oceanographic station number';
comment on column DEPLOYMENT.START_LAT is 'latitude at start of deployment';
comment on column DEPLOYMENT.START_LON is 'longitude at start of deployment';
comment on column DEPLOYMENT.END_LAT is 'latitude at end of deployment';
comment on column DEPLOYMENT.END_LON is 'longitude at end of deployment';
comment on column DEPLOYMENT.LOCATION_SELECTION is 'code of deployment location selection method';
comment on column DEPLOYMENT.DESCRIPTION is 'description (name) given to the deployment/operation';
comment on column DEPLOYMENT.COMMENTS is 'reserved for any special comments regarding deployment';
PROMPT Commenting
comment on table
tables';
comment on column
comment on column
table DEPLOYMENT_COMPONENT
DEPLOYMENT_COMPONENT is 'associative table between DEPLOYMENT and COMPONENT
DEPLOYMENT_COMPONENT.DEPLOYMENT_ID is 'unique identifier for a deployment record';
DEPLOYMENT_COMPONENT.COMPONENT_NO is 'sequence number assigned to gear component';
comment on column DEPLOYMENT_COMPONENT.COMPONENT_ID is 'unique identifier for a component record';
PROMPT Commenting table DEPLOYMENT_OBSERVATION
comment on table DEPLOYMENT_OBSERVATION is 'table of observational data taken at time of
deployment';
comment on column DEPLOYMENT_OBSERVATION.DEPLOYMENT_ID is 'ID of the deployment to which this
observation belongs';
comment on column DEPLOYMENT_OBSERVATION.PARAMETER_CODE is 'standardised code (=name) of the
parameter represented from table PARAMETER_SET';
comment on column DEPLOYMENT_OBSERVATION.VALUE is 'value recorded or setting used';
comment on column DEPLOYMENT_OBSERVATION.QC_FLAG is 'quality flag associated with this data item';
PROMPT Commenting
comment on table
comment on column
comment on column
extension';
comment on column
table GIS_DATA
GIS_DATA is 'table holding information about individual gis source files';
GIS_DATA.DATA_ID is 'unique identifier for gis header record';
GIS_DATA.SOURCE_FILE_NAME is 'file name of individual source file including file
GIS_DATA.SOURCE_FILE_DESCRIPTION is 'textual narrative regarding source file';
PROMPT Commenting table GIS_HEADER
comment on table GIS_HEADER is 'table holding GIS header information about individual layers';
comment on column GIS_HEADER.DATA_ID is 'unique identifier gis layer also used as GIS key in
warehouse application';
comment on column GIS_HEADER.SECURITY_CODE is 'security code assigned to dataset 1-public 2-data
centre only 3-jems group only 4-CMR staff only';
comment on column GIS_HEADER.RELEASE_DATE is 'allows an expiry date to be applied to embargoed
data';
comment on column GIS_HEADER.LICENCE_NOTE is '"licence agreement applies: check Marlin" where one
exists or else null';
comment on column GIS_HEADER.MARLIN_ID is 'ID of the MarLIN record which describes this gis
coverage: link to table MARLIN: DATA_SETS';
comment on column GIS_HEADER.GLOBAL_PROJECT_ID is 'ID of the global project of which this catch is
part (if applicable): link to table GLOBAL_PROJECT';
comment on column GIS_HEADER.PROJECT_ID is 'unique identifier for a project record';
comment on column GIS_HEADER.GIS_TYPE is 'proprietary brand of GIS software used in data
capture/analysis either "ArcView" or "MapInfo"';
comment on column GIS_HEADER.PARAMETER_CODE is 'type of parameter measured';
comment on column GIS_HEADER.LAYER_LABEL is 'Marlin short title (without text JEMS at front)';
comment on column GIS_HEADER.LAYER_DESCRIPTION is 'textual narrative regarding layer usually
derived from marlin title';
comment on column GIS_HEADER.DOWNLOAD_FILE is 'path to zip file in which source files are
archived';
comment on column GIS_HEADER.LAYER_LABEL is 'short description of layer from marlin short title
with JEMS| removed from beginning of marlin field';
PROMPT Commenting table GLOBAL_PROJECT
comment on table GLOBAL_PROJECT is 'table of global project information refreshed from marlin
database';
comment on column GLOBAL_PROJECT. GLOBAL_PROJECT_ID is 'unique identifier given to a global project
record (from marlin)';
comment on column GLOBAL_PROJECT. GLOBAL_PROJECT_NAME is 'name assigned to global project (from
marlin)';
comment on column GLOBAL_PROJECT.DESCRIPTION is 'short description of global project (from marlin)';
PROMPT Commenting table HYDROCHEM_ANALYTICAL_METHOD
comment on table HYDROCHEM_ANALYTICAL_METHOD is 'table of hydrochemistry analytical methods';
comment on column HYDROCHEM_ANALYTICAL_METHOD.METHOD_CODE is 'unique identifier for record
describing data processing or analytical method';
comment on column HYDROCHEM_ANALYTICAL_METHOD.APPLICATION_DATE is 'date on which processing or
analysis was applied';
comment on column HYDROCHEM_ANALYTICAL_METHOD.DESCRIPTION is 'description of method';
comment on column HYDROCHEM_ANALYTICAL_METHOD.REFERENCE is 'reference to digital or hardcopy method
literature';
PROMPT Commenting table HYDROLOGY_ANALYSIS
comment on table HYDROLOGY_ANALYSIS is 'table of information about the analysis of specific
analytes';
comment on column HYDROLOGY_ANALYSIS.DATA_ID is 'unique identifier for individual data stream
record';
comment on column HYDROLOGY_ANALYSIS.ANALYTE_CODE is 'unique identifier for type of analyte
subjected to analysis';
comment on column HYDROLOGY_ANALYSIS.METHOD_CODE is 'unique identifier for record describing data
processing or analytical method';
comment on column HYDROLOGY_ANALYSIS.APPLICATION_DATE is 'date that analysis was carried out';
PROMPT Commenting table HYDROLOGY_DATA
comment on table HYDROLOGY_DATA is 'table of hydrology data';
comment on column HYDROLOGY_DATA.DATA_ID is 'ID of the record in table HYDROLOGY_HEADER to which
this data set belongs';
comment on column HYDROLOGY_DATA.PRESSURE is 'for ctd casts depths are in decibars for wire casts
depths are in meters';
comment on column HYDROLOGY_DATA.BOTTLE_NUMBER is 'number given to bottle on rosette';
comment on column HYDROLOGY_DATA.PARAMETER_CODE is 'type of parameter measured';
comment on column HYDROLOGY_DATA.VALUE is 'measured value';
comment on column HYDROLOGY_DATA.QC_FLAG is 'data quality flag';
PROMPT Commenting table HYDROLOGY_GEOMETRY
comment on table HYDROLOGY_GEOMETRY is 'geometry information for HYDROLOGY_HEADER table';
comment on column HYDROLOGY_GEOMETRY.DATA_ID is 'unique ID of the record in table
HYDROLOGY__HEADER to which this data set belongs';
comment on column HYDROLOGY_GEOMETRY.MI_PRINX is 'mapinfo unique index for table';
comment on column HYDROLOGY_GEOMETRY.GEOLOC is 'oracle spatial object';
comment on column HYDROLOGY_GEOMETRY.SECURITY_CODE is 'security code assigned to dataset 1-public
2-data centre only 3-jems group only 4-CMR staff only';
comment on column HYDROLOGY_GEOMETRY.LICENCE_NOTE is '"licence agreement applies: check Marlin"
where one exists or else null';
PROMPT Commenting table HYDROLOGY_HEADER
comment on table HYDROLOGY_HEADER is 'table of hydrology header information';
comment on column HYDROLOGY_HEADER.DATA_ID is 'unique identifier for hydrology header records';
comment on column HYDROLOGY_HEADER.DEPLOYMENT_ID is 'unique identifier for a deployment record';
comment on column HYDROLOGY_HEADER.SURVEY_NAME is 'name given to vessel based survey expedition';
comment on column HYDROLOGY_HEADER.SECURITY_CODE is 'security code assigned to dataset 1-public 2data centre only 3-jems group only 4-CMR staff only';
comment on column HYDROLOGY_HEADER.RELEASE_DATE is 'allows an expiry date to be applied to embargoed
data';
comment on column HYDROLOGY_HEADER.LICENCE_NOTE is '"licence agreement applies: check Marlin" where
one exists or else null';
comment on column HYDROLOGY_HEADER.PROJECT_ID is 'ID of the project of which this catch is part:
link to table PROJECTS';
comment on column HYDROLOGY_HEADER.MARLIN_ID is 'ID of the MarLIN record which describes this
hydrology record: link to table MARLIN: DATA_SETS';
comment on column HYDROLOGY_HEADER.GLOBAL_PROJECT_ID is 'ID of the global project of which this
catch is part (if applicable): link to table GLOBAL_PROJECT';
comment on column HYDROLOGY_HEADER.CAST_NO is 'sequential station number (for coastal stations cast
number comprises four digit year and three digit sequence number)';
comment on column HYDROLOGY_HEADER.START_TIME is 'start time of dip';
comment on column HYDROLOGY_HEADER.END_TIME is 'end time of dip';
comment on column HYDROLOGY_HEADER.MIN_DEPTH is 'minimum depth';
comment on column HYDROLOGY_HEADER.MAX_DEPTH is 'maximum depth';
comment on column HYDROLOGY_HEADER.BOTTOM_DEPTH is 'water depth at start of dip';
comment on column HYDROLOGY_HEADER.BOTTOM_TIME is 'time of maximum depth of dip';
comment on column HYDROLOGY_HEADER.BOTTOM_LAT is 'latitude at time of maximum ctd depth';
comment on column HYDROLOGY_HEADER.BOTTOM_LON is 'longitude at time of maximum ctd depth';
comment on column HYDROLOGY_HEADER.START_LAT is 'latitude at start of dip';
comment on column HYDROLOGY_HEADER.START_LON is 'longitude at end of dip';
comment on column HYDROLOGY_HEADER.END_LAT is 'latitude at end of dip';
comment on column HYDROLOGY_HEADER.END_LON is 'longitude at end of dip';
comment on column HYDROLOGY_HEADER.POSITION_QC_FLAG is 'quality flag for positions';
comment on column HYDROLOGY_HEADER.TIME_QC_FLAG is 'quality flag for times';
PROMPT Commenting table MOORED_INSTRUMENT_DATA
comment on table MOORED_INSTRUMENT_DATA is 'table of moored instrument data';
comment on column MOORED_INSTRUMENT_DATA.DATA_ID is 'ID of the record in table MOORED_INSTRUMENT
_HEADER to which this data set belongs';
comment on column MOORED_INSTRUMENT_DATA.TIME is 'nominal time to which this record relates (UTC)';
comment on column MOORED_INSTRUMENT_DATA.TIME_SECONDS is 'time in seconds since 1 January 1983';
comment on column MOORED_INSTRUMENT_DATA.TIME_QC_FLAG is 'quality flag associated with this item
for historical records simply indicates whether data has been filtered';
comment on column MOORED_INSTRUMENT_DATA.EAST_COMPONENT is 'velocity component of the current
parallel to the equator ';
comment on column MOORED_INSTRUMENT_DATA.EAST_COMPONENT_QC_FLAG is 'quality flag associated with
this item for historical records simply indicates whether data has been filtered';
comment on column MOORED_INSTRUMENT_DATA.NORTH_COMPONENT is 'velocity component of the current
perpendicular to the equator';
comment on column MOORED_INSTRUMENT_DATA.NORTH_COMPONENT_QC_FLAG is 'quality flag associated with
this item for historical records simply indicates whether data has been filtered';
comment on column MOORED_INSTRUMENT_DATA.PRESSURE is 'calibrated pressure meter reading';
comment on column MOORED_INSTRUMENT_DATA.PRESSURE_QC_FLAG is 'quality flag associated with this
item for historical records simply indicates whether data has been filtered';
comment on column MOORED_INSTRUMENT_DATA.TEMPERATURE is 'calibrated temperature gauge reading';
comment on column MOORED_INSTRUMENT_DATA.TEMPERATURE_QC_FLAG is 'quality flag associated with this
item for historical records simply indicates whether data has been filtered';
comment on column MOORED_INSTRUMENT_DATA.SALINITY is 'derived quantity based on temperature depth
and conductivity';
comment on column MOORED_INSTRUMENT_DATA.SALINITY_QC_FLAG is 'quality flag associated with this
item for historical records simply indicates whether data has been filtered';
PROMPT Commenting table MOORED_INSTRUMENT_GEOMETRY
comment on table MOORED_INSTRUMENT_GEOMETRY is 'geometry information for MOORED_INSTRUMENT_HEADER
table';
comment on column MOORED_INSTRUMENT_GEOMETRY.DATA_ID is 'unique identifier for moored instrument
header record';
comment on column MOORED_INSTRUMENT_GEOMETRY.MI_PRINX is 'mapinfo unique index for table';
comment on column MOORED_INSTRUMENT_GEOMETRY.GEOLOC is 'oracle spatial object';
comment on column MOORED_INSTRUMENT_GEOMETRY.SECURITY_CODE is 'security code assigned to dataset,
1-public, 2-data centre only, 3-jems group only, 4-CMR staff only';
comment on column MOORED_INSTRUMENT_GEOMETRY.LICENCE_NOTE is '"licence agreement applies: check
Marlin" where one exists or else null';
PROMPT Commenting table MOORED_INSTRUMENT_HEADER
comment on table MOORED_INSTRUMENT_HEADER is 'table of moored instrument header information';
comment on column MOORED_INSTRUMENT_HEADER.DATA_ID is 'unique identifier for moored instrument
header record';
comment on column MOORED_INSTRUMENT_HEADER.DEPLOYMENT_ID is 'unique identifier for a deployment
record';
comment on column MOORED_INSTRUMENT_HEADER.METER_TYPE is 'allows differentiation between different
moored instrument datasets(eg current meter and tide gauge)';
comment on column MOORED_INSTRUMENT_HEADER.MARLIN_ID is 'marlin record identifer';
comment on column MOORED_INSTRUMENT_HEADER.PROJECT_ID is 'unique identifier for a project record';
comment on column MOORED_INSTRUMENT_HEADER.GLOBAL_PROJECT_ID is 'unique identifier for a global
project record';
comment on column MOORED_INSTRUMENT_HEADER.SURVEY_NAME is 'name given to groupings of moored
instrument deployments (eg in some cases the name of the experiment';
comment on column MOORED_INSTRUMENT_HEADER.START_LAT is 'start latitude';
comment on column MOORED_INSTRUMENT_HEADER.START_LON is 'start longitude';
comment on column MOORED_INSTRUMENT_HEADER.NOMINAL_METER_DEPTH is 'how far under water the meter was
supposed to be';
comment on column MOORED_INSTRUMENT_HEADER.START_TIME is 'time the meter entered the water (if
known) otherwise duplicates DEPLOYMENT.START_TIME for consistency';
comment on column MOORED_INSTRUMENT_HEADER.END_TIME is 'time the meter exited the water (if known)
otherwise duplicates DEPLOYMENT.END_TIME for consistency';
comment on column MOORED_INSTRUMENT_HEADER.SAMPLE_INTERVAL is 'frequency of sample points
(minutes)';
comment on column MOORED_INSTRUMENT_HEADER.FILTER_ID is 'name of the filter used to produce this
data from the raw format';
comment on column MOORED_INSTRUMENT_HEADER.DATA_PROCESSOR is 'person who processed the raw data';
comment on column MOORED_INSTRUMENT_HEADER.WATER_DEPTH is 'depth of water';
comment on column MOORED_INSTRUMENT_HEADER.COMMENTS is 'free form description of any special
considerations';
comment on column MOORED_INSTRUMENT_HEADER.SECURITY_CODE is 'security code assigned to dataset 1public 2-data centre only 3-jems group only 4-CMR staff only';
comment on column MOORED_INSTRUMENT_HEADER.RELEASE_DATE is ' allows an expiry date to be applied to
embargoed data';
comment on column MOORED_INSTRUMENT_HEADER.LICENCE_NOTE is '"licence agreement applies: check
Marlin" where one exists or else null';
comment on column MOORED_INSTRUMENT_HEADER.MAGNETIC_DECLINATION is 'allows for navigation
correction against the earths changing magnetic field';
PROMPT Commenting table NETCDF_HEADER
comment on table NETCDF_HEADER is 'table stores header information about netcdf files';
comment on column NETCDF_HEADER.DATA_ID is 'unique identifier for netcdf header record';
comment on column NETCDF_HEADER.FILENAME is 'name of netcdf file in which modelled data is stored';
comment on column NETCDF_HEADER.SUMMARY is 'summary of the modeled data';
comment on column NETCDF_HEADER.PROJECT_ID is 'unique identifier for a project record';
comment on column NETCDF_HEADER.GLOBAL_PROJECT_ID is 'unique identifier for a global project
record';
comment on column NETCDF_HEADER.MARLIN_ID is 'marlin record identifer';
comment on column NETCDF_HEADER.SECURITY_CODE is 'security code assigned to dataset 1-public 2-data
centre only 3-jems group only 4-CMR staff only';
comment on column NETCDF_HEADER.RELEASE_DATE is ' allows an expiry date to be applied to embargoed
data';
comment on column NETCDF_HEADER.LICENCE_NOTE is '"licence agreement applies: check Marlin" where one
exists or else null';
PROMPT Commenting table NETCDF_PARAMETER
comment on table NETCDF_PARAMETER is 'table stores information about the parametes stored in netcdf
files';
comment on column NETCDF_PARAMETER.DATA_ID is 'unique identifier for netcdf header record';
comment on column NETCDF_PARAMETER.FILEVARIABLE is 'variable name in netcdf file';
comment on column NETCDF_PARAMETER.PARAMETER_CODE is 'type of parameter modelled';
PROMPT Commenting table PARAMETER_SET
comment on table PARAMETER_SET is 'table stores information about all valid parameter codes used
throughout database';
comment on column PARAMETER_SET.PARAMETER_CODE is 'name given to a particular parameter';
comment on column PARAMETER_SET.PARAMETER_UNITS is 'units of measure';
comment on column PARAMETER_SET.PARAMETER_LABEL is 'plotting label used for this parameter';
comment on column PARAMETER_SET.COMMON_NAME is 'common name for this parameter';
comment on column PARAMETER_SET.DESCRIPTION is 'textual narrative describing the parameter';
comment on column PARAMETER_SET.MINIMUM_VALUE is 'minimum value of parameter';
comment on column PARAMETER_SET.MAXIMUM_VALUE is 'maximum value of parameter';
comment on column PARAMETER_SET.VALUE_TYPE is 'identifies if value described by parameter_code is
textual or numeric';
PROMPT Commenting table PARAMETER_SYNONYM_LIST
comment on table PARAMETER_SYNONYM_LIST is 'table of synonyms for parameters';
comment on column PARAMETER_SYNONYM_LIST.PARAMETER_CODE is 'name given to a particular parameter';
comment on column PARAMETER_SYNONYM_LIST.PARAMETER_SYNONYM is 'other names given to the parameter
(is really only useful for lookup purposes during data loading)';
PROMPT Commenting table PHOTO_SEQUENCE_HEADER
comment on table PHOTO_SEQUENCE_HEADER is 'table of photo sequence header information';
comment on column PHOTO_SEQUENCE_HEADER.DATA_ID is 'unique ID of this photo sequence';
comment on column PHOTO_SEQUENCE_HEADER.SECURITY_CODE is 'security code assigned to dataset 1-public
2-data centre only 3-jems group only 4-CMR staff only';
comment on column PHOTO_SEQUENCE_HEADER.RELEASE_DATE is ' allows an expiry date to be applied to
embargoed data';
comment on column PHOTO_SEQUENCE_HEADER.LICENCE_NOTE is '"licence agreement applies: check Marlin"
where one exists or else null';
comment on column PHOTO_SEQUENCE_HEADER.PROJECT_ID is 'ID of the project of which this photo
sequence is part: link to table PROJECT';
comment on column PHOTO_SEQUENCE_HEADER.MARLIN_ID is 'ID of the MarLIN record which describes this
photo sequence: link to table MARLIN: DATA_SETS';
comment on column PHOTO_SEQUENCE_HEADER.GLOBAL_PROJECT_ID is 'ID of the global project of which this
photo sequence is part (if applicable): link to table GLOBAL_PROJECT';
comment on column PHOTO_SEQUENCE_HEADER.DEPLOYMENT_ID is 'ID of the deployment of which this photo
sequence is part: link to table DEPLOYMENT';
comment on column PHOTO_SEQUENCE_HEADER.SURVEY_NAME is 'name given to vessel based survey
expedition';
comment on column PHOTO_SEQUENCE_HEADER.PHOTO_TYPE_CODE is 'indicates type of this photo sequence
(still video etc.)';
comment on column PHOTO_SEQUENCE_HEADER.LABEL is 'local identifier for this sequence e.g. film
number or tape number)';
comment on column PHOTO_SEQUENCE_HEADER.START_TIME is 'start date/time of photo sequence (UTC)';
comment on column PHOTO_SEQUENCE_HEADER.END_TIME is 'end date/time of photo sequence (UTC)';
comment on column PHOTO_SEQUENCE_HEADER.UTC_OFFSET is 'offset in hours to UTC required to give local
time';
comment on column PHOTO_SEQUENCE_HEADER.START_LAT is 'photo sequence start latitude (decimal
degrees)';
comment on column PHOTO_SEQUENCE_HEADER.START_LON is 'photo sequence start longitude (decimal
degrees)';
comment on column PHOTO_SEQUENCE_HEADER.END_LAT is 'photo sequence end latitude (decimal degrees)';
comment on column PHOTO_SEQUENCE_HEADER.END_LON is 'photo sequence end longitude (decimal degrees)';
comment on column PHOTO_SEQUENCE_HEADER.START_DEPTH is 'photo sequence start depth in m if
available';
comment on column PHOTO_SEQUENCE_HEADER.END_DEPTH is 'photo sequence end depth in m if available';
comment on column PHOTO_SEQUENCE_HEADER.COMMENTS is 'field for comments';
PROMPT Commenting table PHOTO_FRAME_HEADER
comment on table PHOTO_FRAME_HEADER is 'table of photo frame header information';
comment on column PHOTO_FRAME_HEADER.DATA_ID is 'ID of the photo sequence of which this frame is
part: link to table PHOTO_SEQUENCE_HEADER';
comment on column PHOTO_FRAME_HEADER.FRAME_NUMBER is 'unique number of this frame in relevant photo
sequence';
comment on column PHOTO_FRAME_HEADER.LABEL is 'local identifier for this frame if different to
FRAME_NUMBER (e.g. position on tape)';
comment on column PHOTO_FRAME_HEADER.TIME is 'date/time of this photo frame (UTC)';
comment on column PHOTO_FRAME_HEADER.LAT is 'photo frame latitude (decimal degrees)';
comment on column PHOTO_FRAME_HEADER.LON is 'photo frame longitude (decimal degrees)';
comment on column PHOTO_FRAME_HEADER.DEPTH is 'photo frame depth in m if available';
comment on column PHOTO_FRAME_HEADER.LINK_URL is 'URL (web address) of frame if accessible as a
hyperlinked image';
comment on column PHOTO_FRAME_HEADER.LINK_NAME is 'name to display for this link if the frame is
accessible as hyperlinked image';
comment on column PHOTO_FRAME_HEADER.COMMENTS is 'field for comments';
PROMPT Commenting table PHOTO_FRAME_TOPO_PRES_ABS
comment on table PHOTO_FRAME_TOPO_PRES_ABS is 'table of photo topographic presence/absence data';
comment on column PHOTO_FRAME_TOPO_PRES_ABS.DATA_ID is 'ID of the photo sequence of which this frame
is part: link to table PHOTO_SEQUENCE_HEADER';
comment on column PHOTO_FRAME_TOPO_PRES_ABS.FRAME_NUMBER is 'unique number of this frame in relevant
photo sequence';
comment on column PHOTO_FRAME_TOPO_PRES_ABS.PARAMETER_CODE is 'standardised code (=name) of the
parameter represented from table PARAMETER_SET';
comment on column PHOTO_FRAME_TOPO_PRES_ABS.PRESENCE_CODE is 'presence/absence recorded value from
table CODE_LIST';
comment on column PHOTO_FRAME_TOPO_PRES_ABS.QC_FLAG is 'quality flag associated with this data
item';
PROMPT Commenting table PHOTO_FRAME_TOPO_SCORE
Comment on table PHOTO_FRAME_TOPO_SCORE is 'table of photo topographic score data';
comment on column PHOTO_FRAME_TOPO_SCORE.DATA_ID is 'ID of the photo sequence of which this frame is
part: link to table PHOTO_SEQUENCE_HEADER';
comment on column PHOTO_FRAME_TOPO_SCORE.FRAME_NUMBER is 'unique number of this frame in relevant
photo sequence';
comment on column PHOTO_FRAME_TOPO_SCORE.PARAMETER_CODE is 'standardised code (=name) of the
parameter represented from table PARAMETER_SET';
comment on column PHOTO_FRAME_TOPO_SCORE.SCORE_CODE is 'scored value recorded';
comment on column PHOTO_FRAME_TOPO_SCORE.QC_FLAG is 'quality flag associated with this data item';
PROMPT Commenting table PHOTO_FRAME_TOPO_COUNT
comment on table PHOTO_FRAME_TOPO_COUNT is 'table of photo topographic counts';
comment on column PHOTO_FRAME_TOPO_COUNT.DATA_ID is 'ID of the photo sequence of which this frame is
part: link to table PHOTO_SEQUENCE_HEADER';
comment on column PHOTO_FRAME_TOPO_COUNT.FRAME_NUMBER is 'unique number of this frame in relevant
photo sequence';
comment on column PHOTO_FRAME_TOPO_COUNT.PARAMETER_CODE is 'standardised code (=name) of the
parameter represented from table PARAMETER_SET';
comment on column PHOTO_FRAME_TOPO_COUNT.ITEM_COUNT is 'number of items counted';
comment on column PHOTO_FRAME_TOPO_COUNT.QC_FLAG is 'quality flag associated with this data item';
PROMPT Commenting table PHOTO_FRAME_BIOTA_PRES_ABS
comment on table PHOTO_FRAME_BIOTA_PRES_ABS is 'table of photo biota presence/absence data';
comment on column PHOTO_FRAME_BIOTA_PRES_ABS.DATA_ID is 'ID of the photo sequence of which this
frame is part: link to table PHOTO_SEQUENCE_HEADER';
comment on column PHOTO_FRAME_BIOTA_PRES_ABS.FRAME_NUMBER is 'unique number of this frame in
relevant photo sequence';
comment on column PHOTO_FRAME_BIOTA_PRES_ABS.CAAB_SPECIES_CODE is 'numeric version of current CAAB
code for the species e.g. 37004001 for CAAB species 37 004001';
comment on column PHOTO_FRAME_BIOTA_PRES_ABS.PRESENCE_CODE is 'presence/absence recorded value from
table CODE_LIST';
comment on column PHOTO_FRAME_BIOTA_PRES_ABS.QC_FLAG is 'quality flag associated with this data
item';
comment on column PHOTO_FRAME_BIOTA_PRES_ABS.ORIGINAL_SPECIES_CODE is 'species codes which appeared
in the original data';
PROMPT Commenting table PHOTO_FRAME_BIOTA_SCORE
comment on table PHOTO_FRAME_BIOTA_SCORE is 'table of photo biota score data';
comment on column PHOTO_FRAME_BIOTA_SCORE.DATA_ID is 'ID of the photo sequence of which this frame
is part: link to table PHOTO_SEQUENCE_HEADER';
comment on column PHOTO_FRAME_BIOTA_SCORE.FRAME_NUMBER is 'unique number of this frame in relevant
photo sequence';
comment on column PHOTO_FRAME_BIOTA_SCORE.CAAB_SPECIES_CODE is 'numeric version of current CAAB code
for the species e.g. 37004001 for CAAB species 37 004001';
comment on column PHOTO_FRAME_BIOTA_SCORE.SCORE_CODE is 'scored value recorded';
comment on column PHOTO_FRAME_BIOTA_SCORE.QC_FLAG is 'flag associated with this data item';
comment on column PHOTO_FRAME_BIOTA_SCORE.ORIGINAL_SPECIES_CODE is 'species codes which appeared in
the original data';
PROMPT Commenting table PHOTO_FRAME_BIOTA_COUNT
comment on table PHOTO_FRAME_BIOTA_COUNT is 'table of photo biota counts';
comment on column PHOTO_FRAME_BIOTA_COUNT.DATA_ID is 'ID of the photo sequence of which this frame
is part: link to table PHOTO_SEQUENCE_HEADER';
comment on column PHOTO_FRAME_BIOTA_COUNT.FRAME_NUMBER is 'unique number of this frame in relevant
photo sequence';
comment on column PHOTO_FRAME_BIOTA_COUNT.CAAB_SPECIES_CODE is 'numeric version of current CAAB code
for the species e.g. 37004001 for CAAB species 37 004001';
comment on column PHOTO_FRAME_BIOTA_COUNT.ITEM_COUNT is 'number of items counted';
comment on column PHOTO_FRAME_BIOTA_COUNT.QC_FLAG is 'quality flag associated with this data item';
comment on column PHOTO_FRAME_BIOTA_COUNT.ORIGINAL_SPECIES_CODE is 'species codes which appeared in
the original data';
PROMPT Commenting table PROJECT
comment on table PROJECT is 'table of project information refreshed from marlin database';
comment on column PROJECT.PROJECT_ID is 'unique identifier given to a project record (from
marlin)';
comment on column PROJECT.PROJECT_NAME is 'name assigned to project (from marlin)';
comment on column PROJECT.PROJECT_DESCRIPTION is 'short description of project (from marlin)';
PROMPT Commenting table QC_FLAGS
comment on table QC_FLAGS is 'table of valid quality control flags';
comment on column QC_FLAGS.QC_flag is 'data quality flag';
comment on column QC_FLAGS.DATA_STATE is 'overall state of the data item';
comment on column QC_FLAGS.OPERATION is 'type of operation performed on the data ';
comment on column QC_FLAGS.ERROR_TYPE is 'description of type of data error detected';
PROMPT Commenting table SOURCE
comment on table SOURCE is 'table of sources of data refreshed from marlin database';
comment on column SOURCE.SOURCE_ID is 'unique identifier given to a data source (from marlin)';
comment on column SOURCE.SOURCE_NAME is 'name of source of data (from marlin)';
comment on column SOURCE.SOURCE_TYPE is 'type of data source (from marlin)';
PROMPT Commenting table SURVEY
comment on table SURVEY is 'table of survey information refreshed from marlin';
comment on column SURVEY.SURVEY_NAME is 'name given to vessel based survey expedition (from
marlin)';
comment on column SURVEY.SOURCE_ID is 'unique identifier given to a source record (from marlin)';
comment on column SURVEY.MARLIN_SURVEY_ID is 'survey id from MARLIN:SURVEYS table (from marlin)';
comment on column SURVEY.SURVEY_TYPE is 'general type of survey expedition (from marlin)';
comment on column SURVEY.PROJECT_ID is 'unique identifier for a project record (from marlin)';
comment on column SURVEY.START_TIME is 'time at which survey commenced (from marlin)';
comment on column SURVEY.END_TIME is 'time at which survey finished (from marlin)';
comment on column SURVEY.START_LOCATION is 'name of survey start location (from marlin)';
comment on column SURVEY.END_LOCATION is 'name of survey end location (from marlin)';
comment on column SURVEY.START_LAT is 'latitude at which survey started (from marlin)';
comment on column SURVEY.START_LON is 'longitude at which survey started (from marlin)';
comment on column SURVEY.END_LAT is 'latitude at which survey ended (from marlin)';
comment on column SURVEY.END_LON is 'longitude at which survey ended (from marlin)';
comment on column SURVEY.COMMENTS is 'reserved for any special comments regarding survey (from
marlin)';
PROMPT Commenting table UNDERWAY_DATA
comment on table UNDERWAY_DATA is 'table of underway data';
comment on column UNDERWAY_DATA.DATA_ID is 'unique identifier for individual voyage
comment on column UNDERWAY_DATA.TIME is 'time of parameter measurement';
comment on column UNDERWAY_DATA.PARAMETER_CODE is 'parameter measured';
comment on column UNDERWAY_DATA.VALUE is 'measured parameter value';
comment on column UNDERWAY_DATA.QC_FLAG is 'quality flag for this value';
record';
PROMPT Commenting table UNDERWAY_GPS
comment on table UNDERWAY_GPS is 'table of underway GPS data';
comment on column UNDERWAY_GPS.DATA_ID is 'unique identifier for individual voyage record';
comment on column UNDERWAY_GPS.TIME is 'gps time stamp';
comment on column UNDERWAY_GPS.LAT is 'gps latitude';
comment on column UNDERWAY_GPS.LON is 'gps longitude';
comment on column UNDERWAY_GPS.QC_FLAG is 'gps quality flag';
PROMPT Commenting table UNDERWAY_HEADER
comment on table UNDERWAY_HEADER is 'table of underway header information';
comment on column UNDERWAY_HEADER.DATA_ID is 'unique identifier for voyage';
comment on column UNDERWAY_HEADER.SURVEY_NAME is 'name given to vessel based survey expedition';
comment on column UNDERWAY_HEADER.DEPLOYMENT_ID is 'unique identifier for a deployment record';
comment on column UNDERWAY_HEADER.GLOBAL_PROJECT_ID is 'ID of the global project of which this photo
sequence is part (if applicable): link to table GLOBAL_PROJECT';
comment on column UNDERWAY_HEADER.START_TIME is 'time at which underway sampling commenced';
comment on column UNDERWAY_HEADER.END_TIME is 'time at which underway sampling finished';
comment on column UNDERWAY_HEADER.START_LAT is 'latitude at which underway position sampling
started';
comment on column UNDERWAY_HEADER.START_LON is 'longitude at which underway position sampling
started';
comment on column UNDERWAY_HEADER.END_LAT is 'latitude at which underway position sampling ended';
comment on column UNDERWAY_HEADER.END_LON is 'longitude at which underway position sampling ended';
comment on column UNDERWAY_HEADER.PROJECT_ID is 'unique identifier for a project record';
comment on column UNDERWAY_HEADER.MARLIN_ID is 'ID of the MarLIN record which describes underway
record';
comment on column UNDERWAY_HEADER.SECURITY_CODE is 'security code assigned to dataset 1-public 2data centre only 3-jems group only 4-CMR staff only';
comment on column UNDERWAY_HEADER.RELEASE_DATE is ' allows an expiry date to be applied to embargoed
data';
comment on column UNDERWAY_HEADER.LICENCE_NOTE is '"licence agreement applies: check Marlin" where
one exists or else null';
PROMPT Commenting table UNDERWAY_GEOMETRY
comment on table UNDERWAY_GEOMETRY is 'geometry information for UNDERWAY_HEADER table';
comment on column UNDERWAY_GEOMETRY.DATA_ID is 'unique identifier for individual data stream
record';
comment on column UNDERWAY_GEOMETRY.MI_PRINX is 'mapinfo unique index for table';
comment on column UNDERWAY_GEOMETRY.GEOLOC is 'oracle spatial object';
comment on column UNDERWAY_GEOMETRY.SECURITY_CODE is 'security code assigned to dataset 1-public 2data centre only 3-jems group only 4-CMR staff only';
comment on column UNDERWAY_GEOMETRY.LICENCE_NOTE is '"licence agreement applies: check Marlin" where
one exists or else null';
comment on column UNDERWAY_GEOMETRY.PARAMETER_CODE is 'type of parameter';
PROMPT Commenting table MAP_LAYER
comment on table MAP_LAYER is 'table populated with information for MapXtreme map layers';
comment on column MAP_LAYER.LAYER_ID is 'unique id';
comment on column MAP_LAYER.DRAW_ORDER is 'order of drawing layer';
comment on column MAP_LAYER.LAYER_NAME is 'name of layer';
comment on column MAP_LAYER.SOURCE_TYPE is 'where data is sourced from either tab files or database
tables';
PROMPT Commenting table MAP_LAYER_PARAMETER
comment on table MAP_LAYER_PARAMETER is 'table populated with parameters associated with the
construction of MapXtreme map layer';
comment on column MAP_LAYER_PARAMETER.LAYER_ID is 'unique id';
comment on column MAP_LAYER_PARAMETER.PARAMETER_NAME is 'parameter name';
comment on column MAP_LAYER_PARAMETER.PARAMETER_VALUE is 'parameter value';
PROMPT Commenting table APP_CATEGORY
comment on table APP_CATEGORY is 'table contains data required to build the categories section of
the trawlers search page';
comment on column APP_CATEGORY.CATEGORY_ID is 'unique id';
comment on column APP_CATEGORY.CATEGORY_NAME is 'name appearing in the parent category section of
the search page';
comment on column APP_CATEGORY.PARENT_CATEGORY_ID is 'parent category';
PROMPT Commenting table APP_CATEGORY_LOOKUP
comment on table APP_CATEGORY_LOOKUP is 'table contains one-to-many category to data_id';
comment on column APP_CATEGORY_LOOKUP.DATA_ID is 'unique data id';
comment on column APP_CATEGORY_LOOKUP.CATEGORY_ID is 'unique category id';
PROMPT Commenting table APP_USER
comment on table APP_USER is 'table storing trawler user details';
comment on column APP_USER.USER_ID is 'unique user id';
comment on column APP_USER.LOGIN is 'login name';
comment on column APP_USER.PASSWORD is 'login password';
PROMPT Commenting table APP_ACCESS
comment on table APP_ACCESS is 'table storing the one-to-may relationships of user and their
security code(s)';
comment on column APP_ACCESS.USER_ID is 'unique user id';
comment on column APP_ACCESS.SECURITY_CODE is 'security code assigned to dataset 1-public 2-data
centre only 3-jems group only 4-CMR staff only';
PROMPT Commenting table APP_CTD_SUMMARY
comment on table APP_CTD_SUMMARY is 'application summary table for ctd data';
comment on column APP_CTD_SUMMARY.DATA_ID is 'data id from CTD_DATA table';
comment on column APP_CTD_SUMMARY.PARAMETER_CODE is 'parameter code from CTD_DATA table';
comment on column APP_CTD_SUMMARY.COUNT is 'number of records of this parameter for this cast in the
CTD_DATA table';
PROMPT Commenting table APP_HTML_KEY_LOOKUP
comment on table APP_HTML_KEY_LOOKUP IS 'table used to maintain the relationship between a category
and the HTML snippet used to represent the category page';
comment on column APP_HTML_KEY_LOOKUP.CATEGORY_ID is 'a number assigned to a category';
comment on column APP_HTML_KEY_LOOKUP.HTML_KEY is 'the name of the category bean method called to
generate the page for a specific category';
PROMPT Commenting table APP_LOG
comment on
console';
comment on
comment on
comment on
comment on
table APP_LOG is 'table used to record application transactions - used by the application
column
column
column
column
APP_LOG.EXPIRED is 'a flag to indicate if a session has expired';
APP_LOG.SESSION_ID is 'the session id';
APP_LOG.SNIPPET is 'an xml snippet defining the transaction being logged';
APP_LOG.TRANSACTION_DATE is 'the date/time of the transaction';
PROMPT Commenting table APP_SEARCH_DEFINITION
comment on table APP_SEARCH_DEFINITION is 'table defining the result set classes associated with a
search page';
comment on column APP_SEARCH_DEFINITION.CLASS_NAME is 'name of the result set class to be created';
comment on column APP_SEARCH_DEFINITION.HTML_KEY is 'a key in the page refelecting a relationship
between the page and one or many result sets';
Download