Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

How to use the clob datatype column value of a row in where clause IN()

Rupa MohanJan 4 2018 — edited Jan 4 2018

Hi all,

I am using the table 'childtable' with column 'c1' datatype clob.

Inside this c1 column, i am storing the value in a huge string separated by comma(,)

Example:

idc1
1123,456,789,908,765
26359,1258,12,365

My requirement is like,

select * from basetable BT where CodeCombi in (select c1 from childtable CT where CT.id=BT.id )

On executing the above query , Im getting the following error:

ORA-00932: inconsistent datatypes: expected - got CLOB

00932. 00000 -  "inconsistent datatypes: expected %s got %s"

In my case c1 column will contain a huge string seperated by comma whose length can be more than the varchar2 default length.

How to achieve this?

Regards,

RM

Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Feb 1 2018
Added on Jan 4 2018
10 comments
2,567 views