Wow, O/T from me. Reading big XML files....
Wow, O/T from me. Reading big XML files....
Author
Discussion

HertsBiker

Original Poster:

6,443 posts

298 months

Monday 23rd December 2002
quotequote all
sorry, had to do an off topic post.

I need to read in a humungeous XML file. Any easy way of doing this? small files seem ok, eg fast enough, but a big 'un is causing problems....

ta.

Carl

plotloss

67,280 posts

297 months

Monday 23rd December 2002
quotequote all

sorry, had to do an off topic post.

I need to read in a humungeous XML file. Any easy way of doing this? small files seem ok, eg fast enough, but a big 'un is causing problems....

ta.

Carl


Define big, define problems?

Matt.

miniman

29,793 posts

289 months

Monday 23rd December 2002
quotequote all
You could try TextPad for simple viewing with line numbers etc, or XML Spy which gives you a good structured tree view which you can expand and collapse.

www.textpad.com
www.xmlspy.com

Both have free eval versions.

mr_tony

6,350 posts

296 months

Monday 23rd December 2002
quotequote all
Carl, you don't say what you're trying to do exactly.

If you're just trying to load a large XML file in in Windows (i.e. into explorer or VB etc) the it's probably using the DOM object model. This is well know to be inefficient at coping with large documents.

SAX (a different type of document processor) is really better for really massive XML documents because it doesn't try to hold the whole document in memory at once.

[link]www.xml.com/pub/a/2002/03/06/efficient.html
[/link]

Other than that more RAM helps quite a bit in my experience


mr_tony

6,350 posts

296 months

Monday 23rd December 2002
quotequote all
you can tell us XML guys are busy today

HertsBiker

Original Poster:

6,443 posts

298 months

Monday 23rd December 2002
quotequote all
I've got to process a large customer file with VB, as opposed to viewing it. I'll have a play around a bit more. Thanks!
Carl

plotloss

67,280 posts

297 months

Monday 23rd December 2002
quotequote all
Carl,

If you are using the MSXML Parser at version 4.0 then if you can possibly get hold of it and if your software doesnt explicitly use version 4.0 then try to get hold of version 3.0 as its a lot tighter and consequently quicker.

If on the other hand this app is slow with MSXML 3.0 then dont get 4.0 as it will be slower!

Matt.

miniman

29,793 posts

289 months

Monday 23rd December 2002
quotequote all
Ahh, you mean that type of reading a file. In that case, what they all said