When a doctor examines us to see where the pain is, he/she may often touch an area of our bodies and ask, "Does this hurt?" Without X-rays or MRI's a doctor has to probe to find the sore spot before he/she can deal with the issue. When God examines our hearts He doesn't have to ask whether something hurts or not, for He already knows where the infection is and "touches" the sore spot without guessing! And when He does touch that spot He leaves us with no doubt that He has identified the error and calls for us to act and deal with the troubled area. His touch, call it "conviction," sure make us grimace with pain, but it calls us to see the issue that needs to be dealt with.
So, in verse 24, David goes beyond the request for a thorough examination. Now he wants to know the results, good and bad alike. And if there is something "bad" then David's desire is that the Lord would show him just what it is. Now, an interesting point: in this verse David doesn't necessarily ask for "healing" or cleansing. He does so in Psalm 51:7 where the sin was so clearly seen and the pain was so awfully felt! Here in Psalm 139 David asks for the Lord to "lead me in the way everlasting." That "way" is God's way. David knew that a complete change of direction was necessary, which, by the way, is a pretty good definition of true repentance!
Am I willing for God to examine me thoroughly? And, if so, am I ready to ask the Lord to change the direction of my life, including changing the affection of my heart and the priorities of my life?