The @jboss:finder-query applies to JAWS.  The new JBoss 'order by' extension to EJB-QL 
is a separate issue, and as I understand it
is not yet implemented.  I can have a look at implementing this tonight - unless 
someone corrects me to tell me it isn't implemented
(I had a quick look at the template).  Also, as I understand it this feature is only 
available in JBoss CVS, and not in either of
the releases, but I could be wrong there.

cheers
dim

----- Original Message -----
From: "Andronica Teodorescu" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, March 14, 2002 8:36 AM
Subject: RE: [Xdoclet-user] @jboss:finder-query vs. @ejb:finder


> I tried what you suggested, but JBoss (3.0) throws an error when invoking
> the custom finder (javax.ejb.FinderException: Unknown query)
> So, I guess is more a JBoss problem, since it's working fine for you in
> 2.4.4.
>
> Thanks a lot,
> Andronica
>   -----Original Message-----
>   From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
>   Sent: Wednesday, March 13, 2002 1:56 PM
>   To: [EMAIL PROTECTED]; [EMAIL PROTECTED]
>   Subject: RE: [Xdoclet-user] @jboss:finder-query vs. @ejb:finder
>
>
>   I don't know about JBoss 1.3 but we are using JBoss 2.4.4 and I am doing
> this:
>
>   First define the ejb:finder as:
>   @ejb:finder signature="java.util.Collection findAllCustom()"
>
>   And then define  jboss:finder-query as:
>   @jboss:finder-query name="findAllCustom" query=publicationGroupID < 3
> order by description"
>
>   C.
>
>
>
>     -----Original Message-----
>     From: Andronica Teodorescu [mailto:[EMAIL PROTECTED]]
>     Sent: Wednesday, March 13, 2002 1:29 PM
>     To: [EMAIL PROTECTED]
>     Subject: [Xdoclet-user] @jboss:finder-query vs. @ejb:finder
>
>
>     Hello,
>
>     Can someone please explain how to use these 2 tags?
>
>     I am trying to set-up a custom finder for a CMP entity bean. The bean is
> deployed into JBoss1.3 (alpha) server.
>     Also, I would like the finder to return objects ordered by a given
> field. I know, this can be done afterwards, but still ...
>
>     So, in @ejb:finder tag, I can define my query using EJB-QL , which
> doesn't support "ORDER BY".
>     On the other hand, in @jboss:finder-query tag I have the option to
> specify the query (JAWS syntax) and the "order" field.
>     Question: where the query should be defined? In @ejb:finder, or
> @jboss:finder-query or in both?
>
>     Using the jboss tag, the generated jaws.xml file contained the finder
> query method, and the order field as well. But the result list is not
> ordered. Further more,
>     the query that is performed seems to be the query from @ejb:finder tag,
> not from @jboss:finder-query tag.
>
>     If I do not specify the query for @ejb:finder, at runtime an exception
> is thrown by JBoss. (javax.ejb.FinderException: Unknown query).
>
>
>     Here the code for the bean
>      * @ejb:bean
>      *    name="publication/PublicationGroup"
>      *    display-name="Models a Publication Group"
>      *    type="CMP"
>      *    cmp-version="2.x"
>      *    jndi-name="ejb/publication/PublicationGroup"
>      *    view-type="local"
>      *    schema="PublicationGroup"
>      *    primkey-field="publicationGroupID"
>      * @ejb:transaction type="Required"
>      * @ejb:finder signature="java.util.Collection findAll()"
>      * @ejb:finder signature="java.util.Collection findAllCustom()"
>      * @ejb:pk class="java.lang.Long" generate="false"
>      *
>      * @jboss:table-name "publication_group"
>      * @jboss:finder-query
>      *      name="findAllCustom"
>      *      query="publicationGroupID < 3"
>      *      order="description"
>      *      read-ahead="true"
>      * @jboss:create-table "false"
>      * @jboss:remove-table "false"
>      * @jboss:tuned-updates "true"
>      * @jboss:read-only "false"
>
>
>     Thanks in advance,
>     Andronica
>
>
>
>
>
>


_______________________________________________
Xdoclet-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/xdoclet-user

Reply via email to