Received: from tomts11-srv.bellnexxia.net (tomts11.bellnexxia.net [209.226.175.55]) by postgresql.org (8.11.3/8.11.4) with ESMTP id f9GFo9P77444 for ; Tue, 16 Oct 2001 11:50:09 -0400 (EDT) (envelope-from fbax@sympatico.ca) Received: from ACER ([64.229.18.17]) by tomts11-srv.bellnexxia.net (InterMail vM.4.01.03.16 201-229-121-116-20010115) with SMTP id <20011016155005.RNN17332.tomts11-srv.bellnexxia.net@ACER>; Tue, 16 Oct 2001 11:50:05 -0400 Message-Id: <3.0.6.32.20011016114643.01e80c00@pop6.sympatico.ca> X-Sender: b1wudu74@pop6.sympatico.ca X-Mailer: QUALCOMM Windows Eudora Light Version 3.0.6 (32) Date: Tue, 16 Oct 2001 11:46:43 -0400 To: pgsql-sql@postgresql.org From: Frank Bax Subject: Re: VARCHAR vs TEXT Cc: Bruce Momjian In-Reply-To: <200110161256.f9GCu4P07329@candle.pha.pa.us> References: Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" X-Archive-Number: 200110/215 X-Sequence-Number: 5170 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 writes: >> >> BM>

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.

>> >> 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 >