I got the same error. Although I don't know why, JBoss only accepts Objects, that are of the same type as the Bean (better Schema) you defined your query in (e.g. ProductGroup-Scheme-Objects). By redefining the query it worked for me (assuming you're using a bi-directional one-to-many relationship):
SELECT OBJECT(p) FROM Product p WHERE p.productGroup.name= ?1
This must be placed in the Schema for Product. When I tried it with a many-to-many-relationship I got even more strange errors (see http://www.jboss.org/modules/bb/index.html?module=bb&op=viewtopic&t=forums/ of the code in CVS didn't change for 2 months. Maybe the IN clause is not supported correctly (regarding the creation of table-aliases).
Hope it helps,
The author of the EJBQL code says this is a bug in the parser...
I just started reading the forums. I've been to busy (lazy).
This bug has been fixed in cvs.