Project

General

Profile

« Previous | Next » 

Revision 6246

schemas/vegbien.sql: higher_plant_group_nodes: Allow NULL values for higher_plant_group, to allow mapping all remaining families to NULL in family_higher_plant_group

View differences:

vegbien.sql
70 70
--
71 71

  
72 72
CREATE TYPE higher_plant_group AS ENUM (
73
    'all',
73 74
    'bryophytes',
74 75
    'ferns and allies',
75 76
    'flowering plants',
......
2755 2756
--
2756 2757

  
2757 2758
CREATE TABLE higher_plant_group_nodes (
2758
    higher_plant_group higher_plant_group NOT NULL,
2759
    higher_plant_group higher_plant_group,
2759 2760
    node_name text NOT NULL
2760 2761
);
2761 2762

  
......
5352 5353

  
5353 5354

  
5354 5355
--
5355
-- Name: higher_plant_group_node_pkey; Type: CONSTRAINT; Schema: public; Owner: -; Tablespace: 
5356
--
5357

  
5358
ALTER TABLE ONLY higher_plant_group_nodes
5359
    ADD CONSTRAINT higher_plant_group_node_pkey PRIMARY KEY (higher_plant_group, node_name);
5360

  
5361

  
5362
--
5363 5356
-- Name: location_pkey; Type: CONSTRAINT; Schema: public; Owner: -; Tablespace: 
5364 5357
--
5365 5358

  
......
5854 5847

  
5855 5848

  
5856 5849
--
5850
-- Name: higher_plant_group_nodes_unique; Type: INDEX; Schema: public; Owner: -; Tablespace: 
5851
--
5852

  
5853
CREATE UNIQUE INDEX higher_plant_group_nodes_unique ON higher_plant_group_nodes USING btree ((COALESCE(higher_plant_group, 'all'::higher_plant_group)), node_name);
5854

  
5855

  
5856
--
5857 5857
-- Name: location_accessioncode_index; Type: INDEX; Schema: public; Owner: -; Tablespace: 
5858 5858
--
5859 5859

  

Also available in: Unified diff