The Great Switch
‘These Are The Sons Of Leah’
The Gemara states that the gender of a child is dependent on whichever parent “emits the seed” first. If the mother does, the child is male; if the father does, the child is female. Our Gemara says this teaching remained without a source until R. Tzadok expounded Bereishis 46:15, “These are the sons of Leah whom she bore to Yaakov in Padan Aram and Dinah his daughter.” This pasuk associates sons with their mother and Dinah with her father.
The Prayers Of Righteous Women
The Gemara (Berachos 60a) relates that Leah, after bearing Yaakov six sons, found herself pregnant with a seventh son. Yaakov already had 10 sons at that point, and the matriarchs knew through prophecy that he was destined to have 12 sons. Leah realized that if she had another son, Rachel (who did not yet have any children) would be humiliated as she would end up with fewer sons than Bilhah and Zilpah, who had two each. Leah therefore prayed that she would give birth to a daughter.
The Yefei Toar (cited by Me’am Loez) adds that Bilhah and Zilpah joined Leah in her tent and told her they were satisfied with the number of sons they had and wanted Rachel to now give birth to a son. All three of them then prayed that Leah’s seventh pregnancy would result in the birth of a girl. Due to their prayers, Hashem changed the gender of the fetus.
The Power of Prayer
Based on this account, the Maharsha (Niddah 32a) questions R. Tzadok’s exposition. According to him, Dinah was a girl due to the actions of her father, but really she was a girl because of the prayers of Leah (and Bilhah and Zilpah).
The Maharsha answers his question by citing the Paneach Raza, who notes that one of the piyutim recited on Rosh Hashanah indicates that Hashem did not transform the male fetus in Leah’s womb into a female. Rather Hashem exchanged the male fetus in Leah’s womb (Yosef) with the female fetus in Rachel’s womb (Dinah). Thus, Dinah was indeed a female from conception due to her father Yaakov.