Nathan told David a parable from the Lord that exposed his guilt and informed him, Bathsheeba's child would die by the hand of God. David confessed his sin and his life was spared. After their son died, David comforted Bathsheeba and she later bore Solomon.