Spring

[Request processing failed; nested exception is java.lang.NullPointerException] with root cause

codeManager 2022. 5. 30. 18:49
반응형

 

Servlet.service() for servlet [dispatcherServlet] in context with path [] threw exception [Request processing failed; nested exception is java.lang.NullPointerException] with root cause

 

스프링 개발 중에 이런 에러메시지를 볼 때가 있습니다.

 

이유

NullPointerException이 발생한 이유는 Query 조건 중에 Null이 들어갔기 때문입니다.

 

 

해결방법

쿼리에 Null이 안들어가도록 수정해준다.

 

 

반응형