session.save(userHBM);
session.flush();
}
else {
try {
UserHBM userHBM = (UserHBM)session.load(UserHBM.class,
user.getPrimaryKey());
userHBM.setCompanyId(user.getCompanyId());
userHBM.setPassword(user.getPassword());
userHBM.setPasswordEncrypted(user.getPasswordEncrypted());
userHBM.setPasswordExpirationDate(user.getPasswordExpirationDate());