Re: length limitation in '=' operator when comparing TEXT fields ? - Mailing list pgsql-bugs

From Tom Lane
Subject Re: length limitation in '=' operator when comparing TEXT fields ?
Date
Msg-id 23370.1022184923@sss.pgh.pa.us
Whole thread Raw
In response to length limitation in '=' operator when comparing TEXT fields ?  ("Michael Beckstette" <mbeckste@TechFak.Uni-Bielefeld.DE>)
List pgsql-bugs
"Michael Beckstette" <mbeckste@TechFak.Uni-Bielefeld.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

pgsql-bugs by date:

Previous
From: "Michael Beckstette"
Date:
Subject: length limitation in '=' operator when comparing TEXT fields ?
Next
From: "Michael Beckstette"
Date:
Subject: Re: length limitation in '=' operator when comparing TEXT fields ?