Let say I have a Message entity and an Author entity with a one to many relation between the Author and the Message. If I want to select all the messages from a specific author then I could use the folowing query :
SELECT OBJECT(m) FROM Author a, IN( u.messages ) m WHERE a = ?1
It works fine for me but I think the following query is more simple and I do not understand why it doesnt work :
SELECT object(m) FROM Message m WHERE m.author = ?1
Could somebody bring some light on this ?
What is the error message you are getting?
Are you using JBoss 3.0 rc1? If not, upgrade.