Error 10

Uncaught (in promise) TypeError: Cannot read properties of undefined (reading '0')

// scriptconst { data: testData, isLoading } = useQuery([""], () => fetchGetData(id), { enabled: Boolean(activityId.value), },)// tamplate{{ testData[index]?.name }} 1. enabled  옵션을 활성화한 상태에서, 조건에 맞지 않아 useQuery가 데이터를 가져오지 않는 경우 => isLoading이 계속 true인 상태로 변하지 않음 2. useQuery가 데이터를 가져오지 않았기 때문에, 초기 데이터가 undefined 상태에서 화면에 데이터를 렌더링할 경우 => Uncaught (in promise) TypeError: Ca..

Error 2025.01.20

[에러] java.lang.IndexOutOfBoundsException: Index: 0, Size: 0

프로젝트 메인페이지에서 내 위치 반경 1km 시용가능한 충전소 찾기 기능 보완 java.lang.IndexOutOfBoundsException: Index: 0, Size: 0 에러가 떠서 보니 Controller에 문제가 있던 걸 발견했다. 좌표 값을 받아오는 데에서 문제가 생겼다. mv.addObject("lat",stationList.get(0).getMap_latitude()); mv.addObject("longt",stationList.get(0).getMap_longtude()); 리스트의 사이즈를 체크해 해결했다. if( stationList.size()!=0){ mv.addObject("lat",stationList.get(0).getMap_latitude()); mv.addObject("..

Error 2023.03.02

이클립스 sts 프로젝트 에러표시(팔간 엑스 표시) 해결하기

새로 import한 프로젝트에 엑스 표시가 떠서 이것저것 검색해보고 시도해본 결과를 기록해보려고 한다. 프로젝트 우클릭 - Properties - Java Build Path - Libraries혹은 프로젝트 우클릭 - Properties - Build Path - Configure Build Path - Libraries 의 Modulpath확인 기존 프로젝트 import한 프로젝트 기존 프로젝트 설정에 맞춰주었다. 결과

Error 2023.01.07

[에러] mybatis - java.lang.illegalargumentexception: mapped statements collection does not contain value for

1. mapper.xml에 정의한 id가 다른 경우 java(Service or DAO) 파일과 mapper.xml 파일 비교하기 sqlSession.insert(com.project.service.insert, board); 2. Parameter와 bean의 필드명이 틀린 경우 3. namespace가 다른 경우 java(Service or DAO)파일과 mapper.xml 파일 비교하기 sqlSession.insert(com.project.service.insert, board); 4. mybats설정파일에 정의한 namespace확인하기 정의되어 있는지, 스펠링이 틀리지 않았는지 확인하기 5. mapper에 정의된 namespace명칭이 같은 Application 내에 중복된 경우 참고 및 출처 ..

Error 2023.01.05

[에러] org.apache.ibatis.executor.ExecutorException: A query was run and no Result Maps were found for the Mapped Statement 'com.hn.erp.board.selectMyList'. It's likely that neither a Result Type nor a Result Map was specified.

SEVERE: 경로 [/mvc]의 컨텍스트 내의 서블릿 [appServlet]을(를) 위한 Servlet.service() 호출이, 근본 원인(root cause)과 함께, 예외 [Request processing failed; nested exception is org.mybatis.spring.MyBatisSystemException: nested exception is org.apache.ibatis.executor.ExecutorException: A query was run and no Result Maps were found for the Mapped Statement 'com.hn.erp.board.selectMyList'. It's likely that neither a Result Typ..

Error 2022.12.11

[에러] ORA-00911: invalid character

invalid character : 부적합한 문자 원인 : 쿼리문에 적합하지 않은 문자가 들어감 해결방법 : 오타와 이상한 문자가 들어가진 않았는지 확인한다. 문제가 된 sql문 ............ "select * from board;"; 아주 간단하고 기본적인 코드에서조차 이렇게 문제가 발생할 수 있다... 세미콜론 하나로 인해서.. 분명 확인하고 완벽하게 적었다고 생각했는데.... 복사 붙여넣기의 폐해(?)로... 이클립스 쿼리문에 세미콜론이 들어가서 에러가 나는 것이었다. 정말 어이없어 .... 담뱃재, 가스불, 코드선처럼(?) 다시 확인하고 또 확인하는 습관을 가지자 ..

Error 2022.11.18