JPA (4) 썸네일형 리스트형 [Spring Boot] java.sql.SQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 에러 에러 JPA, MySQL 사용 결과 에러 발생 java.sql.SQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 해결 1. MySQL 문법이 잘못 쓰인게 있는지 확인 2. 문법 잘못 쓰인게 없을 시, MySQL 예약어 사용 확인(Order 등등) 3. MySQL 예약어를 사용중일 경우 예약어 사이에 \" 추가 ex. \"(예약어)\" 변경 전 변경 후 [Spring Boot] Inferred type 'S' for type parameter 'S' is not within its bound; should extend 에러 Inferred type 'S' for type parameter 'S' is not within its bound; should extend 및 error: method save in interface CrudRepository cannot be applied to given types 에러 해결 JPA JpaRepository 매개변수 확인, 인터페이스 명 일치 확인 [Spring Boot] Can not issue data manipulation statements with executeQuery() 오류 JPA update, delete 사용시 @Transactional @Modifying 어노테이션 추가 @Transactional @Modifying @Query(value = "delete user where user_id = :userId", nativeQuery = true) void deleteId(Long userId); [Spring Boot] JPA Validation failed for query for method public abstract 오류 JPA Validation failed for query for method public abstract 에러 해결 JPA @Query 어노테이션을 사용하려면 쿼리문에 nativeQuery = true 로 설정 @Query(value = "SELECT *from user where user_id = :userId",nativeQuery = true) List findByPet(@Param("userId") Long userId); 이전 1 다음