It is narrated from Sayyiduna Malik bin Hubayrah (may Allah be pleased with him); he said that the Messenger of Allah (peace and blessings be upon him) said: "There is no Muslim over whose funeral three rows pray except that he has made (Paradise) obligatory (for himself)." The narrator said: And when Malik faced the people of a funeral, he would divide them into three rows.
Hadith Referenceالمعجم الكبير للطبراني / باب الميم / 16714