I believe the only valid time to call sessionA.update(obj) is when the obj has been loaded from a different session, say sessionB. Calling session.flush() will flush your changes to the database. so
Code:
PointInfo pi4 = (PointInfo)sess.load(PointInfo.class,new Integer(2));
pi4.setDescription("Description");
sess.flush();
sess.close();
Should write the differences.
use update in the following situation
Code:
PointInfo pi4 = (PointInfo) sessionA.load(PointInfo.class,new Integer(2));
pi4.setDescription("Description");
sessionA.flush(); sessionA.close();
....
sessionB.update(pi4);
sess.flush();
sess.close();
You would do this between states in a web application for instance where pi4 was loaded on one page and updated on another server interaction.