From: Brian Flowers Date: Wed, 27 May 2020 12:44:26 +0000 (-0400) Subject: Adding unique constraint on lookups table X-Git-Url: http://git.slightlycyberpunk.com%2C%20git.slightlycyberpunk.com/git/?a=commitdiff_plain;ds=inline;p=firewall-lists-3.git Adding unique constraint on lookups table --- diff --git a/bin/firewall-lists b/bin/firewall-lists index f7dd8d4..fc54c56 100755 --- a/bin/firewall-lists +++ b/bin/firewall-lists @@ -251,7 +251,8 @@ CREATE TABLE lookups(id INTEGER, domain INTEGER, ip VARCHAR(128), lookupDate DATETIME default CURRENT_TIMESTAMP, - PRIMARY KEY(id)); + PRIMARY KEY(id) + UNIQUE(domain, ip)); EOF fi }