Linux.backspace garbled

Source: Internet
Author: User
Tags clear screen delete key

Linux.backspace garbled

A workaround for using BACKSPACE keys in Linux environment Sqlplus 2008-04-30 16:32

Using Sqlplus in a Linux environment, a string of garbled characters is often present when you delete (BACKSPACE). Garbled is the result of Oracle's Sqlplus not using the GNU ReadLine Library. There are two ways to resolve this: 1. To use the back Delete key (BACKSPACE), hold down the CTRL key 2 at the same time. Set environment variables under BASH: $ stty erase ^h or add Stty erase ^h to. Bash_profile.

--

Solve the problem of sql*plus, arrow keys and other non-use

Sql*plus, the BACKSPACE bar backspace for ^h, up and down right to the left is ^[[a, ^[[b, ^[[c, ^[[d, not to mention on the next turn on the record.

In fact, the setup backspace ^h can be used Stty, in Stty--help, you can see the definition of some keys, such as erase is to delete a character, kill is the delete line, we define BACKSPACE bar, in your shell configuration file (such as ~/. BASHRC), add the following line:

Stty Erase ^h

To set the delete whole row, you can also

Stty Kill ^u

This way, we press ctrl+u, we can clear the whole line ~ ~

Then, up and down the direction of the key, upside down, and so on, how to achieve, Linux, in addition to SQL developer or JDeveloper, Sql*plus is a very useful Oracle user end under the terminal.

Ha, with Rlwrap, regardless of yum, apt Update or RPM, dpkg installation or source code compilation, here is not the introduction. The rlwrap itself is a shell that can run any command you provide to it, including parameters, and add historical browsing functionality, which is released based on the GPL.

Transferred from: http://hi.baidu.com/searchsprit/item/0b20b310501d23e55e53b17c

The way to use it is rlwrap command,...

Can be added in the shell's configuration file (such as ~/.BASHRC)

Alias sqlplus= ' Rlwrap sqlplus '

To enable sqlplus like Bash to support the ability to scroll up and down the history record.

List some of these commands and look at man or Google in detail:

Ctrl+a:ahead, to the top of the line, the equivalent of Home

Ctrl+e:end, to the end of the line, equivalent to end

Ctrl+b:behind, back one character, equivalent to left

Ctrl+f:forward, forward a child into, equal to right

Ctrl+p:prev., previous row history, equivalent to up

Ctrl+n:next., the next line of history, equivalent to down

Ctrl+u:undo, undo operation, this line is emptied.

Ctrl+w: Cut

Ctrl+y: Pasting

Ctrl+l:clear, clear screen

Linux.backspace garbled (Turn)

Related Keywords:

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.