Dynamic update works within the session scope.
i.e., you do openSession(), either load the object or use select-before-update to the session and then set the attributes of the object with the new values. THe proxy recognizes the attributes that are dirty and can generate the sql for only those attributes.
However, this requires careful analysis of the problem at hand. If the session is open for too long, it locks the resources. Also, select-before-update will cause a database call before update.
Hope this helps.
_________________ joshi
|