I\'m trying to implement a partial update of the Manager entity based in the following:
Entity
public class Manager {
private int id;
private Str
You can write custom update query which updates only particular fields:
@Override
public void saveManager(Manager manager) {
Query query = sessionFactory.getCurrentSession().createQuery("update Manager set username = :username, password = :password where id = :id");
query.setParameter("username", manager.getUsername());
query.setParameter("password", manager.getPassword());
query.setParameter("id", manager.getId());
query.executeUpdate();
}