Hello, statalist!

I am struggling with the replace the value for the same person.
In the dataset, there are two observations, but they are the same person.
I do not want to drop duplicates but just replace the value which is shown as "SAME AS~" with the value.
Since ID=1 and ID=2 is the same person, name, mothername, fathername, and gender is the same.
But, they have different value in birthyear and birthmonth.

I have no idea how to do it.
Do I have to detect all of duplicates and replace it?

So, I was trying

code:
duplicates list name mothername fathername gender


but after then, I do not have any good idea to deal with this.

I want ID=2 to have same value as ID=2 in birthyear and birthmonth because their name, mothername, fathername, and gender is the same (which means same person)

So.. if two observations have the same value in name, mothername, fathername, and gender, then replace the birthyear and birthmonth with the same value as the other one.

Is it fast to replace "SAME AS~" with the blank?

==========================================data==== ===

ID name mothername fathername gender birthyear birthmonth
1 XXX ABC DEF female "1991" "9"
2 XXX ABC DEF female "SAME AS ID=2" "SAME AS ID=2"
3 AAA EFG GED male "1980" "5"
4 BBB FGH HBE female "1960" "3"
.
.
.
================================================== ==


I would greatly appreciate it if you give me any solution for this!
Thank you in advance.