unix

How do I set my MySQL session to use vi mode?

Using MySQL in vi mode is very useful as you can easily search for, modify, and run previous commands quickly. Enabling it is very simple.

It’s just a matter of creating a .inputrc file in your home directory and adding the following:

set editing-mode vi

or alternately you could use this:

$if mysql
set editing-mode vi
$endif

Click to comment

Leave a Reply

Your email address will not be published. Required fields are marked *

To Top