The ruling regarding a person who does not need to relieve himself when he starts to pray, but in the middle of his prayer feels a rising need, is based on how much he needs to relieve himself, and what stage of the prayer he is in. There are three levels of need concerning this law:
- One who can wait 72 minutes is permitted to finish praying.
- One who estimates that he will not be able to wait 72 minutes, but does not yet have to contain the urge, and would have to exert himself slightly to relieve himself at the moment – since when he started to pray he was permitted, and his immediate need is not so great, he may finish the section that he is saying. If the need arises in the middle of Pesukei d’Zimrah, he should wait until reciting Yishtabach, thereby finishing Pesukei d’Zimrah, and then go relieve himself. If the need arises while he is reciting Birkot Keriat Shema, he may, in principle, finish the berachot. However, because he will need to relieve himself before Shemoneh Esrei, it is better not to pause between birkat Ga’al Yisrael and the Amidah. Therefore, he should relieve himself immediately upon finishing the specific berachah or paragraph that he is reciting (Mishnah Berurah 92:9; Bei’ur Halachah s.v. “Ya’amid”).
- One who has to actively suppress the need to relieve himself while praying is in the most serious stage, because at this point he is transgressing the prohibition, “Do not abominate oneself” (Rama 92:2, according to Shulchan Aruch HaRav 3:11). If he is saying Pesukei d’Zimrah or Birkot Keriat Shema, he must immediately go relieve himself since interruption at that point is not so serious. However, if he is in the middle of the Amidah, where a pause at that point is serious, and if, when he began reciting the Amidah, he did not feel the need to relieve himself, he should finish praying. Only in a situation in which he is incapable of waiting at all, should he go relieve himself.
The Bei’ur Halachah 92:1, s.v. “Hayah” is uncertain regarding the law of a chazan who feels a need to relieve himself before Chazarat HaShatz and cannot wait 72 minutes. However, concerning a communal Torah reader, he is lenient and rules that he may read, for human dignity (kevod habriyot) is so great that it takes precedence over a rabbinic prohibition. Nonetheless, regarding prayer, which is considered an abomination, he is doubtful. Thus, even if the chazan will be slightly embarrassed, it is preferable that he goes to relieve himself and has someone replace him. Only if the matter will humiliate him greatly may he continue to pray.
If he must stop to defecate in the middle of the Amidah, it is reasonable to assume that he was probably prohibited from praying when he originally started and it was clear that he would not be able to wait for more than 72 minutes. Therefore, he does not fulfill the obligation for the parts of the Amidah that he already recited and he must go back to the beginning. However, if he truly thought that he would be able to wait 72 minutes, and was surprisingly attacked by such a strong urge to the point where he needed to relieve himself immediately, then if the interruption lasted the time needed to pray all of the Amidah prayer, from beginning to end, he must start the Amidah again, as explained in Shulchan Aruch 104:5 and Rama 65:1. But if the break lasted less time, he continues from the berachah at which he stopped. It seems that a person who was unsure of whether he could, at the outset, estimate his ability to wait 72 minutes, and in the end could not control his need to defecate, must repeat the Amidah because it stands to reason that he was prohibited from praying when he began to recite the Amidah. Furthermore, it is possible that concerning prayer he is considered a repulsive person, based on the logic brought by the Bei’ur Halachah 92:2, s.v. “Yoter.”