Skip to Main Content

DevOps, CI/CD and Automation

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!

XMLTABLE TAKING TIME.

943494Aug 2 2013 — edited Aug 5 2013

Hi All,

I have a table named car and iam inserting values into it from car_xml table (from column xml_value it is xml type).

with small xml file it is inserting withing seconds.

But if i use large xml files around 2.27 MB size then it is taking minimum 2 minutes to process.

Below is the query iam using with XMLTABLE.

Is there any  other way to optimize this query or any other technique other than XMLTABLE. Please guide.

Oracle Database 10g Enterprise Edition Release 10.2.0.3.0 - 64bi

QUERY :-

INSERT INTO CAR ( MODEL_NO , COMPANY )

select XTAB.MODEL_NO,  XTAB.COMPANY

                           FROM CAR_XML,

       XMLTABLE(XMLNAMESPACES('http://car.viva.com/schema/Create' AS "gs"),

       'for $i in /gs:rowset/gs:row/gs:engine/gs:model/gs:country return $i'

       PASSING XML_VALUE

                COLUMNS

                MODEL_NO VARCHAR2(240) PATH 'gs:model_no' ,

                COMPANY VARCHAR2(240) PATH 'gs:company' )  XTAB

Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Sep 2 2013
Added on Aug 2 2013
11 comments
5,800 views