if some sperm gets by and gets retained would it have an effect on getting spayed?
You're definately not thinking like a doggie person!

The answer would be YES and NO. It's not directly related to the retention of sperm, but in the female herself. if she were to be spayed the way most reptiles are spayed, the part of the reproductive system that processes fertilization would be removed, but not the chamber eggs are formed in. (in people lingo.......the ovaries are removed, the womb is left) This would allow for the formation of eggs, without a way to expell them, therefore requiring more surgery.
Spaying is always a drastic measure, and not one I recommend, unless the direct cause is life threatening such as extreme binding or breach of tract. We've worked with a few dragons laying infertiles in an attempt to stop them, and mating them seems to be the most natural and effective. It means that she will stay eggs, probably 1-3 more clutches, and you'll definately have to watch her hydration, fat stores and calcium intake, but the associated risk factors are lower than with infertiles.