Re: inet increment with int

From: Andrew - Supernews <andrew+nonews(at)supernews(dot)com>
To: pgsql-hackers(at)postgresql(dot)org
Subject: Re: inet increment with int
Date: 2005-09-07 02:48:00
Message-ID: slrndhsl70.1vfu.andrew+nonews@trinity.supernews.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 2005-09-06, Patrick Welche <prlw1(at)newn(dot)cam(dot)ac(dot)uk> wrote:
> Now with:
>
> test=# select '192.168.0.0/24'::inet + 1;
> ERROR: Trying to increment a network (192.168.0.0/24) rather than a host

What possible justification is there for this behaviour?

> test=# select '192.168.0.1/24'::inet + -1;
> ERROR: Increment returns a network (192.168.0.0/24) rather than a host

While I suspect I know where this idea came from, it is equally boneheaded
since it is making completely unwarranted assumptions about how inet
values are being used.

--
Andrew, Supernews
http://www.supernews.com - individual and corporate NNTP services

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tim Allen 2005-09-07 02:55:49 Re: 4D Geometry
Previous Message nathan wagner 2005-09-07 02:36:06 Re: uuid type for postgres