Hi I am getting the below error.What should I make change so as to accommodate the maximum size for this variable
[Error] Execution (1: 1): ORA-19011: Character string buffer too small ORA-06512: at line 4
DECLARE
c_var CLOB;
BEGIN
SELECT
RTRIM(XMLAGG(XMLELEMENT(E,'''' ||code|| ''' AS '||code||',')ORDER BY code).extract('//text()'),',')
INTO c_var FROM (SELECT DISTINCT Code from table_A);
DBMS_OUTPUT.PUT_LINE (c_var);
END;
codeand what is it's value. If it is aclob, you can't just concatenate them. - Patrick Hofman