Psalm 119 is the longest psalm in Tehillim, and it is structured as an eightfold alphabetical acrostic ("temanya apei") - eight verses for each letter of the alef-bet. The Malbim analyzes it meticulously, observing that in this lengthy prayer, whose entire focus is a plea that one walk in the Torah of Hashem and keep His commandments, six constant terms appear in every section: Torah, Eidot (testimonies), Pikudim (precepts), Mitzvot (commandments), Chukim (statutes), and Mishpatim (ordinances). Radak counts more, but the Malbim counts six, and these are the same six terms we previously saw in the psalm "The heavens declare the glory of God" (Psalm 19).
אַשְׁרֵי תְמִימֵי־דָרֶךְ הַהֹלְכִים בְּתוֹרַת יְהוָה׃ - Happy are those whose way is blameless, who walk in the Torah of Hashem.
Who are "the blameless of way" (temimei darech)? This refers to those who are whole and complete in their path - their way is pure and unblemished. And who are they? "Those who walk in the Torah of Hashem" - those who study Torah. For a person cannot be complete without studying Torah, as Chazal stated: "An unlearned person cannot be fearful of sin." A person cannot be God-fearing if he does not know what he is required to observe. You ask someone: Do you keep Shabbat? "Of course, meticulously, both minor and major details!" Are you careful with the prohibition of borer (sorting)? "Borer? What is borer?" How can you keep Shabbat if you do not know what borer is? These are prohibitions in which anyone can stumble; as the Ya'arot Devash writes, quoted by the Mishnah Berurah in his introduction, it is impossible for someone not to stumble every Shabbat if he has not studied the laws of Shabbat. Thus, says Radak, a person cannot be complete unless he studies Torah - and this is "Happy are those whose way is blameless, who walk in the Torah of Hashem": when they walk in the Torah of Hashem, their way naturally becomes whole and blameless.
Parenthetically, the full dictum in the Mishnah is: "An unlearned person cannot be fearful of sin, nor can an ignoramus (am ha'aretz) be pious (chasid)." An ignoramus cannot be a chasid, but he can indeed be a tzaddik. Why? Because to act as a chasid, going beyond the letter of the law, one must know that his pious act does not conflict with something else, that he is not performing an act of piety at the expense of another mitzvah. A tzaddik, however, is one who fulfills what is written, and an unlearned person can know what is written and fulfill it. But practicing the measure of piety - that he certainly cannot do properly.
Radak, as well as Ibn Ezra, further explains that the word "way" (derech) here serves double duty: "Happy are those whose way is blameless, who walk in the [way of the] Torah of Hashem" - the word "way" from the first clause also applies to the second. This is similar to what we recite in Aleinu: "Who did not make our portion like theirs, nor our lot like that of all their multitude." Does it mean our lot is like their multitude? Rather, the negative phrase "Who did not make" carries over to the second clause as well: and who did not make our lot like all their multitude. So too here, "way" carries over to what follows.
אַשְׁרֵי נֹצְרֵי עֵדֹתָיו בְּכָל־לֵב יִדְרְשׁוּהוּ׃ - Happy are those who keep His testimonies, who seek Him with all their heart.
The first verse spoke of a person who trains himself to walk on an upright path. Here, Ibn Ezra explains, it refers to a person who preserves the testimony received from the forefathers, foremost among them being eyewitness testimony. That is, there are practices one accustoms oneself to through personal effort, and there are truths acquired and inherited from one's ancestors. Faith and the knowledge of Hashem's existence were passed down to us from our forefathers, for our ancestors recounted them to us. They are the ones who transmit to us faith in Hashem and the definitive knowledge of the Exodus from Egypt - we conduct the Seder night and thereby pass this knowledge from parents to children. This is "Happy are those who keep His testimonies": preserving those very testimonies that the forefathers attested to us, beyond what we train ourselves to do through our own efforts to walk in an upright path.
Radak explains: Praiseworthy are those who keep His testimonies, meaning those who observe the testimonies of Hashem. And what are these testimonies? The mitzvos that serve as testimony and remembrance - Shabbos, the festivals, tzitzis, tefillin. (Note that what the Malbim terms "pikudim", Radak terms "eidos".) And through these testimonies, Radak says, they will understand and know, not with a divided heart, but with all their heart - "they seek Him with their whole heart."
The meaning of this is: when a person performs a mitzvah, and this mitzvah is a remembrance that Hashem brought us out of Egypt, a remembrance that Hashem created His world in six days and rested on the seventh day - this is no longer a mitzvah performed with a divided heart. It is not a mitzvah of "maybe yes, maybe no", which is called having a double heart. Man has two hearts, the yetzer hatov and the yetzer hara, which is why it says "with all your heart (levavcha)" - and not "libcha" - where the two beis letters represent your two inclinations, as Chazal expound. One who serves Hashem with doubt, skeptically, thinking, "It could be true, or it could not; maybe there is a reward for this" - that is serving Hashem with a double heart. But one who guards the testimonies, who preserves the testimony that the Holy One, blessed be He, created His world in six days, gave us the Torah, and brought us out of Egypt - he seeks Hashem with all his heart, he has no doubts, and his service is on a far higher level.
אַף לֹא־פָעֲלוּ עַוְלָה בִּדְרָכָיו הָלָכוּ׃ - They have also done no iniquity; they have walked in His ways.
Rashi explains: If they also possess this quality - that they have done no iniquity and have walked in His ways - praiseworthy are they. This ties back to the "Praiseworthy" with which we began. And why must the verse add "they have walked in His ways"? Because "they have done no iniquity" is merely passive, and inaction is not enough. Their reward is not complete unless "they have walked in His ways" - just as it is written, "Turn away from evil," but that alone is insufficient; rather, one must "and do good." Even if you turn away from evil, there is no completeness until you actively do good.
Radak notes that some explain the word "af" (even/also) here as an expression of kal vachomer (an a fortiori argument). For on the surface, this is puzzling: you spoke of a person who preserves His testimonies and seeks Hashem with all his heart, and now you add that he also does not rob banks? That seems to lower his stature! Rather, the meaning is "how much more so" - how much more so have they done no iniquity. This is similar to the verse in Iyov, "even (af) those who dwell in houses of clay," which means how much more so those who dwell in houses of clay. So too here: if they guard His testimonies, which are positive commandments, how much more so will they be careful not to commit any iniquity, and will walk in the ways of Hashem.
The Malbim explains: "They have also done no iniquity" - these are the negative commandments; "they have walked in His ways" - these are the positive commandments. That is, they are scrupulous regarding both the negative and the positive commandments.
Others explain this differently, in a somewhat Chassidic vein: "They have also done no iniquity" - even those who merely did not commit iniquity, "they have walked in His ways", it will be considered for them as though they walked in His ways; by the very fact that one does not commit iniquity, he is considered as walking in the way of Hashem. However, Radak rejects this interpretation: "And this interpretation is incorrect," as we explained in the first psalm - "Turn away from evil and do good," for a person is not perfected if he merely turns away from evil without doing good. One cannot say that simply because he does not commit iniquity, he is already considered a tzaddik.
Yet Chazal seemingly said precisely this: if one sat and did not commit a sin, he is given a reward like one who performed a mitzvah! However, the Gemara in Kiddushin (39b) clarifies: they said this only regarding someone to whom an opportunity for sin presented itself and he was saved from it. One cannot say in a general sense that whoever does not commit iniquity is considered as doing good; only if a transgression actually presented itself to him and he did not do it. We do not receive reward for not eating pork right now, nor do we receive reward for not murdering right now. But if we face a test - even one that is not particularly great - and overcome it, for that we receive reward.
And this is another expression of the principle that a person should not say, "Pork disgusts me" - do you eat based on what tastes good or what is disgusting? On the contrary, a person should say: pork is very tasty, but I do not eat it because the Torah commanded me not to. Yet that is not a reward one receives right now, for right now I did not refrain from eating because the Torah commanded, but simply because pork was not served to me. And for that, one does not receive a reward.
Radak also offers a completely different explanation: "They have also done no iniquity" - since they seek Hashem with all their heart, they are assured that they will not commit iniquity, that a sinful matter will never come their way; "they have walked in His ways" - all his days he will walk in the ways of Hashem. The verse did not come merely to say that he is "not a criminal," but rather that if you are one who seeks Hashem with all your heart, no sin will ever present itself to you. For "there is no righteous man on earth who does good and does not sin," and anyone can arrive at a situation where he falls into iniquity, Heaven forbid; yet the verse comes and says that one who seeks Hashem with all his heart will never encounter iniquity, but will always walk solely in the ways of Hashem. This is in the realm of what Chazal taught: "He who comes to purify himself is granted assistance" - Heaven protects him and helps him so that he does not come to ruin.
The Malbim adds: Beyond what we said about the testimonies being useful to study, examine, and see what miracles the Holy One, blessed be He, performed for us - leading us to serve Hashem whole-heartedly - they are also beneficial on a practical level. The testimonies teach us the ways of Hashem, and in Hashem's ways we see that He punishes sinners - Sodom, the Generation of the Dispersion, the Generation of the Flood - and grants a good reward to those who walk in His ways, such as Avraham, Yitzchak, and Yaakov. From this, people take heed and understand: "They also do no iniquity," because "they walk in His ways." We see that whoever walks in Hashem's path receives merit from Him, and this is what Sefer Bereishis relates - it is called "Sefer HaYashar" (the Book of the Upright) - that when a person is upright in Hashem's ways, he is rewarded by Him, may He be blessed. The testimonies that attest to reward and punishment prevent a person from committing iniquity and doing wrong, and virtually obligate him to walk in Hashem's ways and cleave to them.
And what is the precision of the phrase "they do [or 'work'] no iniquity" (lo fa'alu avlah)? The Malbim explains in several places that there is a distinction between pa'al (working or engaging in an act) and asah (doing or completing an act): pe'ulah is the very engagement in a matter, while asiyah is when the act is brought to completion. As long as you are involved in something, it is called pe'ulah. The verse tells us that these righteous individuals do not even engage in anything tainted with wrongdoing, even if they do not complete the act. Sometimes a person says: "Well, I will only look into it or get involved; I won't actually commit the sin, or I won't finish it." We say to him: No, these righteous ones "have not even worked iniquity" - they do not have even the slightest involvement in the matter, even without finishing it.
אַתָּה צִוִּיתָה פִקֻּדֶיךָ לִשְׁמֹר מְאֹד׃ - You have commanded Your precepts, to keep them diligently.
The Ibn Ezra explains: "You have commanded Your precepts" - this refers to the heart. And the reason for "You commanded" - where did You command? Through the prophets. The meaning is: everything originated from You; You commanded Your precepts so that we would keep all Your mitzvos. And why did You command that they be kept "diligently" (me'od)? The Radak explains: so that a person will not err in them, and so that his entire heart will be devoted to them. This is the meaning of "to keep diligently" - it requires meticulous vigilance and careful precision. One cannot simply say, "I'll try"; here, thorough and vigilant safeguarding is required: to keep them diligently.
The Malbim explains that pikudim (precepts) are the mitzvos that bear testimony to Hashem's actions and Divine Providence. Tefillin, for example, are classified by the Malbim under "Your precepts," since they testify that the Holy One, blessed be He, took us out of Egypt with a strong hand and an outstretched arm; Shabbos is a testimony that Hashem created His world in six days. And why are they called pikudim? Because within them is deposited (mufkad) the lesson they convey: Hashem deposited in this mitzvah the lesson of the Exodus from Egypt, and in eating matzah He deposited the lesson of the redemption from Egypt, and so forth.
Thus, "You have commanded Your precepts" - You commanded them so that through them, we may "keep diligently." For the testimonies themselves are what occurred in history - testimony that the Exodus took place, testimony that Hashem created His world in six days, testimony that Hashem dispenses reward and punishment; and the pikudim are the practical mitzvos that we perform in commemoration of that testimony. These must be kept diligently, like a wrapped bundle containing precious stones and pearls. Why? Because within these precepts lie the Exodus from Egypt and the creation of the world in six days.
From this you can understand why one who does not observe Shabbos and desecrates it publicly is regarded halachically like a non-Jew. Why? Because he has lost the pearl inside the precept. What is deposited inside the precept? The testimony. Shabbos serves as testimony that Hashem created His world in six days; if you lose the precept and fail to observe Shabbos, the testimony is lost to you - you have no testimony that Hashem created His world in six days, and whoever fails to bear witness to this is considered to deny the Creation. This applied primarily in earlier times, whereas nowadays people often act out of desire or pursuit of pleasure: someone makes Kiddush, professes belief, and then goes to a soccer match, seeing no contradiction. Yet in the definition of Chazal, one who publicly desecrates Shabbos denies the Creation. Similarly, one who does not put on tefillin acts as if saying: "Hashem did not bring us out of Egypt with a strong hand, and therefore I do not put on tefillin." It turns out, therefore, that when you do not diligently safeguard the precepts, you lose what is deposited within them: the testimony of the Exodus, the testimony of Creation, and the testimony of reward and punishment.
The opening of the psalm sets before us the ladder of ascent: "Praiseworthy are those whose way is wholesome, who walk in the Torah of Hashem" - there is no wholeness without Torah study, for an unlearned person cannot be truly scrupulous regarding sin. "Praiseworthy are those who keep His testimonies, who seek Him with all their heart" - one who safeguards the testimonies received from his ancestors serves Hashem with a whole heart and not with a divided heart. "They also do no iniquity; they walk in His ways" - it is not enough to turn away from evil without doing good, and there is no reward for avoidance that was never put to the test; on the other hand, one who seeks Hashem with all his heart is guaranteed heavenly assistance not to stumble, as "one who comes to purify himself is aided from Above." And finally, "You have commanded Your precepts, to keep them diligently" - the mitzvos are like a bundle containing pearls, in which are deposited the great testimonies of the Exodus, the Creation, and reward and punishment; therefore, they require diligent safeguarding, not merely a promise of "I'll try."