Yes, they can. Prostatitis, an enlarged prostate (benign prostatic hyperplasia), and similar conditions can have a negative impact on a man’s sexual health, including potential issues with erectile function. In particular, these problems can induce stress, anxiety, and depression, which can also affect sexual function and lead to erectile dysfunction.