A 9 year old is old enough to understand that discipline is for the purpose of changing behavior to make him a better person. (you will need to explain it, but he should understand)
Talk to your son about why it's important for him to treat women with respect. Do this in a way that he expresses his desire to treat women with respect. Then tell him that when he's sassing you, it's not respectful. Ask him if he would like to change his disrespectful behavior. When you get a "yes" from him, then ask him what would be a good reminder for him, that will help him learn this valuable life skill? Give him some ideas - then consistently do that thing when he is sassy to you. Perhaps for you to look him in the eye and remind him to speak kindly to you? (then make him speak kindly).
http://www.helpfulhallies.com has some cool "obedience sprays" that are a great reminder to kids who are trying to change a certain behavior.
I found that when my kids wanted to change a behavior and helped me to plan how they would learn, that they had a vested interest in changing their behavior.
One thing I always required was for my children to "say it the right way." I'm sure they heard me say this so many times. Never let him get away with his last words being the sassy ones.
In other words, don't simply punish without requiring the right behavior. Otherwise he learns that he just has to withstand the punishment, and there is no life discipline learned. Always require that he "say it the right way." You may even need to say the words you want him to say, in a calm way and have him repeat them.
Remember that when he is sassing you, it is a great opportunity for you to help him learn to be respectful. Try not to take it personally, or it becomes a battle, but rather see it just like anything else you teach him.
I hope that helps.
T. "Ta-Dah Mom" Camp