
----------------------------------------------------------------
--
-- Table creation scripts for class organism
--

----------------------------------------------------------------
--
-- Schema
--
alter session set current_schema=rsat;


----------------------------------------------------------------
--
-- Main table - organism
--
CREATE TABLE organism
	(
		id                               	VARCHAR(32)	NOT NULL PRIMARY KEY,
		taxonomy                         	VARCHAR(255)
	)
;
GRANT select ON organism TO amaze;

----------------------------------------------------------------
--
-- Multivalue field - organism_names
--
CREATE TABLE organism_names
	(
		id                               	VARCHAR(32)	NOT NULL,
		names                            	VARCHAR(255),
		qualifier                        	VARCHAR(20)
	)
;
CREATE INDEX organism_names_id_index ON organism_names (id);
GRANT select ON organism_names TO amaze;

----------------------------------------------------------------
--
-- Quit
--
quit;