It is narrated from Sayyiduna Abu Sa'id al-Khudri (may Allah be pleased with him) that when the Prophet (peace and blessings be upon him) said 'Sami'allahu liman hamidah', he would say: "O Allah, our Lord, to You belongs praise, such as fills the heavens and fills the earth and fills whatever else You will thereafter. O You who are worthy of praise and glory, the truest thing Your servant has said is that we are all Your servants. None can withhold what You give, and the greatness of one possessed of greatness is of no benefit to him before You."
(b) The same words are also reported through another chain, except that in it: when he (peace and blessings be upon him) raised his head from bowing he would say 'Rabbana lakal-hamd' (Our Lord, to You belongs all praise), and it also has the addition that he would also recite 'Wa la mu'tiya lima mana'ta' (and none can give what You withhold).
Hadith Referenceالسنن الكبرى للبيهقي / كتاب الصلاة / 2609