Page 1 of 1

How to set Default Editor for vsql in Linux

Posted: Wed Dec 18, 2013 4:07 am
by askh01
Hi,

What command to use to set the default editor to "vi" in vsql? I tried the following and seems not working

export VSQL_EDITOR=vi

Thanks,

Re: How to set Default Editor for vsql in Linux

Posted: Wed Dec 18, 2013 7:55 pm
by JimKnicely
Hi,

Where are you running the export command?

Re: How to set Default Editor for vsql in Linux

Posted: Thu Dec 19, 2013 2:34 am
by askh01
I'm running it on "$" prompt

$ export VSQL_EDITOR=vi

Re: How to set Default Editor for vsql in Linux

Posted: Thu Dec 19, 2013 4:23 am
by JimKnicely
Hi,

So, after setting the VSQL_EDITOR variable to vi, which editor is launched in vsql when you type \e ?

Is vi an alias on your system?

For example, on mine, vi is an alias for vim:

Code: Select all

[dbadmin@vtest01 ~]$ which vi
alias vi='vim'
	/usr/bin/vim