Im new in EJB
I would like to know how to declare finder methods in a container managed persistent bean.
IM suing ejb2.0 and ive defined a findAll() method. how to declare that in the ejb-jar.xml.
Please help me because this is urgent. Where can i find more info abt this. I searched for this and noone gives example for findAll() methods.
The finder methods in CMP, are written when you write the bean class, in the home interface.
U dont have to define these methods in the ejb-jar.xml file.
only the find method in the home interface and corresponding create method in the bean class needs to be written ( as u know there would be a create method for each of the finder methods).
Write your findAll method in the home and then the ejbCreate method (ofcourse the arguments would be same).
When you call this method .. (normal create method ).. this will refer to the findAll method, which will communicate to the ejbCreate method.
You need to add the following lines in the ejb-jar.xml file
<![CDATA[FROM EJBBeanName AS a]]>
we are using the above format in weblogic6.0 , ejb2.0 specs with ejb query language.it's working.if ur using the ejb2.0 specs with ejb query language... try be using the above format..