[TS] repositoryCustom 파라미터가 없는 조회 기능 구현시 에러발생! => org.springframework.data.mapping.PropertyReferenceException: No property {method} found for type {class}
아래 내용은.. 결과적으로 문제 해결은 되지 않았다. 원인은 ArticleRepository.interface의 파일명이 잘못되어 발생한 것이다. repository, repositoryCustom, repositoryImpl... 과 같은 interface 및 class를 만들때는 이름에 오타가 없게 꼼꼼하게 확인하자. 아래 에러로그에서도 보이듯이 오타를 잡아주지 않는경우도 발생했다.ㅠ Entity의 마지막 순번값을 가져오는 간단한 조회 기능을 구현하다 에러가 발생했다... 결론부터 말하자면 JpaRepository를 구현하고 파라미터 없이 메소드를 작성할 때 반환값이 Entity가 아니라면 ex) DTO, String, Integer...etc (이건 내 추측이다. 정확한 원리는 추후에 추가예정.....
2023.04.17