H2 not creating/updating table in my Spring Boot app. Something's wrong with my Entity?

前端 未结 5 1944
遇见更好的自我
遇见更好的自我 2021-02-04 10:47

I want to keep some data in H2 database by making a CRUD repository, using Hibernate.

I can\'t get the database to store my entries whatsoever. Currently, I\'m trying to

5条回答
  •  北恋
    北恋 (楼主)
    2021-02-04 11:33

    Check if you main class(Spring boot application class) is able to scan the entities defined. This usually happens when the entities are in a different package than that of the main class.

提交回复
热议问题