Skip to Main Content

Database Software

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!

XMLAGG performance problems

411850Jan 29 2007 — edited Feb 1 2007
Hello,
I've been having performance problems with one query using XMLAGG. Explain plan shows that all tables are joined using correct indexes - there is nothing wrong with it. After series of experiments with the query I found out that the problem is in use of XMLAGG function. It aggregates the data before submitting it to the result XML document.

I there any way to generate something like
<Main attr1="...">
<el1>...</el1>
<el2>...</el2>
<SubElement>
<row>row1 from the database</row>
<row>row2 from the database</row>
....
<row>rowN from the database</row>
</SubElement>
<Main>

without using XMLAGG in the subquery or somehow switch the aggregation off? I dont really need the records to be aggregated, all I need is to be able to generate multiple record based XML in the subquery which would have normally failed on (single-row query returned more than one record exception) without XMLAGG.

Thanks in advance
Alexey
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Mar 1 2007
Added on Jan 29 2007
8 comments
1,381 views