본문 바로가기
개발언어/Java

[Spring jpa] could not extract ResultSet; SQL [n/a] error

by 공장장코난 2022. 2. 1.

SpringBoot 기반에서 JPA를 이용한 restful api를 작업하는 과정에서 심심찮게 아래 오류가 종종 발생한다. 

could not extract ResultSet; SQL [n/a]
org.hibernate.exception.SQLGrammarException: could not extract ResultSet

원인은 코드로 작성된 entity와 db table의 동기화가 맞지 않아 발생한 오류로 나의 경우엔 assign_min_battery column이 없어 발생한 오류다.
"동기화 후 다시 작업 시작~"