SlideShare a Scribd company logo
1 of 121
Download to read offline
QueryDSL
type-safe
 Query
발표자
 :
 김영한
12년	 12월	 7일	 금요일
목차
•문제
•JPA
 Query
•QueryDSL?
•QueryDSL-JPA
•기능
 살펴보기
•Spring
 Data
 JPA
 +
 Querydsl
12년	 12월	 7일	 금요일
문제
12년	 12월	 7일	 금요일
긴급
 요구사항
•검색조건
 추가
•나이
•이름
•퇴근시간
 10분전...
12년	 12월	 7일	 금요일
기능
 추가
이정도는 발로
만들어 주지
12년	 12월	 7일	 금요일
쿼리
 추가
String
 sql
 =
“select
 *
 from
 member”
 +
“where
 name
 like
 ?”
 +
“and
 age
 between
 ?
 and
 ?”
12년	 12월	 7일	 금요일
컴파일
 완료
12년	 12월	 7일	 금요일
배포
 완료
12년	 12월	 7일	 금요일
퇴근
 완료
12년	 12월	 7일	 금요일
버그
 발생
12년	 12월	 7일	 금요일
리콜
 완료??
그럴리가
 없어
분명
 빌드는
 성공했어!
12년	 12월	 7일	 금요일
버그
String
 sql
 =
“select
 *
 from
 member”
 +
“where
 name
 like
 ?”
 +
“and
 age
 between
 ?
 and
 ?”
[합치면]
“select
 *
 from
 memberwhere
 name
 
like
 ?and
 age
 between
 ?
 and
 ?”
12년	 12월	 7일	 금요일
QUERY의
 문제점
•QUERY는
 문자,
 Type-check
 불가능
•실행해
 보기
 전까지
 작동여부
 확인
 불가
12년	 12월	 7일	 금요일
에러는
 크게
 2가지
•컴파일
 에러
 (좋은
 에러)
•런타임
 에러
 (나쁜
 에러)
12년	 12월	 7일	 금요일
도메인
 고수?
전
 SQL을
 빨리
 작성하기
 
위해
 컬럼명
 정도는
 모두
 
외운답니다.
SELECT
 NAME,
 AGE
 ..
12년	 12월	 7일	 금요일
SQL...
•만약
 SQL이
 Class처럼
 Type이
 있고
 Java코
드로
 작성
 할
 수
 있다면?
•type-safe
12년	 12월	 7일	 금요일
Type-safe
•컴파일시
 에러
 체크
 가능
•Code-assistant

More Related Content

Viewers also liked

몽고디비사용자교육2일차 v0.5
몽고디비사용자교육2일차 v0.5몽고디비사용자교육2일차 v0.5
몽고디비사용자교육2일차 v0.5
seung-hyun Park
 
R과sql비교 퀵하게보기
R과sql비교 퀵하게보기R과sql비교 퀵하게보기
R과sql비교 퀵하게보기
seung-hyun Park
 
BeLAUNCH2014 x HACKATHON week 3
BeLAUNCH2014 x HACKATHON week 3BeLAUNCH2014 x HACKATHON week 3
BeLAUNCH2014 x HACKATHON week 3
Chan Lee
 

Viewers also liked (20)

Ksug2015 - JPA2, JPA 기초와매핑
Ksug2015 - JPA2, JPA 기초와매핑Ksug2015 - JPA2, JPA 기초와매핑
Ksug2015 - JPA2, JPA 기초와매핑
 
spring data jpa 간단한 튜토리얼
spring data jpa 간단한 튜토리얼spring data jpa 간단한 튜토리얼
spring data jpa 간단한 튜토리얼
 
Jpa 잘 (하는 척) 하기
Jpa 잘 (하는 척) 하기Jpa 잘 (하는 척) 하기
Jpa 잘 (하는 척) 하기
 
Mobile app security nov 2015
Mobile app security nov 2015 Mobile app security nov 2015
Mobile app security nov 2015
 
Querydsl overview 2014
Querydsl overview 2014Querydsl overview 2014
Querydsl overview 2014
 
몽고디비사용자교육2일차 v0.5
몽고디비사용자교육2일차 v0.5몽고디비사용자교육2일차 v0.5
몽고디비사용자교육2일차 v0.5
 
R과sql비교 퀵하게보기
R과sql비교 퀵하게보기R과sql비교 퀵하게보기
R과sql비교 퀵하게보기
 
Query DSL In Elasticsearch
Query DSL In ElasticsearchQuery DSL In Elasticsearch
Query DSL In Elasticsearch
 
보안 위협과 악성코드 분석 기법
보안 위협과 악성코드 분석 기법보안 위협과 악성코드 분석 기법
보안 위협과 악성코드 분석 기법
 
OOPS in javascript
OOPS in javascriptOOPS in javascript
OOPS in javascript
 
Why javaScript?
Why javaScript?Why javaScript?
Why javaScript?
 
