Re: VARCHAR vs TEXT

From: Stephan Szabo <sszabo(at)megazone23(dot)bigpanda(dot)com>
To: Aasmund Midttun Godal <postgresql(at)envisity(dot)com>
Cc: pgsql-sql(at)postgresql(dot)org
Subject: Re: VARCHAR vs TEXT
Date: 2001-10-11 00:18:25
Message-ID: Pine.BSF.4.21.0110101716300.89375-100000@megazone23.bigpanda.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

On Wed, 10 Oct 2001, Aasmund Midttun Godal wrote:

> I am sure this question has been answered in some form or another
> before, but I can't really find anything on exactly this issue.
>
> Are there any differences between varchar and text other than
>
> 1. varchar has limited size
> 2. varchar is SQL 92 text is not?
>
> Especially regarding performance.
>
> Or am I correct to assume that if you need a place to store some text,
> and you are not sure how much (like an email address or a name) you
> are best off using text?

Pretty much yes. text and varchar are pretty equivalent other than
the fact that varchar specifies a maximum size.

In response to

Responses

Browse pgsql-sql by date

  From Date Subject
Next Message Josh Berkus 2001-10-11 04:20:12 Re: [NOVICE] Loading current_user and current_timestamp using COPY
Previous Message Aasmund Midttun Godal 2001-10-10 23:32:07 VARCHAR vs TEXT