Revision 2869
Added by Aaron Marcuse-Kubitza over 12 years ago
vegbien.sql | ||
---|---|---|
3774 | 3774 |
|
3775 | 3775 |
|
3776 | 3776 |
-- |
3777 |
-- Name: namedplace_unique; Type: CONSTRAINT; Schema: public; Owner: -; Tablespace: |
|
3778 |
-- |
|
3779 |
|
|
3780 |
ALTER TABLE ONLY namedplace |
|
3781 |
ADD CONSTRAINT namedplace_unique UNIQUE (rank, placename); |
|
3782 |
|
|
3783 |
|
|
3784 |
-- |
|
3785 | 3777 |
-- Name: namedplacecorrelation_pkey; Type: CONSTRAINT; Schema: public; Owner: -; Tablespace: |
3786 | 3778 |
-- |
3787 | 3779 |
|
... | ... | |
4810 | 4802 |
|
4811 | 4803 |
|
4812 | 4804 |
-- |
4805 |
-- Name: namedplace_unique; Type: INDEX; Schema: public; Owner: -; Tablespace: |
|
4806 |
-- |
|
4807 |
|
|
4808 |
CREATE UNIQUE INDEX namedplace_unique ON namedplace USING btree ((COALESCE(parent_id, 2147483647)), rank, placename); |
|
4809 |
|
|
4810 |
|
|
4811 |
-- |
|
4813 | 4812 |
-- Name: note_accessioncode_index; Type: INDEX; Schema: public; Owner: -; Tablespace: |
4814 | 4813 |
-- |
4815 | 4814 |
|
Also available in: Unified diff
schemas/vegbien.sql: namedplace: Fixed bug where parent_id needed to be included in UNIQUE CONSTRAINT (now UNIQUE INDEX), since there can be more than one e.g. city of the same name if they are in different states