Avatar of italoestrada
italoestradaFlag for Panama

asked on 

Search in a Column type CLOB in DB2

I am doing a search in a column type CLOB,, i can do a search just like,,,,
where (CLOB_COLUMN) = '%FILTER%'
but i still have problems with the upper and lowercase,,,,,,  
i try to do
where upper(CLOB_COLUMN) = upper('%FILTER%')
its any other way to do it....????
DatabasesDB2

Avatar of undefined
Last Comment
italoestrada
ASKER CERTIFIED SOLUTION
Avatar of Kent Olsen
Kent Olsen
Flag of United States of America image

Blurred text
THIS SOLUTION IS ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
Avatar of momi_sabag
momi_sabag
Flag of United States of America image

if your clob values is less than 32k in length you can just cast it to varchar and use upper and lower
no need to loop if the value is less than 32k
otherwise, Kent's solution is what you should use
Avatar of italoestrada
italoestrada
Flag of Panama image

ASKER

Thanks, i try it and work real good,,,,,, what i did was

upper(SUBSTR(the clob, 1,254)) like  '%Search key%'

it works real good,, thanks for your good advice.....
Avatar of italoestrada
italoestrada
Flag of Panama image

ASKER

Good anwer,,, i try it and i works right away......
Databases
Databases

Databases are organized collections of data, most commonly accessed through management systems including schemas, tables, queries and processes that allow users to enter and manipulate the information or utilize it in other fashions, such as with web applications or for reporting purposes.

62K
Questions
--
Followers
--
Top Experts
Get a personalized solution from industry experts
Ask the experts
Read over 600 more reviews

TRUSTED BY

IBM logoIntel logoMicrosoft logoUbisoft logoSAP logo
Qualcomm logoCitrix Systems logoWorkday logoErnst & Young logo
High performer badgeUsers love us badge
LinkedIn logoFacebook logoX logoInstagram logoTikTok logoYouTube logo