Solved

Oracle8 - LIKE OPERATOR ON CLOB

Posted on 2003-12-06
4
3,844 Views
Last Modified: 2008-02-01
In Oracle 9 I could use the LIKE operator on CLOB objects, but it doesn't seems to work in Oracle 8.

Is there an alternative way to do it in Oracle 8 ?

example: select * from article where bodyText LIKE '%TEST%'

Batalf
0
Comment
Question by:Batalf
  • 2
  • 2
4 Comments
 
LVL 23

Expert Comment

by:seazodiac
ID: 9888420
that's right, in Oracle8i you have to use dbms_lob package.


SQL> SELECT * FROM A WHERE dbms_lob.instr(<column>,'<search_string>',1,1)>0;

hope this helps




0
 
LVL 32

Author Comment

by:Batalf
ID: 9888436
That helped a lot. Could you make it case-INsensitive too?
0
 
LVL 23

Accepted Solution

by:
seazodiac earned 250 total points
ID: 9888472
I guess you can do it by adding another layer of function like upper() or lower() like this:

SELECT * FROM A WHERE dbms_lob.instr(upper(<column>),upper('<search_string>'),1,1)>0;
0
 
LVL 32

Author Comment

by:Batalf
ID: 9888495
Off course :-)
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
ORA-01008: not all variables bound. 6 58
Queries 15 40
Oracle function to insert records? 15 42
SQL2016 to ORACLE11G linked-server 6 15
Introduction A previously published article on Experts Exchange ("Joins in Oracle", http://www.experts-exchange.com/Database/Oracle/A_8249-Joins-in-Oracle.html) makes a statement about "Oracle proprietary" joins and mixes the join syntax with gen…
How to Create User-Defined Aggregates in Oracle Before we begin creating these things, what are user-defined aggregates?  They are a feature introduced in Oracle 9i that allows a developer to create his or her own functions like "SUM", "AVG", and…
This video explains at a high level about the four available data types in Oracle and how dates can be manipulated by the user to get data into and out of the database.
This video shows setup options and the basic steps and syntax for duplicating (cloning) a database from one instance to another. Examples are given for duplicating to the same machine and to different machines

803 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question