java – Hibernate Session. Save() does not return a value?
•
Java
The following code will throw a conversion error
I'm new to hibernate Do not know why?
Solution
session. The return value of save () depends on your mapping Probably you have a short ID. try this:
System.out.println(session.save(object).getClass().getName());
Then you will see the type name
The content of this article comes from the network collection of netizens. It is used as a learning reference. The copyright belongs to the original author.
THE END
二维码