Evenin'What I discovered just lately is a nice feature from pgsql that I can testif a specific IP address falls within a supplied subnet:myserver=# select inet '192.168.0.1' << '192.168.0.0/24'::inet as ip; ip ---- t(1 row)But what I don't understand is why pgsql doesn't behave correctly when testing for a /32 subnet:(it works for /31 correctly though)myserver=# select inet '192.168.0.1' << '192.168.0.1/32'::inet as ip; ip ---- fFrom a network engineering point of view this should also return "true" and not false.
myserver=# select inet '192.168.0.1' << '192.168.0.0/24'::inet as ip;
ip
----
t
(1 row)
myserver=# select inet '192.168.0.1' << '192.168.0.1/32'::inet as ip;
f
pgsql-sql by date:
Соглашаюсь с условиями обработки персональных данных