17주차 [JPA와 Querydsl] querydsl bulk연산#109
Open
ChaerinYu wants to merge 1 commit intono-study-no-future:ChaerinYufrom
Open
17주차 [JPA와 Querydsl] querydsl bulk연산#109ChaerinYu wants to merge 1 commit intono-study-no-future:ChaerinYufrom
ChaerinYu wants to merge 1 commit intono-study-no-future:ChaerinYufrom
Conversation
ChaerinYu
commented
May 16, 2022
JPA와Querydsl/bulk_in_querydsl.md
Outdated
Comment on lines
120
to
122
Member
Author
There was a problem hiding this comment.
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해준다고 합니다. 🙂
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.