× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Hi David,
I have a working SQL CLOB example.
I will send it to you tomorrow if you think it will help.
Regards,Mark.

On Wednesday, 31 May 2017, 19:34, David Gibbs <david@xxxxxxxxxxxx> wrote:


Folks:

I'm trying to write a procedure that uses the regexp_replace SQL function with very large variables.

The variables are 256000 characters long.

exec sql set :newvar = regexp_replace(:oldvar, regex, replacement, 1, 'i');

If I just define the variables as char (256000), the compile fails with a SQL0312.

Is the right approach to define the variables as SQLTYPE(CLOB:256000) and do a ...

oldvar_DATA = somevalue;
oldvar_LEN = %len(%trim(somevalue));

... before invoking the SQL function?

Thanks!

david




As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.