All perfect praise be to Allaah, The Lord of the Worlds. I testify that there is none worthy of worship except Allaah, and that Muhammad, sallallaahu ‘alayhi wa sallam, is His slave and messenger.
Allaah The Almighty Says (what means): {And He gave you from all you asked of Him.}[Quran 14:34]
This verse has no relation with the supplication. Ibn Katheer said, “{And He gave you from all you asked of Him.}”, means He prepared for you what you need in all your circumstances of what you ask him according to your circumstances.”
As regards the supplication, Allaah The Almighty may or may not respond to it because of the existence of an obstacle of the obstacles which prevent the supplication from being answered. In case Allaah The Almighty responds to the supplication, it is not necessary that He gives the one who supplicates the same thing that he supplicated for. Rather, the matter depends on Allaah’s Knowledge and Wisdom. It might be that the one who supplicates gets what is more beneficial for him than what he asked for. Abu Sa’eed narrated that the Prophet said: "Any Muslim who supplicates without entailing a sin or breaking ties with kinship (in his supplications) except that Allaah gives him one of these three things: either his supplication is granted immediately in this world, or that it will be kept for him for the Hereafter, or that He repels from him an evil equivalent to that which he supplicated for.”
Allaah Knows best.