HighTechTalks DotNet Forums  

Random access to large XML file

Dotnet XML microsoft.public.dotnet.xml


Discuss Random access to large XML file in the Dotnet XML forum.



Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old   
Yuriy Galanter
 
Posts: n/a

Default Random access to large XML file - 10-19-2007 , 08:44 AM






Hi,

I need to have random access to the XML document, selecting children may
depend of what parents are and vice versa, need to be able to go from deeper
level back to ancestors etc. So naturally XPath (and XPathDocument and
XPathNavigator) are the tools of choice. The problem is - how to deal with
large files? Entire document has to be loaded in memory and for files over
50Mb "out of memory" error is guaranteed.

Any idea how to have random access to large XML documents?

Thanks,

Yuriy.



Reply With Quote
  #2  
Old   
Oleg Tkachenko [MVP]
 
Posts: n/a

Default Re: Random access to large XML file - 10-28-2007 , 06:07 AM






Yuriy Galanter wrote:
Quote:
Hi,

I need to have random access to the XML document, selecting children may
depend of what parents are and vice versa, need to be able to go from deeper
level back to ancestors etc. So naturally XPath (and XPathDocument and
XPathNavigator) are the tools of choice. The problem is - how to deal with
large files? Entire document has to be loaded in memory and for files over
50Mb "out of memory" error is guaranteed.

Any idea how to have random access to large XML documents?
Well, 50 Mb isn't particularly huge document/. XPathDocument should
handle it ok, allocating about 200Mb or RAM.
As an alternative consider using XML data type in SQL Server 2005.


--
Oleg Tkachenko [XML MVP, MCPD]
http://www.tkachenko.com/blog | http://www.XmlLab.Net


Reply With Quote
Reply




Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.