It is narrated from Sayyiduna Sahl bin Sa'd (may Allah be pleased with him) that the Messenger of Allah (peace and blessings be upon him) said: "When one of you goes to relieve himself, let him neither face the qiblah nor turn his back towards it."
Hadith Referenceالمعجم الكبير للطبراني / باب السين / 5714