Re: text vs varchar - Mailing list pgsql-sql

From Wei Weng
Subject Re: text vs varchar
Date
Msg-id 1024444191.16918.6.camel@Monet
Whole thread Raw
In response to Re: text vs varchar  (Josh Berkus <josh@agliodbs.com>)
List pgsql-sql
On Tue, 2002-06-18 at 18:59, Josh Berkus wrote:
> Wei,
> 
> > Is there any disadvantage of using TEXT datatype as opposed to a VARCHAR
> > datatype with a maximum length, especially when I do searches on them?
> 
> Yes.  You can't index TEXT because it's of potentially unlimited length.
> 
> -- 
> -Josh Berkus
> 
> 
I noticed that it is a characteristics of MS SQL Server, but I did
successfully create unique index based on a TEXT field in Postgresql
7.2, while that failed in MS SQL Server (7).

Or do they behave the same in this aspect?

Thanks

-- 
Wei Weng
Network Software Engineer
KenCast Inc.




pgsql-sql by date:

Previous
From: Michelle Murrain
Date:
Subject: Re: text vs varchar
Next
From: Josh Berkus
Date:
Subject: Re: date_part