
June 28th, 2012, 09:23 AM
|
|
Registered User
|
|
Join Date: Feb 2010
Posts: 5
Time spent in forums: 5 h 32 m 32 sec
Reputation Power: 0
|
|
|
LIKE operator doesn't work in TEXT columns
Hello, everybody!
I don't know if I'm missing something because I'm relatively new to PostgreSQL, but here it is:
I have a TEXT column in a table. One of the rows has the value 'texto' in this column. So I'm trying to show this row with queries like these:
Code:
SELECT * FROM TABELA WHERE TEXT_COLUMN LIKE '%texto%'
SELECT * FROM TABELA WHERE TEXT_COLUMN LIKE 'texto%'
SELECT * FROM TABELA WHERE TEXT_COLUMN LIKE '%texto'
and no rows are returned.
What am I doing wrong? Doesn't we use the LIKE operator to search in TEXT columns in PostgreSQL?
Thank you.
Marcos
|