Also i am not aware of that 'SAX parsers may return all contiguous character data in a single chunk, or they may split it into several chunks'?That's surprising. It's right there in the Javadoc where I found it.
Could you please give your idea regarding how to solve this?When you get a startElement(), push the name onto a name stack, push the attributes onto an attributes stack if you need them, and push a new StringBuffer onto a StringBuffer stack. When you get characters(), append them to the StringBuffer at the top of the stack. When you get an endElement(), pop the name off the name stack, pop the StringBuffer off its stack, convert to a String, then the value of the element with that name is that string. If you need the attributes pop them off their stack too.