At the end of your main program/game loop after everything is updated, all the inputs are handled you are gonna be going
window.clear();
window.draw(background);
//draw anything else after your background if first drawn
window.draw(player);
window.display();
there is no way getting around it. If you don't always clear your screen and redraw everything then you get persistent artifacts visually occurring.