I've read some articles on advantages of using SAX parser for parsing XML files in java over using DOM. The one which appeals me the most (as discussed here) is that
Sax is suitable for large XML File and The SAX parser does not loads the XML file as a whole in the memory.
But now as i've written a parser using SAX to derive the entities out of an XML file for a large file of almost 1.4 GB it generates the following Exception.
org.xml.sax.SAXParseException; lineNumber: 1; columnNumber: 1; The parser has encountered more than "64,000" entity expansions in this document; this is the limit imposed by the application.
What is the problem with the memory if the file as whole is not loaded in the memory.
How can i resolve the issue?