You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jdo-dev@db.apache.org by Michael Bouschen <mi...@akquinet.de> on 2017/05/27 19:55:03 UTC

Re: [datanucleus/datanucleus-api-jdo] JDOQL: cannot pass Object[].class as result class to executeResultList (#53)

Hi Andy,

I was looking for a way to execute the query with more than one result
expression w/o the need of a cast:
  List<Object[]> results = q.executeResultList(Object[].class);

I cannot use executeResultList() because it returns List<Object> which
is not compatible to List<Object[]>, so the following does not compile:
  List<Object[]> results = q.executeResultList();

Regards Michael
>
> There is a executeResultList() method for a reason, for the case where
> the user doesn't want to impose the result class (i.e get the default
> the spec defines ... Object[]).
>
> Again, simple to change, but the question remains ... why would anyone
> do that?
>
> —
> You are receiving this because you authored the thread.
> Reply to this email directly, view it on GitHub
> <https://github.com/datanucleus/datanucleus-api-jdo/issues/53#issuecomment-304464836>,
> or mute the thread
> <https://github.com/notifications/unsubscribe-auth/AbdDGNFprQtvnHggYm_0ujb8sHaOt4Qeks5r-Fl4gaJpZM4NoZK5>.
>


-- 
Michael Bouschen
akquinet tech@spree GmbH
Bülowstraße 66 • D-10783 Berlin
Tel:   +49 30 235520-33
Fax:  +49 30 217520-12

E-Mail: michael.bouschen@akquinet.de <ma...@akquinet.de>
Web:   www.akquinet.de <http://www.akquinet.de/>

Geschäftsführung: Martin Weber, Dr. Torsten Fink
Amtsgericht Berlin HRB 86780 • USt.-Id. Nr.: DE 225 964 680

[Facebook] <http://www.facebook.com/akquinet>  [XING]
<https://www.xing.com/companies/akquinetag>  [G+]
<https://plus.google.com/b/111054946250796705170/+akquinet/posts> 
[LinkedIn] <https://www.linkedin.com/company/akquinet-ag>  [Twitter]
<https://twitter.com/akquinet>