Database not found, and IFEXISTS=true, so we cant auto-create it

后端 未结 17 3001
不思量自难忘°
不思量自难忘° 2020-12-15 06:20

I am getting error after opening the h2 database console. I enter database name but it is showing database not found error:

Database \"C:/Users/Barlek

17条回答
  •  隐瞒了意图╮
    2020-12-15 06:58

    Just append this to the application.properties file:

    spring.datasource.url=jdbc:h2:mem:testdb
    spring.datasource.driverClassName=org.h2.Driver
    spring.datasource.username=sa
    spring.datasource.password=
    spring.jpa.database-platform=org.hibernate.dialect.H2Dialect
    

提交回复
热议问题