This is a very strange and unusual order. Lazarus is still in the grave, and the thanksgiving precedes the miracle of resurrection. I thought that the thanksgiving would have risen when the great deed had been wrought, and Lazarus was restored to life again. But Jesus gives thanks for what He is about to receive.
The gratitude breaks forth before the bounty has arrived, in the assurance that it is certainly on the way. The song of victory is sung before the battle has been fought. It is the sower who is singing the song of the harvest home. It is thanksgiving before the miracle! Who thinks of announcing a victory-psalm when the crusaders are just starting out for the field? Where can we hear the grateful song for the answer which has not yet been received? Praise is really the most vital preparatory ministry to the working of the miracles. Miracles are wrought by spiritual power; the supernatural power of God.
Nothing so pleases God in connection with our prayer as our praise, and nothing so blesses the man who prays and then praise for what He is yet to receive.