Friends, I have a requirement in my project like: I have a Stored Procedue which will return a set of tables and considering the result set as a table , I need to execute HQL query on it. How can this be done.
Can be better understood with the query which works fine in the SQL IDEs. select * from ( select distinct PARTY_ID, ACCT_NO_1 , ROW_NUMBER() OVER (ORDER BY PARTY_ID) R from table(pax.p2a_services_pkg.get_by_cust_loc_func('G','327888475','AML')) )where R between 10 and 18
pax.p2a_services_pkg.get_by_cust_loc_func('G','327888475','AML')) This is the stored procedure call and the remaining is the SQL query on the results it gives.
I want to know how this query can be executed using HQL and named sql query. Advice please...
Please Go through the getNamedQuery() for this.....
which is very familiar for the stored procedure ...........only
Joined: Apr 24, 2007
feel free to ask the code and say about the query you need ..........man
Joined: Sep 20, 2004
Hi thanks for replying.. I have got the code for executing simple named query from the javaranach forum only... now I require that an HQL query shud be run on the result sets that would be returned from the stored procedure..