23 Jesus was going through the grain fields on a Sabbath, and his disciples began to pick some heads of wheat as they made their way. 24 So the Pharisees said to him, “Look, why are they doing what is against the law on the Sabbath?” 25 He said to them, “Have you never read what David did when he was in need and he and his companions were hungry— 26 how he entered the house of God when Abiathar was high priest and ate the sacred bread, which is against the law for any but the priests to eat, and also gave it to his companions?” 27 Then he said to them, “The Sabbath was made for people, not people for the Sabbath. 28 For this reason the Son of Man is lord even of the Sabbath.”
Mekhilta d'Rabbi Ishmael 31:13Halakhic Midrash
R. Yishmael and R. Elazar b. Azaryah and R. Akiva were once walking on the road, with Levi Hasadar and R. Yishmael the son of R. Elazar b. Azaryah walking behind them, when this question was asked: Whence is it derived that the saving of a life overrides the Sabbath? R. Yishmael responded: It is written (Ibid. 22:1) "If the thief be found breaking in, etc." — If in such an instance, where it is doubtful whether he is coming to steal or to kill, and the spilling of blood defiles the land and causes the Shechinah to depart, he is permitted to kill the thief to save his life — how much more so does the saving of life override the Sabbath! R. Elazar b. Azaryah responded: If circumcision, which includes only one of a man's organs, overrides the Sabbath, how much more so all of his body! R. Akiva says: If the saving of a life overrides the sacrificial service, which overrides the Sabbath, how much more so does the saving of a life override the Sabbath! R. Yossi Haglili says: "My Sabbaths shall you keep": "but" ("ach," before "My") "divides," i.e., there are Sabbaths that you override, and there are Sabbaths that you rest. R. Shimon b. Menassia says (Ibid. 14) "And you shall keep the Sabbath, for it is holy to you" — Sabbath is given to you and you are not given (i.e., "surrendered") to the Sabbath. R. Nathan says (Ibid. 16) "And the children of Israel shall keep the Sabbath to observe the Sabbath for their generations": Desecrate one Sabbath in order to keep many Sabbaths.
Notes and References
"... Sigal draws our attention to the parallel saying attributed to Rabbi Simon ben Menasya, who said: "Behold, it says: 'And you shall keep the sabbath, for it is holy unto you' [Exodus 31:14]. This means: The sabbath is given to you but you are not surrendered to the sabbath" (Mekilta on Exodus 31:12-17). Sigal reasons that since this parallel is too close to be regarded as nothing more than a coincidence, and since Jesus, who antedates Simon ben Menasya by more than 200 years, is the first to have articulated this halakah, it is most likely that what is credited to Menasya originated with Jesus. Sigal suspects that in other areas, such as in his stricter views of personal piety and more lenient views of cultic requirements, Jesus influenced Tannaic Judaism ..."
Evans, Craig A. Ancient Texts for New Testament Studies: A Guide to the Background Literature (pp. 252-253) Hendrickson Publishers, 2005