Skip to Main Content

SQL Developer

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!

Not able to Export XMLAGG output.

User_U5XKZAug 17 2022 — edited Aug 18 2022

When i try to export result of XMLAGG function in SQL Developer. I get blank values in Excel Sheet against the Column.
Please let me know how to resolve this.
They Query is as follows:
SELECT XMLCAST(
XMLAGG(XMLELEMENT(E,NAME,'#') .EXTARACT('//text()') ORDER BY ID )
AS CLOB
) AS NAME_LIST
FROM EMPLOYEE
GROUP BY ID;
Using the above Query i do not get values in the export Excel file.
But, when i use following below query, I am able to export the data in Excel but, special characters like &,>,<, get converted in XML form of &, >,
They Query is as follows:
SELECT
XMLAGG(XMLELEMENT(E,NAME,'#') .EXTARACT('//text()') ORDER BY ID )
AS NAME_LIST
FROM EMPLOYEE
GROUP BY ID;

Comments
Post Details
Added on Aug 17 2022
5 comments
398 views