Psalm 119:71 in the King James Version
It is good for me that I have been afflicted; that I might learn thy statutes.
Context
70 Their heart is as callous as the fat, but I delight in your law.
71 It is good for me that I have been afflicted, that I may learn your statutes.
72 The law of your mouth is better to me than thousands of pieces of gold and silver. YODH