如果你的entity bean用的是local interface,那么你的访问代码应该如下:Context ctx =new InitialContext();
itemHome = (ItemHome)ctx.lookup("Item");
item=itemHome.findByPrimaryKey(oldId);
item.modify(name,kind); 你写的是对远程接口的访问,祝好运!
note: ItemHome is local interface!
itemHome = (ItemHome)ctx.lookup("Item");
item=itemHome.findByPrimaryKey(oldId);
item.modify(name,kind); 你写的是对远程接口的访问,祝好运!
note: ItemHome is local interface!
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货