Throughout the Old Testament, particularly in the Psalms, the subject will speak of thirsting, longing for God.
Water is the essential element for man. He can live for longer periods of time without food, but without water, a man will be driven to drink just about anything.
This internal, eternal thirst breaks out in other parts of the Psalms, not just when David was fleeing his enemies.
"To the chief Musician, Maschil, for the sons of Korah. As the hart panteth after the water brooks, so panteth my soul after thee, O God." (Psalm 42: 1)
Yet in Isaiah, we learn that God is not only aware of our thirst, but promises to take care of it:
"And the parched ground shall become a pool, and the thirsty land springs of water: in the habitation of dragons, where each lay, shall be grass with reeds and rushes." (Isaiah 35: 7)
"The beast of the field shall honour me, the dragons and the owls: because I give waters in the wilderness, and rivers in the desert, to give drink to my people, my chosen." (Isaiah 43: 20)
"1Ho, every one that thirsteth, come ye to the waters, and he that hath no money; come ye, buy, and eat; yea, come, buy wine and milk without money and without price.
2Wherefore do ye spend money for that which is not bread? and your labour for that which satisfieth not? hearken diligently unto me, and eat ye that which is good, and let your soul delight itself in fatness.
3Incline your ear, and come unto me: hear, and your soul shall live; and I will make an everlasting covenant with you, even the sure mercies of David." (Isaiah 55: 1-3)
Why do we not thirst anymore? Because of Jesus, who has given us His Spirit!
"13Jesus answered and said unto her, Whosoever drinketh of this water shall thirst again: 14But whosoever drinketh of the water that I shall give him shall never thirst; but the water that I shall give him shall be in him a well of water springing up into everlasting life." (John 4: 13-14)
In fact, Jesus would thirst, so that we would never have to every again:
"37In the last day, that great day of the feast, Jesus stood and cried, saying, If any man thirst, let him come unto me, and drink. 38He that believeth on me, as the scripture hath said, out of his belly shall flow rivers of living water. 39(But this spake he of the Spirit, which they that believe on him should receive: for the Holy Ghost was not yet given; because that Jesus was not yet glorified.)" (John 7: 37-39)
"After this, Jesus knowing that all things were now accomplished, that the scripture might be fulfilled, saith, I thirst." (John 19: 28)
Because Jesus thirsted on the Cross, it was a signal that He had fulfilled the Perfect Work of dying for our sins and granting us His Spirit, His Life!
No matter what you may read in the Old Testament, remember that Jesus fulfilled the Old and brought in the New. The Psalmist may have thirsted, but because of Jesus, you will never have to.