Liutauras Vilda wrote:
Have you tried to download any other text editor as Notepad++, it should be able to handle files up to 2GB. Search for a different editor, surely there is some on Windows too.
Tim Holloway wrote:I suspect that you are running a 32-bit JVM.
In any event, I ALSO suspect that you're attempting to process a 1.7 GB file by loading the entire freaking thing into memory.
And that there's nothing necessarily wrong with the XML other than that there's simply too much of it.
That much data rarely needs to be (or should be!) processed in RAM directly. There are other ways to handle XML that allow you to process the XML as a stream instead of as one big indigestible lump. Consider using a SAX or STaX parser instead, and it you actually want to do complex things, you might store the received data into a database where it can be more efficiently accessed.
Rob Spoor wrote:Without seeing line 268 we cannot see what's going wrong. All I can tell you is what the message says - you have an element that expects only text content but instead contains a nested element.
Tim Cooke wrote:I'm not sure how you could view that on a Windows machine. Perhaps someone else will be able to help with that.
On a *NIX machine I would suggest using sed to print out a small range of lines from the whole file. I don't know if you have sed on Windows, or some equivalent even.
Tim Cooke wrote:
Alex Chun wrote:Sorry, I paste picture here. It's only a part of xml file.
Please don't do that. I cannot read anything in that image.
Just paste the part of the xml relevant to the error. What's on and around line 268?
Tim Cooke wrote:Please don't use images to show errors. Please copy and paste the error as text into your posts.
Also, show the xml that is being parsed.