Re: uniqueness not always correct

From: Peter Eisentraut <peter_e(at)gmx(dot)net>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>, Frank Cusack <fcusack(at)iconnet(dot)net>, pgsql-bugs(at)postgresql(dot)org
Subject: Re: uniqueness not always correct
Date: 2000-06-02 23:48:23
Message-ID: Pine.LNX.4.21.0006020351140.372-100000@localhost.localdomain
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs pgsql-hackers

Tom Lane writes:

[CIDR and INET]
> Alternatively, if no one cares enough about these types to even
> understand what they should do, maybe we should rip 'em out?

Actually, I'm a happy user of these types, so that would certainly make me
unhappy...

CIDR stores network addresses, so '10.8/16' might be some network. INET
stores both host addresses and, optionally, the network it's in, so
'10.8.7.6/16' is the given host in the network '10.8/16'. Alternatively,
INET '10.8.7.6' is just a host with no network. IMO, there is one of two
bugs in the CIDR input routine:

1) '10.8.7.6/16' in not rejected

2) Since it is accepted, at least the hidden fields need to be zeroed.

(But note that this bug is only exposed when you use the type improperly
in the first place.)

Using the same operators for cidr and inet is fine as long as this is
fixed.

--
Peter Eisentraut Sernanders väg 10:115
peter_e(at)gmx(dot)net 75262 Uppsala
http://yi.org/peter-e/ Sweden

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Peter Eisentraut 2000-06-03 22:44:59 Re: Bug Repoprt- Casting Issues
Previous Message Bruce Momjian 2000-06-02 14:56:40 Re: [BUGS] double dumps for all objects with pg_dump

Browse pgsql-hackers by date

  From Date Subject
Next Message Peter Eisentraut 2000-06-02 23:54:39 Re: config files in /data
Previous Message Peter Eisentraut 2000-06-02 23:47:53 Re: [HACKERS] Oft Ask: How to contribute to PostgreSQL?