Open lgo opened 7 years ago
I notice INET type is in 2.0, but apparently not CIDR - will this be coming? Applications such as Netbox need both... To add to that, CRDB is targeted at distributed network-based applications - INET and CIDR datatypes are perfect for managing all kinds of things in this domain. ... not to mention that not having CIDR is an empty checkbox for any claimed Postgres compatibility. I would assume that Postgres added these datatypes because there was a need; if PG had the need, it can only be more of a need for the network-distributed CRDB.
Just a quick note here that although INET has been added, CIDR has not... so I think this issue should still be held open. 6 years so far... any idea when this might be implemented?
The CIDR column type for dealing with IP addresses in postgresql. It's closely related to the INET column type with some minor differences.
Many of the same functions for INET are supported by CIDR, either by casting it to an INET or from CIDR with a few differences, e.g.
abbrev
omits octets with no bits set (or not covered at all by the prefix length, you'd have to check postgres to determine that)set_masklen
truncates bits not covered by the prefix lengthnetwork
returns a CIDR but consumes an INETSee the postgres docs for features https://www.postgresql.org/docs/current/static/datatype-net-types.html https://www.postgresql.org/docs/current/static/functions-net.html
Jira issue: CRDB-5993