본문 바로가기

logs

(27)
java] arraylist에 중복 row 제거하기 List 결과List = new ArrayList(new LinkedHashSet(돌릴List)); HashSet은 중복된 애를 넣으려고 하면 이미 있으니까 더 안들어감 LinkedHashSet 과 HashSet의 차이점은 LinkedHashSet은 데이터를 넣은 순서가 보장된다는 것. ==> LinkedHashSet에 1 2 3 4 5 1 6 을 넣으면1 2 3 4 5 6 으로 출력되며 HashSet은 1 2 3 4 5 6이 출력되지만 출력되는 순서는 보장되지 않음! 다른 방법 (속도 보장 못함)List deduped = list.stream().distinct().collect(Collectors.toList()); 정렬은 .sort() 또 다른 방법 출처 : https://www.dotnetperl..
mysql] function 생성시 This function has none of DETERMINISTIC,~ 오류 해결법 디비를 덤프뜨던 중 function을 내보내기 하자 아래와 같은 오류가 발생했다. ERROR 1418 (HY000): This function has none of DETERMINISTIC, NO SQL, or READS SQL DATA in its declaration and binary logging is enabled (you *might* want to use the less safe log_bin_trust_function_creators variable) 개발DB에서는 잘 사용하고 있던 것이므로 펑션에는 문제가 없을텐데.... 검색해보자 새로 구축한 DB에는 function에 대한 권한이 안되어있는 모양...ㅠㅠㅠ 해결방법 1.show global variables like 'log_bin_t..
mysql] putty로 linux에 있는 mysql 접속하기 1. Putty실행 * 주소는 http:// 이런거 빼고 아이피만 입력할것 ex) 192.168.0.1 2. 로그인 3. mysql 설치확인rpm -qa | grep mysql 4. mysql 설치위치 확인find / -name mysql 5. mysql 접속mysql -u user명 -h 주소 -p 디비명 6. user의 pw입력 7. 성공했다면 아래와 같이 나옴Reading table information for completion of table and column namesYou can turn off this feature to get a quicker startup with -A Welcome to the MySQL monitor. Commands end with ; or \g.Your MyS..
root-context.xml, servlet-context.xml 를 context-*.xml, *-servlet.xml 로 바꿔준 뒤로 404오류 환장하는 줄 알았다. 콘솔에도 로그가 안찍히고 페이지 호출하면 404 에러만 뜨고..... 의심되는 부분이 넘나 여러군데여서 헤매다가 아예 Controller에 들어오지도 못하는 것 같아서bean 생성에 문제가 있으리라 짐작했음 context-common.xml이랑 action-servlet.xml에 bean 생성해주는 부분 범위 설정이 잘 되어있는지 확인... 문제가 있어서 수정했음 그 뒤 아래 블로그를 참고하여 bean이 잘 생성되었는지 Spring Explorer 윈도우에서 확인했음 결국 잘 돌아감 ㅠㅠㅠㅠㅠㅠㅠㅠㅠㅠㅠㅠㅠ http://ddoong2.com/946 http://toriworks.tistory.com/84
없어진 @RequestMapping 이 문제가 있다는 오류문구... 없앤지 오래인 requestmapping 값들... resource 값들이 문제가 있따고 자꾸 뜸... 로컬에서는 같은 소스로 문제가 없는데 서버에 올렸을때만 저렇게 뜨고, 당연히 소스에는 comCodeList.do 이런거 있지도 않음....서버에 빈 생성된 부분이 초기화가 안되는게 문제인거 같은데 서버 초기화 하는 방법도 안나오구... org.springframework.beans.factory.BeanCreationException: Error creating bean with name "org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerMapping#0": Initialization of bean failed; ne..
### Cause: java.sql.SQLException: Value '0000-00-00' can not be represented as java.sql.Date ### Cause: java.sql.SQLException: Value '0000-00-00' can not be represented as java.sql.Date 해결방법 :root-context.xmldataSource url 끝에 ?zeroDateTimeBehavior=convertToNull 추가
tiles 붙이기 1. pom.xml안에2.2.2 org.apache.tilestiles-core${org.apache.tiles-version}org.apache.tilestiles-servlet${org.apache.tiles-version}org.apache.tilestiles-jsp${org.apache.tiles-version}xercesxercesImpl2.11.0
java.sql.SQLException: No database selected java.sql.SQLException: No database selected 해결방법 : root-context.xml