persistence@glassfish.java.net

Re: EJB QL constructor query with aggregate argument

From: Michael Bouschen <mbo.tech_at_spree.de>
Date: Mon, 13 Mar 2006 16:16:48 +0100

Hi,

sorry, I forgot the attachemnt.

Regards Michael

> Hi Tom,
>
> welcome back!
>
> attached you find my changes fixing the NPE in ReportQuery thrown for an
> EJB QL query using an aggregate function as an argument of a constructor
> expression:
> SELECT NEW custom.CityCount(c.city, COUNT(c)) FROM Customer c
> GROUP BY c.city
>
> In the parse tree node ConstructorNode I switch back to calling the
> ReportQuery method returnObjectsFromConstructor taking Class instances
> for the constructor arguments (instead of mappings). I understood that
> with your checkin from March 3 ("delayed ejbql query parsing till
> login") this should work for constructor expressions in named queries.
> Please have a look.
>
> The corresponding glassfish issue is:
> https://glassfish.dev.java.net/issues/show_bug.cgi?id=310
>
> Thanks!
>
> Regards Michael


-- 
Michael Bouschen		Tech_at_Spree Engineering GmbH
mailto:mbo.tech@spree.de	http://www.tech.spree.de/
Tel.:++49/30/235 520-33		Buelowstr. 66			
Fax.:++49/30/2175 2012		D-10783 Berlin