Blog

Non-terminating-decimal-expansion

In one of my recent projects, I had to use java.math.BigDecimal to divide two values. I had to use BigDecimal instead of double as this was a Billing application and required the results to be accurate. However, after running the application, I encountered the...

Read Xml File In Java Using SAX Parser

In this blog, I will show you how to read an XML file via Java SAX parser. SAX Parsers are faster than DOM parser because it doesn’t load complete XML into memory and read xml document sequentially. SAXParser are little bit confusing in start but if you are working on...

Read XML File In Java

read xml file in java In this blog, I will show you how to read an XML file via DOM XML parser. DOM parser parses the entire XML document and loads it into memory; then models it in a “TREE” structure for easy traversal or manipulation. In short, it turns a XML file...

Using Projections in Hibernate

Hi Guys, I am back with another post titled “Using Projections in Hibernate”. When we deal with large objects(containing multiple attributes) we use Projections to select only a subset of attributes of an object. It helps in avoiding unnecessary column...