added a commit query for the case where we are updating an exisitng
record