On Thu, Sep 01, 2005 at 03:51:35PM -0400, Merlin Moncure wrote:
> > Huh, hang on -- AFAIK there's no saving at all by doing that. Quite
> > the opposite really, because with char(x) you store the padding
> > blanks, which are omitted with varchar(x), so less I/O (not
> > necessarily a measurable amount, mind you, maybe even zero because
> > of padding issues.)
>
> You are right, all this time I thought there was a 4 byte penalty for
> storing varchar type and not in char :(. So there is no reason at all
> to use the char type?
Other than SQL conformance, apparently not.
--
Alvaro Herrera -- Valdivia, Chile Architect, www.EnterpriseDB.com
Bob [Floyd] used to say that he was planning to get a Ph.D. by the "green
stamp method," namely by saving envelopes addressed to him as 'Dr. Floyd'.
After collecting 500 such letters, he mused, a university somewhere in
Arizona would probably grant him a degree. (Don Knuth)