Re: length limitation in '=' operator when comparing TEXT fields ?

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Michael Beckstette" <mbeckste(at)TechFak(dot)Uni-Bielefeld(dot)DE>
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: length limitation in '=' operator when comparing TEXT fields ?
Date: 2002-05-23 20:15:23
Message-ID: 23370.1022184923@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

"Michael Beckstette" <mbeckste(at)TechFak(dot)Uni-Bielefeld(dot)DE> writes:
> i have a little problem when selecting entries from a table, specified by a
> long match on a field of type TEXT. Is there a length limitation for the '='
> operator when comparing a field of type TEXT to a given string ?

No.

> Example:

> SELECT description FROM sequences_33 WHERE description LIKE 'gi 17559974%';
^^^^^^^^^^^^^^^^^^^
> [ finds a row ]

> SELECT description FROM sequences_33 WHERE description=' gi 17559974 ref
^^^^^^^^^^^^^^^^^
> [ finds no row ]

You seem to think that leading spaces are insignificant. They are not.

regards, tom lane

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Michael Beckstette 2002-05-23 22:41:44 Re: length limitation in '=' operator when comparing TEXT fields ?
Previous Message Michael Beckstette 2002-05-23 19:23:55 length limitation in '=' operator when comparing TEXT fields ?