Hibernate version: 3.2.5
Hi folks,
i am trying to access the elements of a map in a HQL query and get
org.hibernate.QueryException: illegal attempt to dereference collection executing my query.
Here is my query:
Code:
from MasterData as md where md.parametersIntern.name = 'John'
In this case
parmetersIntern is a map of elements. I am trying to access the field
name of the map objects in my
where condition.
I have also tried following query:
Code:
from MasterData as md where md.parametersIntern[key].name = 'John'
In this case i am getting
SQLGrammarException.
What is wrong with these queries? Has anybody an idea? How should my query looks like?
Many thanks in advance.