وَحَدَّثَنِي عَنْ مَالِكٍ، عَنْ نَافِعٍ، أَنَّ عَبْدَ اللَّهِ بْنَ عُمَرَ، كَانَ يَقُولُ مَنْ نَسِيَ صَلاَةً فَلَمْ يَذْكُرْهَا إِلاَّ وَهُوَ مَعَ الإِمَامِ فَإِذَا سَلَّمَ الإِمَامُ فَلْيُصَلِّ الصَّلاَةَ الَّتِي نَسِيَ ثُمَّ لِيُصَلِّ بَعْدَهَا الأُخْرَى ‏.‏

Yahya related to me from Malik from Nafi that Abdullah ibn Umarused to say, "Someone who only remembers that he has forgotten aprayer when he is praying the next prayer behind an imam, should praythe prayer he has forgotten after the imam has said the taslim, andthen pray the other one again." Translation Not Available

Book Ref: Muwatta Imam Malik Book 9 Hadith 411
Web Ref:  Muwatta Imam Malik Book 9 Hadith 80