-->
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: embed hql in mapping files
PostPosted: Mon Jul 28, 2008 2:51 pm 
Newbie

Joined: Sun Mar 30, 2008 10:15 pm
Posts: 18
Hello is there a way I can embed my hql in the mapping file then use a named query to execute it?

<sql-query name="get_pets_for_user" callable="false">
<return class="cat"/>
FROM Cat WHERE owner= :owner
</sql-query>

Everything works great except I get a JDBCExceptionReporter telling me that
"could not execute query [FROM Cat WHERE owner = ?]"

It thinks it is sql not hql...

Thanks in advance


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.