diff --git a/xml-2/src/main/java/com/baeldung/xml/validation/XmlValidator.java b/xml-2/src/main/java/com/baeldung/xml/validation/XmlValidator.java index 7d8f531bfa..57eccab193 100644 --- a/xml-2/src/main/java/com/baeldung/xml/validation/XmlValidator.java +++ b/xml-2/src/main/java/com/baeldung/xml/validation/XmlValidator.java @@ -44,7 +44,7 @@ public class XmlValidator { try { validator.validate(new StreamSource(getFile(xmlPath))); } catch (SAXParseException e) {} - xsdErrorHandler.getExceptions().forEach(e -> LOGGER.info(e.getMessage())); + xsdErrorHandler.getExceptions().forEach(e -> LOGGER.info(String.format("Line number: %s, Column number: %s. %s", e.getLineNumber(), e.getColumnNumber(), e.getMessage()))); return xsdErrorHandler.getExceptions(); }