From: Bruce Momjian <pgman@candle.pha.pa.us>
To: Frank Bax <fbax@sympatico.ca>
Cc: pgsql-sql@postgresql.org
Subject: Re: VARCHAR vs TEXT
Date: Tue, 16 Oct 2001 11:55:21 -0400 (EDT)
Message-ID: <200110161555.f9GFtLj17838@candle.pha.pa.us> (raw)
In-Reply-To: <3.0.6.32.20011016114643.01e80c00@pop6.sympatico.ca>
There is a limits FAQ item, not a separate limits FAQ. Sorry for the
confusion.
> Perhaps 'limits' should be part of FAQ, not separate entity?
>
> Also a reference (or link) to 'limits' from other sections such as
> mentioned below may be more appropriate than duplicating the information.
>
> Frank
>
> At 08:56 AM 10/16/01 -0400, you wrote:
> >> >>>>> "BM" == Bruce Momjian <pgman@candle.pha.pa.us> writes:
> >>
> >> BM> <P>CHAR() is best when storing strings that are usually the
> >> BM> same length. VARCHAR() is best when storing variable-length
> strings,
> >> BM> but you want to limit how long a string can be. TEXT is for
> strings
> >> BM> of unlimited length, maximum 1 gigabyte. BYTEA is for storing
> >> BM> binary data, particularly values that include NULL bytes.</P>
> >>
> >> Could you add the length limitation for TEXT to the reference manual?
> >> I searched high and low for that limit, but never found it. Also,
> >> what's the max VARCHAR() or CHAR() I can create? Is that also 1Gb?
> >
> >TEXT limit is 1GB, as shown on the 'limits' FAQ item. Is it worth
> >mentioning here? CHAR()/VARCHAR() also 1GB limit.
> >
> >--
> > Bruce Momjian | http://candle.pha.pa.us
> > pgman@candle.pha.pa.us | (610) 853-3000
> > + If your life is a hard drive, | 830 Blythe Avenue
> > + Christ can be your backup. | Drexel Hill, Pennsylvania 19026
> >
> >---------------------------(end of broadcast)---------------------------
> >TIP 4: Don't 'kill -9' the postmaster
> >
>
--
Bruce Momjian | http://candle.pha.pa.us
pgman@candle.pha.pa.us | (610) 853-3000
+ If your life is a hard drive, | 830 Blythe Avenue
+ Christ can be your backup. | Drexel Hill, Pennsylvania 19026
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-sql@postgresql.org
Cc: pgman@candle.pha.pa.us, fbax@sympatico.ca
Subject: Re: VARCHAR vs TEXT
In-Reply-To: <200110161555.f9GFtLj17838@candle.pha.pa.us>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox