Notice
Recent Posts
Recent Comments
Link
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | |||
5 | 6 | 7 | 8 | 9 | 10 | 11 |
12 | 13 | 14 | 15 | 16 | 17 | 18 |
19 | 20 | 21 | 22 | 23 | 24 | 25 |
26 | 27 | 28 | 29 | 30 | 31 |
Tags
- 스프링
- spring
- Android
- 백준
- QueryDSL
- JDBC
- Proxy
- Exception
- 그리디
- kotlin
- Thymeleaf
- Greedy
- 김영한
- http
- 알고리즘
- java
- transaction
- 스프링 핵심 기능
- springdatajpa
- db
- 스프링 핵심 원리
- 인프런
- pointcut
- Servlet
- jpa
- Spring Boot
- AOP
- JPQL
- 자바
- SpringBoot
Archives
- Today
- Total
목록fetchone (1)
개발자되기 프로젝트
결과 조회
1. query 결과 조회 방법 fetch의 사전적 의미 : 가져오다. fetch() : 리스트 조회, 데이터 없으면 빈 리스트 반환 fetchOne() : 단 건 조회 결과가 없으면 : null 결과가 둘 이상이면 : com.querydsl.core.NonUniqueResultException fetchFirst() : limit(1).fetchOne() fetchResults() : 페이징 정보 포함, total count 쿼리 추가 실행 fetchCount() : count 쿼리로 변경해서 count 수 조회 2. 예제 fetchResults()의 경우 getResults()를 통해 contents를 꺼낼 수 있음. @Test public void resultFetch(){ List fetch = ..
인프런/[인프런] QueryDsl
2021. 9. 1. 23:19