You do not need to sand your stained woodwork before priming and painting. Because wood is porous, it is suited for primer and paint adhesion.
As long as you remove dust with a sticky tackcloth, you should have no trouble painting over unsanded stained woodwork as long as you use an oil-based primer.
You must sand stained woodwork if it is coated with a protective topcoat of varnish or wood sealer. Because these coatings are non-porous, they will not accept adhesion.
Use sandpaper to remove these coatings before application, or the new painted finish will flake and peel.
You do not need to sand stained wood unless it is coated with varnish or wood sealant. You can recognize this coating by its sheen.
If your stained woodwork appears glossy, you must sand it. Never attempt to prime and paint over varnish or wood sealant, or the finish will eventually fail.
Always sand along with the grain of the wood to prevent splintering.