arrow keys are not functional in sqlplus

烈酒焚心 提交于 2019-12-02 20:06:39

You can use a third party utility called rlwrap.

rlwrap is a readline wrapper, a small utility that uses the GNU readline library to allow the editing of keyboard input for any other command. It maintains a separate input history for each command, and can TAB-expand words using all previously seen words and/or a user-specified file.

So you will be able to use arrows and also get a command history as a bonus.

After you have installed the utility run sqlplus the following way:

$ rlwrap sqlplus
user1755394

As Johnny suggested, you can install the rlwrap utility to manage command history for any other command, including sqlplus. Another useful trick is to alias the wrapped version of sqlplus so you don't have to type rlwrap sqlplus every time.

alias sqlplus="rlwrap sqlplus"
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!