Difference between revisions of "Configure rlwrap"
Jump to navigation
Jump to search
Line 40: | Line 40: | ||
<pre> | <pre> | ||
alias sqlplus='rlwrap -D2 -irc -b'\''"@(){}[],+=&^%#;|\'\'' -f ~/Documents/Oracle_Scripts/tpt/setup/wordfile_11gR2.txt $INSTANT_CLIENT_PATH/sqlplus' | alias sqlplus='rlwrap -D2 -irc -b'\''"@(){}[],+=&^%#;|\'\'' -f ~/Documents/Oracle_Scripts/tpt/setup/wordfile_11gR2.txt $INSTANT_CLIENT_PATH/sqlplus' | ||
+ | </pre> | ||
+ | |||
+ | * To use | ||
+ | |||
+ | <pre> | ||
+ | SQL> select * from dba | ||
+ | |||
+ | [tab] to complete | ||
+ | |||
+ | [tab] [tab] to show all possible values | ||
</pre> | </pre> | ||
Revision as of 15:38, 16 May 2012
Configure rlwrap on Mac OS X
- Download the installation file from http://www.macports.org/install.php, Choose Lion.
- Install the downloaded package installation file.
- During the installation, the package will update the profile file to include the following:
export PATH=/opt/local/bin:/opt/local/sbin:$PATH
- So you may need to source the updated profile before proceed with rlwrap installation. Otherwise, when running to install the rlwarp, it may say that *port* is not found.
. ~/.bash_profile
- Install rlwrap
$ sudo port install rlwrap
- If it says that rlwrap cannot be found, try to get update first.
$ sudo port selfupdate
- Once successfully installed, you now can use rlwrap, for example,
$ rlwrap sqlplus user@sid
- Or you can create an alias for as a shortcut.
alias sqlplus='rlwrap sqlplus'
- In addition, Tanel Poder has enhanced the rlwrap by having capability, in addition to recalling history, but also to search keywords in Oracle.
- This is the sample. You can find out more from setup/README_rlwrap.txt file in the tpt_public.zip
alias sqlplus='rlwrap -D2 -irc -b'\''"@(){}[],+=&^%#;|\'\'' -f ~/Documents/Oracle_Scripts/tpt/setup/wordfile_11gR2.txt $INSTANT_CLIENT_PATH/sqlplus'
- To use
SQL> select * from dba [tab] to complete [tab] [tab] to show all possible values
References:
Related Posts: