Is it possible to have a like in a where clause in a named query? I am trying to do the following but am getting exceptions
@NamedQuery(name = \"Place.getPla
You can't have the % in the NamedQuery, but you can have it in the value you assign the parameter.
NamedQuery
As in:
String city = "needle"; query.setParamter("city", "%" + city + "%");