Software Development & Operating Systems

Notes on Software Development & Operating Systems

Posts about H2

Configure SpringBoot with H2 Database

Prerequisite: Go to and create a new SpringBoot project with Web, H2, and DevTools for dependencies. Import new project into STS (Spring Tools Suite). Additions to Open /src/main/resources/ and add the following lines: # H2 spring.h2.console.enabled=true spring.h2.console.path=/h2 # Datasource spring.datasource.url=jdbc:h2:file:~/test spring.datasource.username=sa spring.datasource.password= spring.datasource.driver-class-name=org.h2.Driver spring.jpa.database-platform=org.hibernate.dialect.H2Dialect spring.jpa.generate-ddl=true spring.jpa.hibernate.ddl-auto=validate NOTE: If you want your database [...]

Posted in h2, Hibernate, JPA, SpringBoot | Comments Off