Re: Big trouble implementing a search on a LONG field...

From: Sybrand Bakker <postbus_at_sybrandb.demon.nl>
Date: Fri, 18 Aug 2000 22:21:57 +0200
Message-ID: <966631673.27041.2.pluto.d4ee154e_at_news.demon.nl>


You'll need Oracle Context (v7) or Oracle Intermedia (Oracle 8) to accomplish this.

Hth,

Sybrand Bakker, Oracle DBA

<monsri_at_my-deja.com> wrote in message news:8njijr$v0l$1_at_nnrp1.deja.com...
> Hi,
> Has someone already implemented a function that returns true
> if the string passed as its parameter is contained in a LONG
> field ??
> You know you can't do a ..WHERE <long field> LIKE '%XXX%',
> that's why I'd like to be able to do as follows:
> > SELECT...
> > FROM <myTable>
> > WHERE isItInMyLongField('%XXX%');
>
> where the function ISITINMYLONGFIELD would look like:
> > create or repl. function ISITINMYLONGFIELD(param in varchar2)
> > return boolean
> > is
> > l_string varchar2(32767);
> > begin
> > select <myLongField> into l_string
> > from <myTable>
> > where .. // !! <= the big problem comes from here !!
> > ...
> > if l_string like param then
> > return true;
> > else
> > return false;
> > end if;
> > end;
> > /
>
> Does someone have already succeeded in such an implementation ??
>
> Thanks a lot !
>
> Seb
>
>
> Sent via Deja.com http://www.deja.com/
> Before you buy.
Received on Fri Aug 18 2000 - 22:21:57 CEST

Original text of this message