pom.xml:
<dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-data-jpa</artifactId> </dependency> <dependency> <groupId>com.h2database</groupId> <artifactId>h2</artifactId> <scope>runtime</scope> </dependency>
Add Hibernate and h2 into our pom.xml.
application.properties:
spring.datasource.url=jdbc:h2:file:~/theater
spring.datasource.driverClassName = org.h2.Driver
spring.datasource.username = sa
spring.datasource.password =
spring.jpa.properties.hibernate.hbm2dll.auto = update
Open: localhost:8080/h2-cosnole in browser: modify accordingly
When click connect: See the database UI