Clear record when doc_type was changed

@czue http://manage.dimagi.com/default.asp?140716#785508
If only comparing the length it seems needless to have the full list of expected data.