Abdullah bin Umar (may Allah be pleased with him) narrates from Sayyiduna Umar (may Allah be pleased with him) that the Prophet (peace and blessings be upon him) caught up with him in a caravan while he was swearing by his father. He (peace and blessings be upon him) said: "Allah has forbidden you from swearing by your fathers. Whoever wishes to swear, let him swear by Allah or remain silent."
Hadith Referenceالسنن الكبرى للبيهقي / كتاب الأيمان / 19826