• 2021-04-14
    以下程序代码对Customer的name属性修改了两次:
    tx = session.beginTransaction();
    Customer customer=(Customer)session.load(Customer.class,
    new Long(1));
    customer.setName("Jack");
    customer.setName("Mike");
    tx.commit();
    执行以上程序,Hibernate需要向数据库提交几条update语句?