|
Re: Failed to map sql result set when execute stored procedure returning cursor [message #754052 is a reply to message #753602] |
Mon, 31 October 2011 11:32   |
Eclipse User |
|
|
|
First of all don't use,
q.setHint("eclipselink.cursor", true);
This is for streaming results, and has nothing to do with stored procedures. If you really wanted to stream results, you would need to set this hint in your named query, not when executing it.
Also,
result-class="Result"
result-set-mapping="ProductMapping"
You can't set both of these, either one or the other.
But, since you don't really seem to want objects back, just data, don't set either. Then you do not need a dummy class, and do not need to worry about mapping the result set. You will just get back the data.
|
|
|
|
|
|
Re: Failed to map sql result set when execute stored procedure returning cursor [message #755536 is a reply to message #755310] |
Tue, 08 November 2011 13:02  |
Eclipse User |
|
|
|
As James pointed out, the "eclipselink.cursor" hint is not used to specify that the type returned is a cursor. It is used to wrap the results returned in a cursor so that they can be returned one at a time instead of all at once from the resultset, which may not be what you want.
Please try your query without the hint, and also try without your resultset mapping definition to see if it is contributing to the problem.
Best Regards,
Chris
|
|
|
Re: Failed to map sql result set when execute stored procedure returning cursor [message #755537 is a reply to message #755310] |
Tue, 08 November 2011 13:02  |
Eclipse User |
|
|
|
As James pointed out, the "eclipselink.cursor" hint is not used to specify that the type returned is a cursor. It is used to wrap the results returned in a cursor so that they can be returned one at a time instead of all at once from the resultset, which may not be what you want.
Please try your query without the hint, and also try without your resultset mapping definition to see if it is contributing to the problem.
Best Regards,
Chris
|
|
|
Powered by
FUDForum. Page generated in 0.05988 seconds