Have you checked that the shift cable is in good condition and not frayed or kinked? Replace it if there is any question. If that doesn't explain or fix the problem then:
Wash out the shifter mechanism with a deluge of WD-40, mineral spirits or similar. Remove the cables and spray the solvent into every opening and crack you can find. Drain and repeat a couple of times. Blow it as dry as possible and then lube with Tri- Flow or similar light oil.
If that doesn't fix the problem, you are likely in the market for replacements.