Difference between flush() and commit() in hibernate?
Answers were Sorted based on User's Feedback
Answer / aslam mohammed c l
Flushing the Session simply makes the data that is currently
in the session synchronized with what is in the database.
However, just because you have flushed, doesn't mean the
data can't be rolled back.
Commit does flush the session, but it also ends the unit of
work.
To summarize commit does two things,
1. Commit internally does flush
2. Ends the unit of work (makes the changes permanent).
| Is This Answer Correct ? | 21 Yes | 2 No |
What is the difference between a vector & an array list?
Explain listiterator and methods in listiterator?
Difference between operator overloading and function overloading
0 Answers Tavant Technologies, Virtusa,
Which way a developer should use for creating thread, i.e. Sub classing thread or implementing runnable.
What is the purpose of a statement block?
what is meant wrapper classes?
Can we override final method?
What is the specification of ?CODEBASE? in an applet?
Differences between jdk 1.4 and 1.5
6 Answers SoftSol, TCS, Wipro,
What if I write static public void instead of public static void in java?
What are the steps that are followed when two computers connect through tcp?
what is the Diff. between Access Specifiers and Access Modifiers?
39 Answers BMC, Cyber Shot, Infosys, VTS, Wipro,