Re: IPv4 addresses, unsigned integers, space

From: Bruno Wolff III <bruno(at)wolff(dot)to>
To: pgsql-general(at)postgresql(dot)org
Subject: Re: IPv4 addresses, unsigned integers, space
Date: 2003-07-16 16:18:10
Message-ID: 20030716161810.GA1263@wolff.to
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Tue, Jul 15, 2003 at 22:12:13 +0200,
Florian Weimer <fw(at)deneb(dot)enyo(dot)de> wrote:
> Bruno Wolff III <bruno(at)wolff(dot)to> writes:
>
> >> Does PostgreSQL already implement these data types? I don't think so.
> >> If I succeed in implementing them, would you accept a patch?
> >
> > You can have unsigned integers using a domain with a check constraint.
>
> They take twice as much storage as necessary.

This depends on the range of numbers you need. If you specifically need
integers greater than 2^31-1 and don't need any greater than 2^32-1, then
that is true. In most cases there won't be a per item space penalty.

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Ron 2003-07-16 16:22:07 COPY problem
Previous Message Kirill Ponazdyr 2003-07-16 16:18:09 Re: Postgresql "FIFO" Tables, How-To ?