[단일 쿼리 실행 단축키] command + Enter [다중 쿼리 실행 단축키] command + ⬆️ + Enter
분류 전체보기
![](https://img1.daumcdn.net/thumb/R750x0/?scode=mtistory2&fname=https%3A%2F%2Fblog.kakaocdn.net%2Fdn%2F3Zbaq%2FbtsBKfAb6uC%2FJ3G0HRZoO4EYowSKjYLs90%2Fimg.png)
[상황] 팀 프로젝트를 이유로 git에서 pull을 받아와야 하는데 'Git Pull Failed' 메세지가 표시되어서 difference들을 고쳤다가 사용하지 않는 import문이 자동으로 삭제되어 'Git Pull Failed' 무한루프에 빠지게 되었다. [문제 해결 과정] 1. Settings - Editor - General - Auto Import - Java - Optimize imports on the fly 체크 해제 [문제 해결 완료] No differences 생겼쥬? pull 완료 !
![](https://img1.daumcdn.net/thumb/R750x0/?scode=mtistory2&fname=https%3A%2F%2Fblog.kakaocdn.net%2Fdn%2FvKhcH%2FbtsBMVOs0RN%2FBFDHEV3GglaJ1d9KakFtP0%2Fimg.png)
[상황] 'http://localhost:8080/order/orderJspPage'에서 '카드 결제' 버튼 체크 후 '결제하기' 버튼 누르면 다음과 같은 결제 API가 호출되고, 결제 완료 시, order.js에서 구성된 다음의 코드 일부로 인해 'http://localhost:8080/order/paySuccess.jsp'로 페이지가 넘어가야한다. //order.js //포트원 API : 카드 결제 요청 // [1-1] card 결제 API 호출 function payment(){ // 1. 포트원 계정 연동 및 API 연결 var IMP = window.IMP; IMP.init("imp******"); //포트원 API 계정 번호 //시크릿 키 처리 해야함 // 2-1. order.jsp 전달 된 ..
![](https://img1.daumcdn.net/thumb/R750x0/?scode=mtistory2&fname=https%3A%2F%2Fblog.kakaocdn.net%2Fdn%2FXV9VX%2FbtsBDNLqclH%2FxNu9X0yf1pyGKxpqkkggS1%2Fimg.png)
[상황] intellij 환경에서 mysql과 연결해야함, intellij 내 config.properties 파일 내 시크릿 키의 값을 바꾸고 DB와 연결시켜야함 spring.datasource.driverClassname = com.mysql.jdbc.Driver spring.datasource.url = jdbc:mysql://hostname:3306/new_schema spring.datasource.username = username spring.datasource.password = 1234 [문제 발생] Caused by: java.sql.SQLException: Access denied for user 'root'@'localhost' (using password: YES) DB에 연결 시..
![](https://img1.daumcdn.net/thumb/R750x0/?scode=mtistory2&fname=https%3A%2F%2Fblog.kakaocdn.net%2Fdn%2FbIn7gd%2FbtsBHSqG4KO%2FP0cEpR3s3QLAhxSTi32ELK%2Fimg.png)
[상황]1. (자바 스크립트) 기능 구현 목표결제 방법 버튼 3개 (카드, 계좌이체, 카카오페이) 중 카드 버튼 클릭 시,클릭 된 버튼 : 테두리 없앰, 배경 색상 '파란색', 글자 색상 '흰색'클릭 되지 않은 버튼 : 기존 디자인 유지 카카오페이, 계좌이체 버튼 위와 동일 [1차 기능 구현 완료]1. 메서드 구현// 결제 방법 '버튼' 클릭 시, 클린 된 버튼의 색상 변경function changeBtnColor(id) { var paymentBtns = document.getElementById(id); paymentBtns.style.border = "none"; paymentBtns.style.backgroundColor = "#0185FE"; paymentBtns.style..
![](https://img1.daumcdn.net/thumb/R750x0/?scode=mtistory2&fname=https%3A%2F%2Fblog.kakaocdn.net%2Fdn%2FbdT3VA%2FbtsBJf0jwXQ%2FkMroHgmb9D44kMSpfl8Jv0%2Fimg.png)
[에러 발생 : TypeError] order.js:113 Uncaught (in promise) TypeError: Cannot read properties of null (reading 'value') at payment (order.js:113:27) at HTMLInputElement. (order.js:12:9) payment @ order.js:113 (익명) @ order.js:12 [에러 원인] order.js의 'payment()' 내 파라미터 값의 데이터로 불러올 value 값을 불러오지 못함 당장 order.js 로 가자 [문제 해결 과정] 1. order.js function payment(){ var IMP = window.IMP; IMP.init("imp******"); //포트..
![](https://img1.daumcdn.net/thumb/R750x0/?scode=mtistory2&fname=https%3A%2F%2Fblog.kakaocdn.net%2Fdn%2FbitxcE%2FbtsBHQGoL0c%2F7KQ6E79G1Rh4eWgAki9uXk%2Fimg.png)
[상황] intellij에서 git 연동하면서 팀 프로젝트 진행 중, PR 완료 된 팀원들이 변경한 파일을 내 local 인텔리제이에 반영하기 위해 sync fork와 fetch 완료 후 Pull 클릭 [에러 메세지] Git Pull Failed Your local changes will be overwritten by merge. Commit, stash, or revert them to proceed. View them [문제 해결 과정] 1. View them 클릭 클릭하면 'Local Changes Prevent from Pull' 창으로 들어가진다. 그럼 달라진 부분이 있는 파일들이 보이게 되고, 그 파일들 안에서 '>>' 클릭하면 변경된다. 공백 부분도 다 반영해줘야함 하지만 반영하려고 해도 ..
![](https://img1.daumcdn.net/thumb/R750x0/?scode=mtistory2&fname=https%3A%2F%2Fblog.kakaocdn.net%2Fdn%2FBqezv%2FbtsBC4rNXw3%2F002ZvGTClLlxIWoHLQQSoK%2Fimg.png)
아앗 ! 이런 바보같은 실수를 ! [상황] 포트원 결제 API 요청하여 결제 완료 후 사용자의 신용카드 번호를 DB에 넣어야 함 [결제완료 카드 번호 데이터 넘기기 위해 아래 파일들 수정 과정] 1. StodDTO.java private int creditNum; 신용카드 번호 데이터가 저장 될 컬럼 추가, 생성자 / getter / setter / toString 추가 2. StodMapper.xml INSERT INTO payHty (odNo, id, lstPrice, payType, slrName, slrNum, bsnsName, indst, kind, slrPhone, creditNum, state, cardType, instlFees, slrAddr) VALUES (#{odNo}, #{id}, ..
Caused by: org.springframework.beans.factory.BeanCurrentlyInCreationException: Error creating bean with name 'stodDaoImpl': Requested bean is currently in creation: Is there an unresolvable circular reference? 스프링이 빈을 생성하는 과정에서 순환 참조가 발생했음을 나타내는 에러 문구이다. - 순환 참조란? 빈 A가 빈 B 의존, 빈 B가 빈 A 의존 => 빈을 초기화하는 동안 서로가 서로를 기다리게 되어 빈 생성 불가 문제 발생 - 해결 방법 순환 참조를 일으키는 빈들 사이의 의존성 제거 or 변경 에러 메세지 Caused by: org.s..
상황 : 주문 내역 테이블에 주문정보 데이터 삽입해야함 ['사용자 결제 완료 X' ▶️ '결제하기' 버튼 클릭 시 주문 내역 테이블에 주문정보 데이터 삽입] vs ['사용자 결제 완료 O' ▶️ 결제 완료 후 주문 내역 테이블에 주문정보 데이터 삽입] 데이터 삽입 시점은 사업의 특성과 요구 사항에 따라 달라짐. 비즈니스 목표와 전략에 따라 달라질 수 있으므로, 여러 관점에서 고려해보는게 좋음. 1. 데이터 정확성 2. 데이터 분석 3. 시스템 성능 위 3가지를 고려하여 삽입 시점 결정 ['사용자 결제 완료 X' ▶️ '결제하기' 버튼 클릭 시 주문 내역 테이블에 주문정보 데이터 삽입] 결제 완료하지 않은 주문 기록 시, 1. 데이터 정확성 status 컬럼에 '결제 대기 중', '주문 취소' 등의 상태 ..
![](https://img1.daumcdn.net/thumb/R750x0/?scode=mtistory2&fname=https%3A%2F%2Fblog.kakaocdn.net%2Fdn%2FbnnSkG%2Fbtsy8nAzP9s%2FKwXhEtcPlrs2sOu5E8yh0K%2Fimg.png)
mac terminal 접속 Spring 학습 위해 JAVA 11 버전이 필요한 상황, 원래 자바 버전은 8인 것 같다. brew update 업데이트 해주고 brew tap adoptopenjdk/openjdk brew search jdk jdk 찾은 후 brew install --cask adoptopenjdk11 jdk 11 버전 설치 /usr/libexec/java_home -v java가 설치된 경로 확인해주고 java -version 자바 버전 확인 설치 성공