如何在jaws里边定义finder方法,定义过了,为什么还是找不到那??

bluegirl
03-07-03 131

jaws.xml文件如下:


<jaws>
<datasource>java:/DB2DS</datasource>
<type-mapping>DB2</type-mapping>
<debug>true</debug>


<enterprise-beans>
<entity>
<ejb-name>ProtonAccount</ejb-name>
<table-name>protonaccount</table-name>
<cmp-field>
<field-name>account_number</field-name>
<column-name>account_number</column-name>
</cmp-field>
<cmp-field>
<field-name>customer_name</field-name>
<column-name>customer_name</column-name>
</cmp-field>
<cmp-field>
<field-name>balance</field-name>
<column-name>balance</column-name>
</cmp-field>
<finder>
<name>findByID</name>
<query>protonaccount WHERE protonaccount.account_number={0}</query>

<order></order>
</finder>
<finder>
<name>findAllAcounts</name>
<query />
<order/>
</finder>

</entity>
</enterprise-beans>
</jaws>

调用这个实体bean后报错如下:

error getting the accountsUnknown query: public abstract java.util.Collection com.bank.ProtonAccountHome.findAllAccounts() throws javax.ejb.FinderException,java.rmi.RemoteException