2 Samuel 7:18
ESV
Then King David went in and sat before the Lord and said, "Who am I, O Lord God, and what is my house, that you have brought me thus far?
NIV
Then King David went in and sat before the Lord, and he said: "Who am I, Sovereign Lord, and what is my family, that you have brought me this far?
NASB
Then David the king came in and sat before the Lord, and he said, 'Who am I, Lord God, and who are the members of my household, that You have brought me this far?
CSB
Then King David went in, sat in the Lord’s presence, and said, Who am I, Lord God, and what is my house that you have brought me this far?
NLT
Then King David went in and sat before the Lord and prayed, 'Who am I, O Sovereign Lord, and what is my family, that you have brought me this far?
KJV
Then went king David in, and sat before the Lord, and he said, Who am I, O Lord God? and what is my house, that thou hast brought me hitherto?
NKJV
Then King David went in and sat before the Lord; and he said: “Who am I, O Lord God? And what is my house, that You have brought me this far?
What does 2 Samuel 7:18 mean?
When the chapter opened, David sat in his exquisite house. This was made from the cedars of Lebanon by craftsmen sent by the king of Tyre. As he looked over the workmanship, David thought about the ark of the covenant, sitting in a tent nearby. The imbalance was obvious, so David talked to his advisor, the prophet Nathan, about building a proper temple (2 Samuel 7:1–3).Now, David sits in that tent, praising God. God doesn't want David to build him a "house." God wants to build David a house: a son to take the throne after him, and an everlasting legacy (2 Samuel 7:4–17).
David affirms what God told him. God took him "from the pasture, from following sheep" to be the prince of Israel (2 Samuel 7:8). David was a nobody, but God chose to defeat his enemy's countless times and give him the respect of nations (2 Samuel 7:9). David is from the line of Rahab, a prostitute of Jericho, and Ruth, a woman from Israel's enemy Moab (Matthew 1:5–6). David was the youngest son of seven sons (1 Chronicles 2:13–15). If God wanted the crown to go to a descendant of Judah (Genesis 49:10), He could have chosen from thousands of men. But God chose David.
David feels compelled to respond to the Lord, to speak to Him directly. It seems likely that David may have written this humble prayer of thankfulness down, since he seemed to have marked many of the important events in his life with a special psalm, song, or poem. David's humble gratitude is the only appropriate response to God's grace and generosity. Even the smallest amount of reflection should help us to remember that we deserve none of the good gifts God has given us so far and promises to give us forever (Romans 11:33–36).