Rabbi Yochanan ben HaChoranit must have been a great Sage. I imagine that many reading this devar Torah have never heard of him and there is in fact very little known about him. He appears but once in the Mishna and even in this instance it is not to record something he said. Rather, it was a debate about whether his sukkah was kosher that earned him mention in our canon. Seemingly, very little to indicate greatness. But there is much more than meets the eye.
Our Sages note that the minimum size necessary for a sukkah is an area that can contain “one’s head, most of the body and one’s table” to place one’s food. The Sages estimated this would be a space of seven by seven tefachim, handbreadths or approximately three feet by three feet. It must also have a minimum height of ten tefachim, some three-and a-half feet tall. While not luxurious it is big enough for a dwelling place needed just seven days a year.
Beit Hillel and Beit Shammai debate whether even a large sukkah would be invalidated if the table would be situated, not inside the sukkah but inside the home. With people attracted to food, Beit Shammai fear that one will “follow the food” and will end up eating inside and thus they invalidate such a sukkah even if in reality one brings the food inside the sukkah. Beit Hillel reject such an approach, confident that even if the food is set up inside one will be careful to eat only in the sukkah itself. And even if one mistakenly eats some food outside the sukkah that is no reason to invalidate such a sukkah in all circumstances.
In trying to convince Beit Shammai that such a sukkah would be valid, Beit Hillel reminded them of the time that “the Elders of Beit Shammai and the Elders of Beit Hillel went to visit Rabbi Yochanan ben HaChoranit and they found him sitting with his head and most of his body in the sukkah and his table in the house” (Sukkah 28a). That proof could be brought from the action of Rav Yochanan ben HaChoranit to settle a dispute between the great academies of Hillel and Shammai indicate what a great Sage Rav Yochanan ben HaChoranit must have been. Moreover, the fact that the elders of Beit Shammai and Beit Hillel went to visit Rav Yochanan ben HaChoranit on Sukkot in the first place is telling.
The Torah obligates us to come to Jerusalem on the three national holidays of Pesach, Shavuot and Sukkot. We come together as a nation dedicated to the service of G-d. With the divine presence most manifest at the Temple in Jerusalem it is there that we must congregate as a people. With the destruction of the Temple, this mitzva could no longer be (fully) observed. Yet with the respect due our teachers (and parents) just about equal to that due towards G-d, our Sages ordained that one must visit one’s teacher on Yom Tov (Sukkah 27b).
So important is visiting one’s teachers on Yom Tov that one who is travelling to do so is exempt from the mitzva of sukkah – even when one is not actually travelling i.e. at night. This is an example of the principle sheluchai mitzva peturim min hasukkah, those engaged in a mitzva are exempt from sitting in a sukkah.
Rashi cites two additional examples of this principle, the mitzva to learn Torah and the mitzva to redeem of captives. Rashi is careful to list learning Torah and visiting one’s teacher as separate mitzvot. There is a mitzva to learn Torah and that mitzva might necessitate visiting one’s teacher. But there is also a mitzva to visit one’s teacher, unrelated to formal Torah learning. One learns much from being in the presence of great teachers. Our Sages teach that “greater is serving [one’s teacher] than learning from them” (Brachot 7b). Formal education is only part of the role of a teacher. Even just seeing one’s mentor can be inspiring. Hence the term for this mitzva is “lehakbeel pnei rabbo”, literally to receive the face of one’s teacher.
That the elders of Beit Shammai and Beit Hillel travelled to the home of Rav Yochanan ben HaChoranit on Sukkot speaks volumes. Who better to bring a proof to the validity of a sukkah, even with the table inside the house, than this great Sage?
Nonetheless, Beit Shammai rejected this as proof. “They [the Elders of Beit Shammai] said to him: If you were accustomed to act in this manner, you have never fulfilled the mitzva of sukkah in all your days”.
This exchange between Beit Shammai and Beit Hillel reveals much about their respective modes of behaviour and even had historical implications. It is the reason we follow the rulings of Beit Hillel despite the fact that the Beit Shammai were “sharper” (Yevamot 14a).
“Why did Beit Hillel merit that the halacha was established in accordance with their opinion? Because they were pleasant and forbearing and they would teach their own statements and the statements of Beit Shammai” (Eiruvin 13b). Beit Hillel recognized that views other than their own were valid, sometimes even more than their own. With that openness came a willingness to rethink issues and accept the view of Beit Shammai when warranted. But convinced that their way was the only way, Beit Shammai never once agreed to the view of Beit Hillel.
“Moreover, they taught the statements of Beit Shammai before their own, as we learned in the Mishna, one whose head and most of his body were in the sukkah, but his table was in the house, Beit Shammai deem this sukkah invalid; and Beit Hillel deem it valid. Beit Hillel said to Beit Shammai: Wasn’t there an incident in which the Elders of Beit Shammai and the Elders of Beit Hillel went to visit Rabbi Yochanan ben HaChoranit, and they found him sitting with his head and most of his body in the sukkah, but his table was in the house?...”
It is perfectly legitimate for Beit Shammai to disagree with Rav Yochanan ben HaChoranit; but it was not acceptable to say “you never fulfilled the mitzva of sukkah all your life” just because one follows the view of Beit Hillel. The lack of sensitivity to tell that to someone, not to mention a Talmudic Sage, is quite astounding. Jewish law states that one is not allowed to directly point out an error made by a parent or a teacher. Rather one should drop hints that will help the person realize they may have erred, say by asking a question about the topic at hand.
The Gemara could have used many other examples of Beit Shammai being recorded before Beit Hillel. For example, the first chapter of masechet Beitza lists 11 debates surrounding Yom Tov between these two great houses of learning and in each case Beit Shammai is listed first.
The fact that the Talmudic editors chose this example involving Rabbi Yochanan ben HaChoranit would be a fulfilment of the notion that “merit is brought about through the meritorious”. Rabbi Yochanan ben HaChoranit is most worthy to be the person associated with the accepted rulings of Beit Hillel. The fact that he did not respond to Beit Shammai is a great indication of his character, one worthy of historical notation. Moreover, by citing this story the Talmud offers a most respectful critique of the approach of Beit Shammai.
Ironically, the Tosafists (Sukkah 3a s.v. d’amar) quote from the 9th century siddur of Rav Amram Gaon, the first full siddur ever produced, that this case is one of only six places where we rule in accordance with Beit Shammai.
 A number of such occasions are recorded in the first chapter of masechet Eduyot.
 It is a hallmark of great poskim to recognize views of others as most legitimate even as they disagree. To cite just two of many examples, Rav Moshe Feinstein permitted one to donate towards the Manhattan eiruv even though he personally felt the eiruv was not kosher. Rav Shlomo Zalman Auerbach, when asked for permission to abort a Tay-Sachs baby would advise the person to ask the Tzitz Eliezer, who unlike Rav Shlomo Zalman allowed such.