add unique constraint for worksheet and tab name in ghseet tracked table
authorRogan Hamby <rhamby@esilibrary.com>
Tue, 30 Jan 2018 14:23:34 +0000 (09:23 -0500)
committerRogan Hamby <rhamby@esilibrary.com>
Tue, 30 Jan 2018 14:23:34 +0000 (09:23 -0500)
mig-sql/init/010-gsheet_tracked_table.sql

index 29404fd..842d320 100644 (file)
@@ -6,5 +6,6 @@ CREATE TABLE gsheet_tracked_table (
     ,tab_name                   TEXT
     ,created                    TIMESTAMP
     ,last_pulled                TIMESTAMP
+    ,UNIQUE(worksheet_name,tab_name)
 );