In this discussion about dom vs sax here
the chosen answer says:
DOM is easier to use but has an overhead of parsing the entire XML before you can start using it
I understood that in SAX, you dont need to parse the whole xml. Let us say that i am using Sax parser and i want to find a particular node. Now if the node is towards the end of the xml document, how will the sax parser find it without parsing the whole xml?
My other question is why in sax we cannot insert/delete a node? For some reason these answers are not obvious from the statement "sax is event based".