-->
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.  [ 2 posts ] 
Author Message
 Post subject: Named SQL query..
PostPosted: Fri Nov 18, 2005 5:25 am 
Newbie

Joined: Mon Nov 14, 2005 2:27 am
Posts: 6
Hi,

Named SQL queries may be defined in the mapping document ? In which document it should be defined , can I have an example?.


Top
 Profile  
 
 Post subject:
PostPosted: Fri Nov 18, 2005 5:48 am 
Newbie

Joined: Sat Nov 12, 2005 1:12 am
Posts: 4
Location: Islamabad, Pakistan
Name Query is define in in hbm file.eg i have a Cat.hbm.xml file where i define a named query as

<query name="findCatsByPerson"><![CDATA[
from Cat c where c.person.id = :id2Find
]]></query>

outside the the <class> tag.

for detailed information read Hibernate in Action chapter 7.

[if it helped u plz rate it].


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

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.