There are multiple questions with the verse's final two phrases (בִּמְגִלַּת־סֵ֝֗פֶר and כָּת֥וּב עָלָֽי). The difficulty of the second half of Ps 40:8 led the translators of the NEB to omit it as a later scribal insertion.
However, most translations interpret מְגִלַּת־סֵ֝֗פֶר either as a reference to an unspecified book or to the Torah.
Then I said, “Behold, I have come; in the scroll of the book it is written of me: (ESV; cf., NIV, NASB, NET, Luther 2017)
And so I answered, “Here I am; your instructions for me are in the book of the Law. (GNT; cf., HFA, NGÜ, GNB)
The verse's last two words (כָּת֥וּב עָלָֽי) are also understood differently.
Then I said, "Here I am, I have come-- it is written about me in the scroll. (NIV; cf., NLT, ESV, NRSV)
and so I answered, “Here I am; your instructions for me are in the book of the Law. (GNT; cf., NFC, PDV)
Argument Maps[]
The Scroll of the Book[]
Many modern translations render מגלת ספר as a "scroll" (cf., NIV, NET) or "scroll of the book" (ESV, NASB, NRSV).
The Book of the Law (preferred)[]
Some translations interpret בִּמְגִלַּת־סֵפֶר as a reference to the Torah (cf., GNT, NGÜ, etc.).
About Me[]
Some translations interpret the prepositional phrase as a reference to the scroll's content (i.e., about the psalmist).
Then I said, "Look, I have come. As is written about me in the Scriptures: (NLT)
Instructions for Me (preferred)[]
Some modern translations understand the prepositional phrase as an indication of the obligations the psalmist must fulfill.
and so I answered, “Here I am; your instructions for me are in the book of the Law. (GNT)
Conclusion (B)[]
The GNT offers the most probable interpretation of this verse:
And so I answered, “Here I am; your instructions for me are in the book of the Law. (GNT)
Although מְגִלַּת־סֵפֶר is not a common way to refer to the Torah, (1) the phrase functions as a synonym to תֹורָתְךָ in v. 9b, and (2) the psalmist's focus immediately shifts to his delight in doing what pleases YHWH (v. 9a). Additionally, while ספר can refer to a generic book, it can also clearly refer to the Torah even if used without a definite article (cf., 2 Kgs 22:10). Finally, the Targum offers an interpretive tradition that understood the phrase as a reference to the Torah.
The prepositional phrase (עָלָי) likely indicates the obligations placed on the psalmist by the contents of the scroll (מגלת ספר). Two pieces of evidence support this position. First, the phrase is used similarly in 2 Kgs 22:13. Second, Ps 40:8 alludes to 1 Sam 15:22 where Samuel rebukes Samuel for relying on sacrifices rather than obedience.
A final question remains about the meaning of this verse: why use an ambiguous term as a reference to the Torah? As discussed in the argument map above, Hebrew poetry frequently moves from a generic concept to a more specific example. Robert Alter refers to this as intensification (Alter 2011, 75-80). By delaying an explicit reference to the Torah, David poetically emphasizes his desire to obey YHWH. It is not just any book of instruction, it is YHWH's Torah! Furthermore, the Torah is not simply concerned with sacrifices. It is also filled with obligations for ethical living.
"Then I said, 'Behold, I have entered eternal life when I am occupied with the scroll of the book of the Law, which was written for my sake.'"[9]
Modern[]
Omits Ps 40:8b[]
I would have said, “Here I am” (NEB)
Follows the LXX[]
Entonces dije: He aqui, vengo! En la cabecilla del rollo esta escrito acerca de mi: (S21)
Scroll of the Book[]
Then I said, "Here I am, I have come-- it is written about me in the scroll. (NIV)
Then I said, “Behold, I have come; in the scroll of the book it is written of me: (ESV)
Then I said, "Behold, I come; In the scroll of the book it is written of me. (NASB)
Then I say, "Look! I come! What is written in the scroll pertains to me. (NET)
Then I said, “Here I am; in the scroll of the book it is written of me. (NRSV)
Then I said,“See, I will bring a scroll recounting what befell me.” (JPS 1985)
Da sprach ich: Siehe, ich komme; im Buch ist von mir geschrieben: (Luther 2017)
Da sprach ich: Siehe, ich komme; in der Rolle des Buches steht über mich geschrieben. (ELB)
Da habe ich gesagt: Siehe, ich komme. In der Buchrolle steht es über mich geschrieben. (EÜ)
Da sprach ich: Sieh, ich bin gekommen, in der Schriftrolle steht geschrieben, was für mich gilt. (ZÜR)
Alors j'ai dit : Je viens avec le livre-rouleau écrit pour moi. (NBS)
Alors je dis : Voici je viens Avec le rouleau du livre écrit pour moi (NVSR)
Alors j’ai dit : Voici, je viens, dans le rouleau du livre, il est question de moi. (BDS)
Alors j’ai dit : « Me voici, je viens à toi. Dans le rouleau d’un livre , je trouve écrit ce que je dois faire. » (PDV)
Alors j'ai dit : « Je viens moi-même à toi. Dans le livre je trouve écrit ce que je dois faire. » (NFC)
Alors j’ai dit: «Me voici, je viens – dans le rouleau du livre il est écrit à mon sujet – (S21)
Entonces dije: «He aquí, vengo; en el rollo del libro está escrito de mí; (RVR)
Por eso dije: «Aquí me tienes —como el libro dice de mí—. (NVI)
Por eso he dicho: Aquí estoy, tal como el libro dice de mí. (DHH)
Book of the Law[]
Then I said, "Look, I have come. As is written about me in the Scriptures: (NLT)
And so I answered, “Here I am; your instructions for me are in the book of the Law. (GNT)
Da habe ich gesagt: »Hier bin ich! Im Buch des Gesetzes ist von mir die Rede. (NGÜ)
Darum sage ich: Mein Gott, ich bin bereit, zu tun, was du von mir erwartest, so wie es für mich aufgeschrieben ist im Buch des Gesetzes. (GNB)
About Me[]
Then I said, "Here I am, I have come-- it is written about me in the scroll. (NIV)
Then I said, "Look, I have come. As is written about me in the Scriptures: (NLT)
Then I said, “Behold, I have come; in the scroll of the book it is written of me: (ESV)
Then I said, "Behold, I come; In the scroll of the book it is written of me. (NASB)
Then I said, “Here I am; in the scroll of the book it is written of me. (NRSV)
Then I say, "Look! I come! What is written in the scroll pertains to me. (NET)
Then I said,“See, I will bring a scroll recounting what befell me.” (JPS 1985)
Da sprach ich: Siehe, ich komme; im Buch ist von mir geschrieben: (Luther2017)
Da habe ich gesagt: »Hier bin ich! Im Buch des Gesetzes ist von mir die Rede. (NGÜ)
Da sprach ich: Siehe, ich komme; in der Rolle des Buches steht über mich geschrieben. (ELB)
Da habe ich gesagt: Siehe, ich komme. In der Buchrolle steht es über mich geschrieben. (EÜ)
Da sprach ich: Sieh, ich bin gekommen, in der Schriftrolle steht geschrieben, was für mich gilt. (ZÜR)
Alors j'ai dit : Je viens avec le livre-rouleau écrit pour moi. (NBS)
Alors je dis : Voici je viens Avec le rouleau du livre écrit pour moi (NVSR)
Alors j’ai dit : Voici, je viens, dans le rouleau du livre, il est question de moi. (BDS)
Alors j’ai dit: «Me voici, je viens – dans le rouleau du livre il est écrit à mon sujet – (S21)
Entonces dije: «He aquí, vengo; en el rollo del libro está escrito de mí; (RVR)
Por eso dije: «Aquí me tienes —como el libro dice de mí—. (NVI)
Por eso he dicho: Aquí estoy, tal como el libro dice de mí. (DHH)
Entonces dije: He aqui, vengo! En la cabecilla del rollo esta escrito acerca de mi: (S21)
Instructions for Me[]
And so I answered, “Here I am; your instructions for me are in the book of the Law. (GNT)
Deshalb antworte ich: »Herr, hier bin ich! Was im Buch des Gesetzes steht, das gilt mir. (HFA)
Darum sage ich: Mein Gott, ich bin bereit, zu tun, was du von mir erwartest, so wie es für mich aufgeschrieben ist im Buch des Gesetzes. (GNB)
Alors j’ai dit : « Me voici, je viens à toi. Dans le rouleau d’un livre , je trouve écrit ce que je dois faire. » (PDV)
Alors j'ai dit : « Je viens moi-même à toi. Dans le livre je trouve écrit ce que je dois faire. » (NFC)
Secondary Literature[]
Alexander, Joseph Addison. 1864. Commentary on Psalms. Grand Rapids: Kregel Publications.
Alter, Robert. 2011. The Art of Biblical Poetry. Philadelphia, PA: Basic Books.
Craigie, Peter C. 1983. Psalms 1–50. WBC 19. Waco, TX: Word.
DeClaissé-Walford, Nancy L., Rolf A. Jacobson, and Beth LaNeel Tanner. 2014. The Book of Psalms. The New International Commentary on the Old Testament. Grand Rapids, Michigan: William B. Eerdmans Publishing Company.
Jamieson, Robert. n.d. A Commentary Critical, Practical and Explanatory, on the Old and New Testaments. New York: F. H. Revell.
Kirkpatrick, Alexander Francis. 1897. The Book of Psalms. Cambridge: Cambridge University Press.
Kraus, Wolfgang. 2019. “Psalm 40(39):7–9 in the Hebrew Bible and in the Septuagint, with Its Reception in the New Testament (Heb 10:5–10).” In XVI Congress of the International Organization for Septuagint and Cognate Studies, edited by Wolfgang Kraus, Gideon R. Kotzé, and Michaël N. van der Meer, 119–32. :Stellenbosch, 2016. Society of Biblical Literature.