From: olivier Date: Mon, 4 May 2009 13:21:34 +0000 (+0000) Subject: docref sql: add uniqueness constraint to publisher collections X-Git-Url: https://git.parisson.com/?a=commitdiff_plain;h=e07ff3c2c089f1eb8197d11c00ad113784542bc9;p=telemeta-data.git docref sql: add uniqueness constraint to publisher collections git-svn-id: http://svn.parisson.org/svn/crem@90 3bf09e05-f825-4182-b9bc-eedd7160adf0 --- diff --git a/trunk/docref/crem.sql b/trunk/docref/crem.sql index 0539d02..b82405a 100644 --- a/trunk/docref/crem.sql +++ b/trunk/docref/crem.sql @@ -111,7 +111,8 @@ CREATE TABLE publisher_collections ( publisher_id INTEGER NOT NULL, value VARCHAR(250) NOT NULL, - FOREIGN KEY(publisher_id) REFERENCES publishers (id) ON DELETE CASCADE + FOREIGN KEY(publisher_id) REFERENCES publishers (id) ON DELETE CASCADE, + UNIQUE (publisher_id, value) ) ENGINE=InnoDB; --