Skip site navigation (1) Skip section navigation (2)

Re: Disadvantages to using "text"

From: Bruce Hyatt <brucejhyatt(at)yahoo(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Aurynn Shaw <ashaw(at)commandprompt(dot)com>, "Don Mies \(NIM\)" <dmies(at)networksinmotion(dot)com>, pgsql-novice(at)postgresql(dot)org
Subject: Re: Disadvantages to using "text"
Date: 2008-05-08 01:40:52
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-novice
> Well, all the textual operators/functions are actually
> declared to take
> and return type TEXT, so when you are working with VARCHAR
> columns the
> expressions have no-op cast nodes in them ("RelabelType"
> nodes), even
> if it's an unconstrained-length VARCHAR.  I'm not sure whether
> the
> execution cost of these would be measurable in real
> applications, but
> it's not zero.  A bigger problem is that sometimes the planner
> gets
> confused by the RelabelTypes and fails to find as good a plan
> as it
> finds for a pure-TEXT query. 

I assume this is true for version 7 as well as version 8.


Be a better friend, newshound, and 
know-it-all with Yahoo! Mobile.  Try it now.;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ

In response to

pgsql-novice by date

Next:From: Bruce MomjianDate: 2008-05-08 19:11:59
Subject: Re: [NOVICE] encoding problems
Previous:From: Bruce MomjianDate: 2008-05-07 20:32:43
Subject: Re: [NOVICE] encoding problems

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group