I am using Spring Boot 2.2.4 and hibernate 5.3.1. I am seeing the following error being thrown by
could not execute statement; SQL [n/a];
constraint [null]; nested exception is org.hibernate.exception.ConstraintViolationException:
could not execute statement at
I am able to catch the exception. How do I see the SQL and parameters that caused the exception ? I see I can log all sql and parameters as shown here: How can I log SQL statements in Spring Boot?
But I would specifically like to see the ones causing the exception, and not all.