Ellicott's Commentary for English Readers - 2 Samuel 22:16
(16) Of the sea.—Psalms 18:0, “of waters.” There are several such slight differences between 2 Samuel 22:15-16, and the parallel verses in the psalm, which mark the two as distinctly different recensions. The most striking change is that of the last pronoun from “his” to “thy in the psalm, as appropriate to its use in public worship. read more
John Dummelow's Commentary on the Bible - 2 Samuel 22:1-51
David’s Thanksgiving PsalmThis beautiful poem has also been preserved as the Eighteenth Psalm. It probably belongs to the earlier portion of David’s reign, when his conquests and God’s promise (2 Samuel 7) were still fresh in his mind. See on Psalms 18. read more