Skip to content

17주차 [JPA와 Querydsl] querydsl bulk연산#109

Open
ChaerinYu wants to merge 1 commit intono-study-no-future:ChaerinYufrom
ChaerinYu:bulk_querydsl
Open

17주차 [JPA와 Querydsl] querydsl bulk연산#109
ChaerinYu wants to merge 1 commit intono-study-no-future:ChaerinYufrom
ChaerinYu:bulk_querydsl

Conversation

@ChaerinYu
Copy link
Member

No description provided.

@ChaerinYu ChaerinYu added JPA JPA Querydsl Querydsl labels May 15, 2022
@ChaerinYu ChaerinYu linked an issue May 15, 2022 that may be closed by this pull request
Comment on lines 120 to 122
Copy link
Member Author

@ChaerinYu ChaerinYu May 16, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

when do we call entity manager flush and refresh methods. 
In brief - the flush call will issue SQL queries to update the database with the changes that have been done to the in memory entities. 
The refresh on the other hand pulls the entity state from the database and overwrites the in memory changes.

google에 Entitymanager refresh vs flush를 검색하면 나오는 정보입니다.
flush를 호출할 경우 메모리에 있는 entity 값들도 바꾸고 DB에도 UPDATE를 날려주는 SQL 쿼리를 호출하고
refresh를 호출할 경우 entity state를 DB에서 가져오고(pull) 메모리에 overwrites해준다고 합니다. 🙂

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

JPA JPA Querydsl Querydsl

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[JPA/Querydsl] Querydsl에서의 벌크연산

2 participants