98 Toyota Corolla automatic not shifting properly

There are two things going on that may or may not be related. The car has 95k miles.



Last summer I noticed after engaging the cruise control the first time it had to accelerate it would do so but then the engine RPM would rev up high and stay there. To stop it I would have to disengage the cc. I do little highway driving so I just decided to put that repair on the back burner for a while.



The second thing is much more troubling. Last week I had a new O2 sensor (the first one) replaced because the check engine light came on (after another mechanic used seafoam in the car) and it was guzzling gas.



Since then I’ve noticed at the 30mph mark the car doesn’t want to shift. It just sits at about 30 no matter how much gas I give it. Sometimes if I let up on the gas and then try again it shifts ok. This morning I noticed it happening on take off at about 5 mph. I’m thinking that’s between 1st and 2nd gear.



Questions:



Could these two events (the cc and shifting) be related?



Could replacing the O2 sensor cause this?



Is there a sensor that detects when to shift that may be out?



Do you have any other ideas about what could be the problem?



Thank you, Debbie

Update: It seems this is happening at any speed randomly. Upon acceleration the car doesn’t go and/or looses power. No weird noises or vibrations. I’m thinking the fuel line is blocked. I don’t think the fuel filter has been changed out ever. I bought the car at 50k and it as 95k now and I haven’t changed it.