Modifying the script to update demographics of existing patients and creating encounters for new patients if the encounters are available in the textintegration file