Hibernate start (하이버네이트 시작하기)
Hibernate start (하이버네이트 시작하기)Hibernate start (하이버네이트 시작하기)
Hibernate start (하이버네이트 시작하기)
 
Big query at GDG Korea Cloud meetup
Big query at GDG Korea Cloud meetupBig query at GDG Korea Cloud meetup
Big query at GDG Korea Cloud meetup
 
BeLAUNCH2014 x HACKATHON week 3
BeLAUNCH2014 x HACKATHON week 3BeLAUNCH2014 x HACKATHON week 3
BeLAUNCH2014 x HACKATHON week 3
 
Computer Vision - Artificial Intelligence
Computer Vision - Artificial IntelligenceComputer Vision - Artificial Intelligence
Computer Vision - Artificial Intelligence
 
미티어 리엑티비티 ( reactivity of meteor )
미티어 리엑티비티 ( reactivity of meteor ) 미티어 리엑티비티 ( reactivity of meteor )
미티어 리엑티비티 ( reactivity of meteor )
 
Javascript and Web Performance
Javascript and Web PerformanceJavascript and Web Performance
Javascript and Web Performance
 
3. collection
3. collection3. collection
3. collection
 
1. 미티어의 폴더구조
1. 미티어의 폴더구조1. 미티어의 폴더구조
1. 미티어의 폴더구조
 
5.router
5.router5.router
5.router
 

Recently uploaded

AI Mastery 201: Elevating Your Workflow with Advanced LLM Techniques
AI Mastery 201: Elevating Your Workflow with Advanced LLM TechniquesAI Mastery 201: Elevating Your Workflow with Advanced LLM Techniques
AI Mastery 201: Elevating Your Workflow with Advanced LLM Techniques
VictorSzoltysek
 
TECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providerTECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service provider
mohitmore19
 

Recently uploaded (20)

Introducing Microsoft’s new Enterprise Work Management (EWM) Solution
Introducing Microsoft’s new Enterprise Work Management (EWM) SolutionIntroducing Microsoft’s new Enterprise Work Management (EWM) Solution
Introducing Microsoft’s new Enterprise Work Management (EWM) Solution
 
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time ApplicationsUnveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
 
A Secure and Reliable Document Management System is Essential.docx
A Secure and Reliable Document Management System is Essential.docxA Secure and Reliable Document Management System is Essential.docx
A Secure and Reliable Document Management System is Essential.docx
 
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdfThe Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
 
Software Quality Assurance Interview Questions
Software Quality Assurance Interview QuestionsSoftware Quality Assurance Interview Questions
Software Quality Assurance Interview Questions
 
Direct Style Effect Systems - The Print[A] Example - A Comprehension Aid
Direct Style Effect Systems -The Print[A] Example- A Comprehension AidDirect Style Effect Systems -The Print[A] Example- A Comprehension Aid
Direct Style Effect Systems - The Print[A] Example - A Comprehension Aid
 
How to Choose the Right Laravel Development Partner in New York City_compress...
How to Choose the Right Laravel Development Partner in New York City_compress...How to Choose the Right Laravel Development Partner in New York City_compress...
How to Choose the Right Laravel Development Partner in New York City_compress...
 
AI Mastery 201: Elevating Your Workflow with Advanced LLM Techniques
AI Mastery 201: Elevating Your Workflow with Advanced LLM TechniquesAI Mastery 201: Elevating Your Workflow with Advanced LLM Techniques
AI Mastery 201: Elevating Your Workflow with Advanced LLM Techniques
 
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
 
Right Money Management App For Your Financial Goals
Right Money Management App For Your Financial GoalsRight Money Management App For Your Financial Goals
Right Money Management App For Your Financial Goals
 
Exploring the Best Video Editing App.pdf
Exploring the Best Video Editing App.pdfExploring the Best Video Editing App.pdf
Exploring the Best Video Editing App.pdf
 
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdfLearn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
 
VTU technical seminar 8Th Sem on Scikit-learn
VTU technical seminar 8Th Sem on Scikit-learnVTU technical seminar 8Th Sem on Scikit-learn
VTU technical seminar 8Th Sem on Scikit-learn
 
TECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providerTECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service provider
 
Microsoft AI Transformation Partner Playbook.pdf
Microsoft AI Transformation Partner Playbook.pdfMicrosoft AI Transformation Partner Playbook.pdf
Microsoft AI Transformation Partner Playbook.pdf
 
Unlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language ModelsUnlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language Models
 
Azure_Native_Qumulo_High_Performance_Compute_Benchmarks.pdf
Azure_Native_Qumulo_High_Performance_Compute_Benchmarks.pdfAzure_Native_Qumulo_High_Performance_Compute_Benchmarks.pdf
Azure_Native_Qumulo_High_Performance_Compute_Benchmarks.pdf
 
AI & Machine Learning Presentation Template
AI & Machine Learning Presentation TemplateAI & Machine Learning Presentation Template
AI & Machine Learning Presentation Template
 
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
Shapes for Sharing between Graph Data Spaces - and Epistemic Querying of RDF-...
 
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
 

Querydsl