public void update(Employee bean, JdoPMF pmf) {
/* 1. Get the PersistenceManager */
PersistenceManager persistenceManager = pmf.getPersistenceManager();
Employee e = new Employee();
e.setId(bean.getId());
PersistenceBroker broker = PersistenceBrokerFactory.defaultPersistenceBroker();
Identity oid = new Identity(e, broker);
Employee b = new Employee();
// 2. start transaction
persistenceManager.currentTransaction().begin();
// 3. Get the Object based on the primary key
b = (Employee) persistenceManager.getObjectById(oid, false);
// 4. Copy data from bean