Re: cidr question (resent)

Alex Pilosov <alex@pilosoft.com>

From: Alex Pilosov <alex@pilosoft.com>
To: Mir S Islam <mislam@mindspring.com>
Cc: pgsql-sql@postgresql.org
Date: 2001-12-13T03:37:03Z
Lists: pgsql-sql
On Wed, 12 Dec 2001, Mir S Islam wrote:

> should not the command
> DELETE from ip_space where ip = '11.0.1.0/24'::cidr
> delete last two rows ? But it does not delete anything. Basically I would
> like to be able to delete a whole range or block of ip/network addresses.

You need:
DELETE from ip_space where ip << '11.0.1.0/24'::cidr

<< is 'belongs to'. 

-alex