最佳答案
How do I specify database schema used by Spring Boot? I am using default hibernate (=default) and postgres (but i hoping for a generic solution). I know how to specify JDBC URL:
spring.datasource.url=jdbc:postgresql:db_name
But unfortunately postgresql does not allow to specify schema in JDBC URL. I know that there is hibernate property hibernate.default_schema
, so I was hoping that one of the following properties will work:
hibernate.default_schema=schema
spring.hibernate.default_schema=schema
spring.jpa.hibernate.default_schema=raw_page
But unfortunately neither of them seems to have any result.