I have a query which is 'execute immediate vc_query into vcl_result'. Here vc_query is a varchar2 which is holding my query and return some value, And vc_result is a CLOB.
Now, this statement is failing to execute and saying inconsistent datatypes.
Is there a way I can convert the result of the sql query in the variable to convert to clob?
Yes and no. It depends.
a) why are you using execute immediate to execute a query?
b) why do you want the results stored in a CLOB?
c) what structure should the results have in the CLOB?
d) read the FAQ: Re: 2. How do I ask a question on the forums? and post sufficient details so people can answer you properly.