Module: sip-router
Branch: master
Commit: 902a3c31c25d20355351a4aa336abee7270a6868
URL:
http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=902a3c3…
Author: Henning Westerholt <henning.westerholt(a)1und1.de>
Committer: Henning Westerholt <henning.westerholt(a)1und1.de>
Date: Mon Nov 30 23:36:29 2009 +0100
db scheme(k): update lcr tables scripts after index addition in scheme
---
utils/kamctl/mysql/lcr-create.sql | 3 ++-
utils/kamctl/oracle/lcr-create.sql | 3 ++-
utils/kamctl/postgres/lcr-create.sql | 3 ++-
3 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/utils/kamctl/mysql/lcr-create.sql b/utils/kamctl/mysql/lcr-create.sql
index 1c6db01..63d72be 100644
--- a/utils/kamctl/mysql/lcr-create.sql
+++ b/utils/kamctl/mysql/lcr-create.sql
@@ -14,7 +14,8 @@ CREATE TABLE gw (
weight INT UNSIGNED,
flags INT UNSIGNED DEFAULT 0 NOT NULL,
defunct INT UNSIGNED DEFAULT NULL,
- CONSTRAINT lcr_id_gw_name_idx UNIQUE (lcr_id, gw_name)
+ CONSTRAINT lcr_id_grp_id_gw_name_idx UNIQUE (lcr_id, grp_id, gw_name),
+ CONSTRAINT lcr_id_grp_id_ip_addr_idx UNIQUE (lcr_id, grp_id, ip_addr)
) ENGINE=MyISAM;
INSERT INTO version (table_name, table_version) values ('lcr','3');
diff --git a/utils/kamctl/oracle/lcr-create.sql b/utils/kamctl/oracle/lcr-create.sql
index 1dc954a..075af32 100644
--- a/utils/kamctl/oracle/lcr-create.sql
+++ b/utils/kamctl/oracle/lcr-create.sql
@@ -14,7 +14,8 @@ CREATE TABLE gw (
weight NUMBER(10),
flags NUMBER(10) DEFAULT 0 NOT NULL,
defunct NUMBER(10) DEFAULT NULL,
- CONSTRAINT gw_lcr_id_gw_name_idx UNIQUE (lcr_id, gw_name)
+ CONSTRAINT gw_lcr_id_grp_id_gw_name_idx UNIQUE (lcr_id, grp_id, gw_name),
+ CONSTRAINT gw_lcr_id_grp_id_ip_addr_idx UNIQUE (lcr_id, grp_id, ip_addr)
);
CREATE OR REPLACE TRIGGER gw_tr
diff --git a/utils/kamctl/postgres/lcr-create.sql b/utils/kamctl/postgres/lcr-create.sql
index 834ea08..e23e7f7 100644
--- a/utils/kamctl/postgres/lcr-create.sql
+++ b/utils/kamctl/postgres/lcr-create.sql
@@ -14,7 +14,8 @@ CREATE TABLE gw (
weight INTEGER,
flags INTEGER DEFAULT 0 NOT NULL,
defunct INTEGER DEFAULT NULL,
- CONSTRAINT gw_lcr_id_gw_name_idx UNIQUE (lcr_id, gw_name)
+ CONSTRAINT gw_lcr_id_grp_id_gw_name_idx UNIQUE (lcr_id, grp_id, gw_name),
+ CONSTRAINT gw_lcr_id_grp_id_ip_addr_idx UNIQUE (lcr_id, grp_id, ip_addr)
);
INSERT INTO version (table_name, table_version) values ('lcr','3');