Hibernate version: 2.1.4
In the "Hibernate In Action" book, I see:
Quote:
The getNamedQuery() method obtains a Query instance for a named query:
session.getNamedQuery("findItemsByDescription")
.setString("description", description)
.list();
In this example, we execute the named query findItemsByDescription after binding
a string argument to a named parameter. The named query is defined in mapping
metadata, e.g. in Item.hbm.xml, using the <query> element:
<query name="findItemsByDescription"><![CDATA[
from Item item where item.description like :description
]]></query>
Is it possible to do a similar named query for an UPDATE statement in Hibernate? I require this to overcome legacy database difficulties with Hibernate. If possible, please provide some code example or point me to the resource.