I just noticed that comparing a text to a varchar results in an index not
being used without a cast in some circumstances. Given that they have
identical internal representations (or so I believe), that seems a little odd.
Can anyone shed some light on this for me? I assume it has something to
Philip Warner [EMAIL PROTECTED] writes:
I just noticed that comparing a text to a varchar results in an index not
being used without a cast in some circumstances. Given that they have
identical internal representations (or so I believe), that seems a little odd.
But they're not the same
At 10:18 AM 20/03/2003 -0500, Tom Lane wrote:
I have been wondering whether we couldn't eliminate the datatype
distinction between text and varchar.
That would be great if done magically in the backend. If all text columns
were effectively wrapped in a Cast(X to text), life from a users PoV would
Ross J. Reedstrom wrote:
On Wed, Jul 11, 2001 at 09:56:27AM -0400, Jan Wieck wrote:
Rachit Siamwalla wrote:
Is there any good reason to use VARCHAR over TEXT for a string field? ie.
performance hits, etc.
Other than running into the row size limit problem, are there any large
[EMAIL PROTECTED]
To: Jan Wieck [EMAIL PROTECTED]
Cc: Rachit Siamwalla [EMAIL PROTECTED];
[EMAIL PROTECTED]
Sent: Wednesday, July 11, 2001 10:56 AM
Subject: Re: [HACKERS] varchar vs. text
On Wed, Jul 11, 2001 at 09:56:27AM -0400, Jan Wieck wrote:
Rachit Siamwalla wrote:
Is there any good
Rachit Siamwalla wrote:
Is there any good reason to use VARCHAR over TEXT for a string field? ie.
performance hits, etc.
Other than running into the row size limit problem, are there any large
storage / performance penalties of using TEXT for virtually all strings?
Er - what kind of
On Wed, Jul 11, 2001 at 09:56:27AM -0400, Jan Wieck wrote:
Rachit Siamwalla wrote:
Is there any good reason to use VARCHAR over TEXT for a string field? ie.
performance hits, etc.
Other than running into the row size limit problem, are there any large
storage / performance penalties
Is there any good reason to use VARCHAR over TEXT for a string field? ie.
performance hits, etc.
Other than running into the row size limit problem, are there any large
storage / performance penalties of using TEXT for virtually all strings?
For ex. A phone number. This field probably wouldn't
Rachit Siamwalla [EMAIL PROTECTED] writes:
Is there any good reason to use VARCHAR over TEXT for a string field?
The only reason to use VARCHAR is if you *want* the data to be truncated
at a specific length. If you don't have a well-defined upper limit in
mind, I'd recommend TEXT.