Why does Spring-data-jdbc not save my Car object?

This is not related to transactions not working. Instead, it’s about Spring Data JDBC considering your instance an existing instance that needs updating (instead of inserting). You can verify this is the problem by activating logging for org.springframework.jdbc.core.namedparam.NamedParameterJdbcTemplate. You should see an update but no insert. By default, Spring Data JDBC considers an entity as … Read more