When setting the flag spring.datasource.initialize=false, the data-${platform}.sql and data.sql files are always loaded.
This comes after the refactoring "Defer SQL initialization to fit with JPA better" that fixes "gh-1006" (done on june 2nd, commit id 49a09c807c437ad9b668652a89ea70c122aff89a)
This behaviour is different than specified in the chpater "63.3 Initialize a database using Spring JDBC" of the documentation.
I agree this is a bug, but I think it only happens if you a) use Hibernate and b) set ddlAuto to something non-null. I suggest not setting spring.jpa.hibernate.ddlAuto.
Most helpful comment
I agree this is a bug, but I think it only happens if you a) use Hibernate and b) set ddlAuto to something non-null. I suggest not setting
spring.jpa.hibernate.ddlAuto.