will the Query object always take preference over EntityManager on setting flushmode?
posted 9 years ago
I have a question regarding the flush mode setting on either the EntityManager or the Query object.
since the setFlushMode method is available in both EntityManager and Query interface, then which one takes the preference?
For example, If the EntityManager has been configured with setFlushMode(FlushModeType.AUTO) and the Query object has been called with setFlushMode(FlushModeType.COMMIT), then will the preference goes to the Query object? (COMMIT in this case???)