modifiedthe cancel and confirm to maintain balance
for merging the changes db_script