aspose file tools*
The moose likes EJB Certification (SCBCD/OCPJBCD) and the fly likes EJB-QL Select methods Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Certification » EJB Certification (SCBCD/OCPJBCD)
Bookmark "EJB-QL Select methods" Watch "EJB-QL Select methods" New topic
Author

EJB-QL Select methods

Carlos Llona
Greenhorn

Joined: Apr 09, 2004
Posts: 15
Hello helppp:

the spec says in 11.2.2

Select methods?Select methods are a special type of query method not directly exposed
through the client view. The Bean Provider typically uses select methods to select the persistent
state of an entity object or to select entities that are related to the entity bean for which the
query is defined. The result type of a select method can be an EJBLocalObject (or a collection
of EJBLocalObjects), an EJBObject (or a collection of EJBObjects), or a cmp-field value (or a
collection of such).


I think that the results should be EJBlocalObjects or collecions or cmp-field value (or a collection of such). Why does the result will be ejbObject (remotes) is it right?, In witch cases it would be objects remotes???

sorry my inglish is poor
guojun shan
Greenhorn

Joined: Jun 04, 2003
Posts: 4
give a example ,the following is the ejb-jar.xml OF A EJB NAMED CabinEJB:

<entity>
<ejb-name>CabinEJB</ejb-name>
<home>com.titan.cabin.CabinHomeRemote</home>
<remote>com.titan.cabin.CabinRemote</remote>
<ejb-class>com.titan.cabin.CabinBean</ejb-class>
<abstract-schema-name>Cruise</abstract-schema-name>
...
</entity>

THE following EJB QL is correct,right?

SELECT OBJECT(C) FROM Cruise C

so ,it can got a ejbobject or collections of ejbobjects


SCJP 1.2<br />SCWCD<br />SCBCD
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: EJB-QL Select methods
 
Similar Threads
EJB spec conflicts - CMR field return types
ejbSelect...() method
EJB QL Query
My Study Notes
ejbSelect Method in CMP