Yes, lack of ejaculation is linked to prostate cancer - it's not a simple linear relationship for sure, and as often in medicine, the results are open to interpretation. It seems that frequent ejaculations at a younger age are linked to fewer incidents of prostate cancer.
See...