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!

performance issue with XMLElement & XMLAgg

User739955-OracleFeb 24 2011 — edited Feb 25 2011
I have the below query

SELECT XMLELEMENT ("ns1:listOfItems",
XMLATTRIBUTES ( 'http://www.w3.org/2001/XMLSchema-instance' AS "xmlns:xsi",
'http://www.w3.org/2001/XMLSchema' AS "xmlns:xsd",
'http://xmlns.oracle.com/apps/ego/item/service/out' AS "xmlns:ns1"),
XMLAGG(w.XMLCONTENT.extract('//Item') ))
FROM EGO_PUB_WS_OUTPUT w where session_id =13366

And the structure of EBO_PUB_WS_OUTPUT is as follows:

Name Null Type
------------------------------ -------- ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
SESSION_ID NOT NULL NUMBER
ODI_SESSION_ID NOT NULL NUMBER
WEB_SERVICE_NAME VARCHAR2(100)
SEQUENCE_ID NOT NULL NUMBER
ENTITY_TYPE VARCHAR2(100)
STATUS VARCHAR2(100)
XML_ODI XMLTYPE()
XMLCONTENT XMLTYPE()
XMLCLOB CLOB()
CREATION_DATE NOT NULL DATE
CREATED_BY NOT NULL NUMBER


The select takes a couple of seconds for 10records. But more than 2 min for 50. Can anything be done to improve this.

XMLCONTENT in the table is really a big.
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Mar 25 2011
Added on Feb 24 2011
2 comments
381 views