Move around in insert mode in old school vi

I am using an old school vi.

: uname -a
SunOS ah5719006ub002 5.10 Generic_150400-64 sun4u sparc SUNW,SPARC-Enterprise

I would like to be able to move around in insert mode in vi. Is that possible? It keeps switching back to command mode when I try to move around.

Hi,

I don't have a Solaris 10 box to hand to test with, but if you're using the proper Sun-provided vi rather than vim, then I think the answer probably is "you can't". Certainly back on Solaris 2.x, I always remember having to exit Insert mode, navigating to where I wanted the cursor to be, and then having to go back into Insert mode. It wasn't possible to navigate or move the cursor whilst in Insert mode in Sun vi.

So unless this changed somewhere along the line to Solaris 10, I think you'll just have to get used to pressing Escape, moving your cursor, then going back into insert mode. To be honest, this is a habit I still have today even when using vim or Linux, where the cursor keys do work in Insert mode. Having spent my very earliest UNIX years moving around in Solaris vi purely in command mode, exiting insert mode before moving is a habit I never really managed to break !

In the classic vi the cursor keys only work in command mode.
But the backspace key works (erases the character to the left) only in insert mode.
If it does not work then check if Ctrl-H works. And check your terminal settings with
stty -a