Note that there are some explanatory texts on larger screens.

plurals
  1. POopenjpa: illegal argument exception for value object
    text
    copied!<p>there is a NamedQuery like this:</p> <pre><code>@NamedQuery(name = "getOpakOdeslaniForPartner", query = "select </code></pre> <p>new com.vo.OpakOdeslaniVO(opak.pocetPokusu, opak.idSekvenceOpakovani.idOpakSekvence, opak.idSekvenceOpakovani.sekvence) from GmOpakOdeslani opak, GmPrijemce prij where opak.idTypZpravy.idTypZpravy = :typZpravy and opak.idPrijemce = prij and prij.idPrijemceTyp.idPrijemceTyp = :typPrijemce"</p> <p>The value object has single constructor with three parameters.</p> <p>There is a such log (WebLogic 11g, HP-UX):</p> <pre><code>Caused by: &lt;openjpa-1.1.1-SNAPSHOT-r422266:1172209 nonfatal user error&gt; org.apache.openjpa.util.UserException: There was an error packing the projection and/or aggregate results of the query into result type "class com..vo.OpakOdeslaniVO". See the nested Throwable exception for details. at org.apache.openjpa.kernel.ResultPacker.packUserType(ResultPacker.java:262) at org.apache.openjpa.kernel.ResultPacker.pack(ResultPacker.java:225) at org.apache.openjpa.kernel.QueryImpl$PackingResultObjectProvider.getResultObject(QueryImpl.java:1960) at com..service.OpakOdeslani.getOpakOdeslaniForPartner(.java:52) at sun.reflect.GeneratedMethodAccessor1516.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) Caused by: java.lang.IllegalArgumentException at sun.reflect.GeneratedConstructorAccessor747.newInstance(Unknown Source) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27) at java.lang.reflect.Constructor.newInstance(Constructor.java:513) at org.apache.openjpa.kernel.ResultPacker.packUserType(ResultPacker.java:235) ... 114 more </code></pre> <p>Actually I feel stuck, as there is no explanation message for IllegalArgumentException and I cannot find a source code for GeneratedConstructorAccessor747 class. Any idea, what is going on and how to fix this issue? I guess there must be some problem with the value object constructor or class.</p> <p>Thank you</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload