[XQuery Talk Mailing List Archive Home] [By Date] [By Thread] [By Subject] [By Author] [Recent Entries] [Reply To This Message]

Time complexity of XQuery

Amitabh Ojha amitabhojha at rediffmail.com
Tue Feb 22 10:04:52 PST 2005

Dear members,

I  invite your attention to the following  XML document, data.xml :

<?xml version="1.0"?>





Also, pl see the following query :

let $x := doc (“data.xml”)/KMeansData/Object
for $y  in  $x
return ($y/X,  $y/Y)

If  “n”  be the  number  of  elements  named “Object” in the XML file above,  then  would  the  time complexity of the XQuery above be      O(n)  or  O(n^2) ?   

I am asking this question  because while using a particular XQuery Engine,  I did an experiment  with synthetically  generated  XML data for  upto n = 10,000.  While the time remained O (n) i.e linear upto n = 7,000 but after that,  I noticed a tendency towards O(n^2).

Will appreciate your comments/ help.

Amitabh Ojha

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://xquery.com/pipermail/talk/attachments/20050222/74bcd1cc/attachment.htm


Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
First Name
Last Name
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.