Added code to skip commit on update / insert if needed