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:

schemas/vegbien.my.sql
1984 1984
--
1985 1985

  
1986 1986
CREATE TABLE higher_plant_group_nodes (
1987
    higher_plant_group text NOT NULL,
1987
    higher_plant_group text,
1988 1988
    node_name text NOT NULL
1989 1989
);
1990 1990

  
......
4362 4362

  
4363 4363

  
4364 4364
--
4365
-- Name: higher_plant_group_node_pkey; Type: CONSTRAINT; Schema: public; Owner: -; Tablespace: 
4366
--
4367

  
4368
ALTER TABLE higher_plant_group_nodes
4369
    ADD CONSTRAINT higher_plant_group_node_pkey PRIMARY KEY (higher_plant_group, node_name);
4370

  
4371

  
4372
--
4373 4365
-- Name: location_pkey; Type: CONSTRAINT; Schema: public; Owner: -; Tablespace: 
4374 4366
--
4375 4367

  
......
4864 4856

  
4865 4857

  
4866 4858
--
4859
-- Name: higher_plant_group_nodes_unique; Type: INDEX; Schema: public; Owner: -; Tablespace: 
4860
--
4861

  
4862

  
4863

  
4864

  
4865
--
4867 4866
-- Name: location_accessioncode_index; Type: INDEX; Schema: public; Owner: -; Tablespace: 
4868 4867
--
4869 4868

  
schemas/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