GetId是怎么写的?
Table.GetId()没有参数?你添了一条纪录不假,但是你要取那一条记录呀?我是看不出来。

解决方案 »

  1.   

    to hongyu71,难道getid不是取出当前记录的id吗,应该是没有参数的吧
    to luodi
    这是bean类的代码,public class TableBean implements EntityBean
    {
      EntityContext entityContext;
      public Short id;
      public String name;
      public TablePK ejbCreate(Short id, String name) throws CreateException, RemoteException
      {
        this.id = id;
        this.name = name;
        return null;
      }
      public void ejbPostCreate(Short id, String name) throws CreateException, RemoteException
      {
      }
      public void ejbLoad() throws RemoteException
      {
      }
      public void ejbStore() throws RemoteException
      {
      }
      public void ejbRemove() throws RemoveException, RemoteException
      {
      }
      public void ejbActivate() throws RemoteException
      {
      }
      public void ejbPassivate() throws RemoteException
      {
      }
      public void setEntityContext(EntityContext entityContext) throws RemoteException
      {
        this.entityContext = entityContext;
      }
      public void unsetEntityContext() throws RemoteException
      {
        entityContext = null;
      }
      public Short getId()
      {
        return id;
      }
      public String getName()
      {
        return name;
      }
    }
      

  2.   

    把你的 Home 和 Remote 的 Interface 定义也贴出来看一下。
      

  3.   

    另:如有可能,把你发布的过程描述一下,比如你的 ejb-jar.xml 文件内容。
      

  4.   

    肯定是没有问题的,是jbuilder自动生成的,已经能create了,就是能插入了,可是却不能读属性,why?