Skip to content

Commit

Permalink
Use the inet data type for supermasters.ip on postgrsql.
Browse files Browse the repository at this point in the history
Use pgsql’s inet data type for v4 and v6 IP addresses in the
supermasters table.

The guarantees that the address will fit, that the queries will
return the addresses in canonical format, and correctness in that
nothing other than an IP address can be stored in that column.

Signed-off-by: James Cloos <cloos@jhcloos.com>
  • Loading branch information
jhcloos committed Oct 16, 2013
1 parent d1aef07 commit 14a2e52
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pdns/no-dnssec.schema.pgsql.sql
Expand Up @@ -30,7 +30,7 @@ CREATE INDEX nametype_index ON records(name,type);
CREATE INDEX domain_id ON records(domain_id);

create table supermasters (
ip VARCHAR(64) NOT NULL,
ip INET NOT NULL,
nameserver VARCHAR(255) NOT NULL,
account VARCHAR(40) DEFAULT NULL
);
Expand Down

0 comments on commit 14a2e52

Please sign in to comment.