diff options
author | Neels Hofmeyr <nhofmeyr@sysmocom.de> | 2017-02-01 17:08:56 +0100 |
---|---|---|
committer | Harald Welte <laforge@gnumonks.org> | 2017-02-01 19:13:27 +0000 |
commit | cc785f0c43686c0e9ec523ef5f9330e27a44dba2 (patch) | |
tree | 1104e4ad909c8002e59c3bbd5e6a7920f811ddd5 /sql | |
parent | 6b883f784835943e1b3dbcf816dd2a949dd6805d (diff) |
sql: add unique constraints to IMSI and MSISDN
Todo for later: table subscriber_multi_msisdn possibly allows duplicating the
MSISDN, so we should drop this table or have all MSISDNs in one table separate
from 'subscriber'.
Change-Id: I5737106a232e416d67a10634e6270a7a89cf1b05
Diffstat (limited to 'sql')
-rw-r--r-- | sql/hlr.sql | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sql/hlr.sql b/sql/hlr.sql index 5a02be3..9238871 100644 --- a/sql/hlr.sql +++ b/sql/hlr.sql @@ -3,9 +3,9 @@ CREATE TABLE subscriber ( id INTEGER PRIMARY KEY, -- Chapter 2.1.1.1 - imsi VARCHAR(15) NOT NULL, + imsi VARCHAR(15) UNIQUE NOT NULL, -- Chapter 2.1.2 - msisdn VARCHAR(15), + msisdn VARCHAR(15) UNIQUE, -- Chapter 2.2.3: Most recent / current IMEI imeisv VARCHAR, -- Chapter 2.4.5 |