mr.dash.f...@googlemail.com writes: > 1. select '10.1.1.0/24'::inet between '10.1.1.0'::inet and > '10.1.1.255'::inet gives me FALSE.
> Am I missing something obvious? 10.1.1.0/24 is different from, and sorts before, 10.1.1.0/32 (which is what '10.1.1.0'::inet is an abbreviation for). You might find that the net address inclusion operators (<< and friends) provide the semantics you're looking for. BETWEEN only knows about btree sort ordering, which is fundamentally a brick or two shy of a load when considering two-dimensional quantities such as netmasks. regards, tom lane -- Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-bugs