-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 
Author Message
 Post subject: Need help please. Very Very Urgent.
PostPosted: Mon Jul 04, 2005 3:50 am 
Newbie

Joined: Tue Jun 07, 2005 6:54 am
Posts: 17
Hi,

I have a stored procedure,which is proforming multiple joins on various tables and returinng me as result some fields from those joined tables.

The query goes as follows:

CREATE OR REPLACE FUNCTION pg_admin_user_list()
RETURNS refcursor AS
$BODY$
DECLARE
memberInfo refcursor;
BEGIN
OPEN memberInfo FOR
select m.member_id,m.username,m.first_name,m.last_name,
mr.member_role_desc,
t.team_desc,
tm.start_date,tm.end_date,
mf.pref_type,mf.pref_name,mf.pref_value,
ap.first_name As artistFName,ap.last_name As artistLName
from team_member tm,member_role mr,member m,member_pref mf,team t, artist_pool ap
where tm.member_id=m.member_id And tm.team_id=t.team_id And tm.member_role_id=mr.member_role_id
And mf.pref_name='artist_id'
and mf.pref_value = ap.artist_id;
RETURN memberInfo;
END;
$BODY$
LANGUAGE 'plpgsql' VOLATILE;
ALTER FUNCTION pg_admin_user_list() OWNER TO postgres;


My question is as the result is returning selected fields from multiple tables how to relate it to the Hibernate DTO objects.
I am using Hibernate3.0.


Please help.It is very urgent.

Thanks.


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.