When car is first started after sitting for long periods (overnight, all day) it clunks into gear and starts out in 2nd, won't shift. Drive it for a mile or two, restart it a few times and then it shifts okay. Except for occasionally it simply goes out of gear while driving. Sometimes it seems like when you have to slow down for traffic (at a light) without coming to a complete stop it screws up.
Staying in second gear is called "limp mode" that allows you to drive slowly to a repair shop without needing a tow truck.
In general, when it starts out in second gear without going through an up-shift, it's usually a speed sensor or other electrical problem. When it doesn't go back to second gear until or during an up-shift, that is usually caused by slippage of a clutch pack and will lead to the need to a rebuild.
There WILL be at least one diagnostic fault code stored in the Transmission Computer. An experienced transmission mechanic will know how to proceed after reading those codes.