Re: What datatype should I use to store an IP Address?

From: Michał Pawlikowski <misiekbest(at)gmail(dot)com>
To: Andre Lopes <lopes80andre(at)gmail(dot)com>
Cc: postgresql Forums <pgsql-general(at)postgresql(dot)org>
Subject: Re: What datatype should I use to store an IP Address?
Date: 2010-03-25 10:28:52
Message-ID: 217ea9ed1003250328i565eb0fax1084c59c130cf8ed@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

>On Thu, Mar 25, 2010 at 11:25 AM, Andre Lopes <lopes80andre(at)gmail(dot)com> wrote:
> Hi,
>
> I'm using Varchar(16) to store an IP Address. PostgreSQL offers another
> datatypes to store IP's or it is OK to store in Varchar(16)?
>
> Best Regards,
>

Yes, just look here:
http://www.postgresql.org/docs/8.4/static/datatype-net-types.html

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Devrim GÜNDÜZ 2010-03-25 11:22:00 Re: What datatype should I use to store an IP Address?
Previous Message Andre Lopes 2010-03-25 10:25:52 What datatype should I use to store an IP Address?