problem again ..
when I use Jame's solution I get
Not all named parameters have been set: [reqID] [update ORION_LMS_LEAVE_REQ set FINAL_STATUS='approved' where LEAVE_REQ_ID = :reqID]
my xml is like
<sql g="381,560,129,52" name="CleanupOnApproval" var="approvalQ">
<query>update ORION_LMS_LEAVE_REQ set FINAL_STATUS='approved' where LEAVE_REQ_ID = :reqID</query>
<parameters><object name="reqID" expr="#{requestId}"/></parameters>
<transition g="-102,-11" name="sendApprovalMail" to="sendApprovalMail"/>
</sql>
The problem <object> doesnot have a parameter "name" still stands.
Help ..