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 |
Tags
- 인프런
- SpringBoot
- 알고리즘
- http
- Thymeleaf
- 그리디
- Greedy
- pointcut
- 김영한
- Android
- Spring Boot
- jpa
- 백준
- java
- JPQL
- AOP
- 스프링
- 스프링 핵심 원리
- QueryDSL
- transaction
- Servlet
- springdatajpa
- 스프링 핵심 기능
- db
- kotlin
- Proxy
- spring
- 자바
- JDBC
- Exception
Archives
- Today
- Total
목록JPAExpressions (1)
개발자되기 프로젝트
서브쿼리, SubQuery
1. 서브쿼리 쿼리안에 쿼리 넣기 com.querydsl.jpa.JPAExpressions 사용 2. 예제1 : 나이가 가장 많은 회원 조회 /** * 나이가 가장 많은 회원 조회 */ @Test public void subQuery(){ //서브쿼리는 바깥에 있는 alias랑 겹치면 안됨. //QMember새로 만들어줘야함. QMember memberSub = new QMember("memberSub"); List result = queryFactory .selectFrom(member) .where(member.age.eq( JPAExpressions .select(memberSub.age.max()) .from(memberSub) )) .fetch(); assertThat(result).extrac..
인프런/[인프런] QueryDsl
2021. 9. 2. 23:51