حَدَّثَنَا مُحَمَّدُ بْنُ يَحْيَى ، حَدَّثَنَا فَهْدُ بْنُ حَيَّانَ ، حَدَّثَنَا هَمَّامٌ ، عَنْ قَتَادَةَ ، عَنْ أَنَسٍ ، قَالَ : قَالَ رَسُولُ اللهِ - صَلَّى اللهُ عَلَيْهِ وَسَلَّمَ - : مَثَلُ الْمُؤْمِنِ مَثَلُ السُّنْبُلَةِ تَمِيلُ أَحْيَانًا وَتَقُومُ أَحْيَانًا .
It is narrated from Sayyiduna Anas (may Allah be pleased with him) that the Messenger of Allah (peace and blessings be upon him) said: "The example of the believer is like an ear of grain which (under the blows of trials) sometimes bends to one side and sometimes stands straight."
Related hadith on this topic