This script does two things: For those persons having one Alternate Name of type “Birth” and a Primary name of “undefined” type, it sets the Alt name as the Primary name and changes the previous Primary name to an Alternate Name. For those persons having more than one Name of type “Birth”, it lists the Record…