“The Medanites sold him to Egypt, to Potifar, an official of Pharaoh, the chief executioner” (Genesis 37:36). “The Medanites sold him” – how many bills of sale were written for him? Rabbi Yudan said: Four – his brothers to the Ishmaelites, the Ishmaelites to the merchants, the merchants to the Midianites, and the Midianites sold him to Egypt. Rav Huna said: Five – the Midianites sold him to the country’s treasury. Potifar came and purchased him from the country’s treasury.
“It was at that time; Judah descended from his brothers and turned to an Adulamite man, and his name was Ḥira” (Genesis 38:1). “It was at that time; Judah descended from his brothers” – “Judah has betrayed, and an abomination has been performed…” (Malachi 2:11). [God] said to him: ‘You have denied, Judah; you have lied, Judah’ – “and an abomination has been performed in Israel” (Malachi 2:11).1Judah is portrayed as having denied and lied in that he betrayed his status as a member of Jacob’s household by marrying a Canaanite woman (Matnot Kehuna). This is in accordance with the opinion of Rabbi Neḥemya (see Bereshit Rabba 84:21). ‘Judah has become profane’ – “for Judah has profaned the holy of the Lord that He loves” (Malachi 2:11). “It was at that time.” “I will yet bring to you a dispossessor, inhabitant of Maresha; [the glory of Israel] will come as far as Adulam” (Micah 1:15) – the King and Holy One of Israel.2God will come to Adulam to punish Israel (Yefe To’ar). [Alternatively,] should the glory of Israel have “come as far as Adulam”?3In this clause the midrash interprets “the glory of Israel” to refer to Judah himself. This sentence is to be read rhetorically; was it really fitting for Judah to come to Adulam and to marry a Canaanite woman? (see Yefe To’ar). “Come as far as Adulam” – as it is written: “And turned to an Adulamite man.” “It was at that time” – Rabbi Shmuel bar Naḥman began: “For I have known the thoughts” (Jeremiah 29:11) – the tribes were engaged in the sale of Joseph, Joseph was engaged in his sackcloth and his fasting, Reuben was engaged in his sackcloth and his fasting, Jacob was engaged in his sackcloth and his fasting, Judah was engaged in taking a wife for himself, and the Holy One blessed be He was engaged in creating the light of the messianic king: “It was at that time, Judah descended from his brothers.”4Judah married the daughter of Shua, thereby establishing the family that would produce the Messiah. “Before she begins labor, she will give birth” (Isaiah 66:7) – before the first one who would enslave [Israel] was born, the ultimate redeemer was born. “It was at that time” – what is written prior to the matter? “The Medanites sold him to Egypt” (Genesis 37:36).5As the events that would lead to Israel’s enslavement in Egypt were just beginning to unfold, God was already planting the seeds of the ultimate redemption.