S
Stefanie Ertheld
The code for the LIKE selection:
I don't have the real thing at hand so I can't test it and so I neither
have the exact error at hand - but doing some research and more
thinking, I guess it was a PropertyNotFoundException.
Seems like Hibernate couldn't find MYOBJECT.MYPROPERTYNAME. What are the
exact rules for the annotations? Do they have to be above the setter
methods, above the getter methods, above both, or above the private
instance variables. I put them abouve the private instance variables,
because I think that makes it the easiest to read - and this worked for
my insert statement - are there differences for the Like statement???
I also just read for the getter and setter methods, only the very first
letter may and must be a capital letter - so it must be
setHousenumber and getHousenumber NOT setHouseNumber and getHouseNumber.
True? Pretty stupid imho. Maybe that was the reason??
Thanks in advance,
Stefanie
myCompareValue)).list();>return myHibernateSession.createCriteria(MYOBJECT.class)
>.add(Expression.like(MYOBJECT.MYPROPERTYNAME,
I don't have the real thing at hand so I can't test it and so I neither
have the exact error at hand - but doing some research and more
thinking, I guess it was a PropertyNotFoundException.
Seems like Hibernate couldn't find MYOBJECT.MYPROPERTYNAME. What are the
exact rules for the annotations? Do they have to be above the setter
methods, above the getter methods, above both, or above the private
instance variables. I put them abouve the private instance variables,
because I think that makes it the easiest to read - and this worked for
my insert statement - are there differences for the Like statement???
I also just read for the getter and setter methods, only the very first
letter may and must be a capital letter - so it must be
setHousenumber and getHousenumber NOT setHouseNumber and getHouseNumber.
True? Pretty stupid imho. Maybe that was the reason??
Thanks in advance,
Stefanie