虚位以待(AD)
虚位以待(AD)
首页 > 数据库 > Oracle数据库 > OracleSqlplus中上下键出现^[[A乱码问题

OracleSqlplus中上下键出现^[[A乱码问题
类别:Oracle数据库   作者:码皇   来源:Oracle Sqlplus中上下键出现^[[A乱码问题     点击:

安装rlwrap 下载:http: utopia knoware nl ~hlub uck rlwrap 或者 百度云盘:http: pan baidu com s 1ntM8YXr需要先安装readline,否则会报一下错误:You need the GNU readline library(ftp

安装rlwrap

下载:http://utopia.knoware.nl/~hlub/uck/rlwrap/

或者 百度云盘:http://pan.baidu.com/s/1ntM8YXr
需要先安装readline,否则会报一下错误:You need the GNU readline library(ftp://ftp.gnu.org/gnu/readline/ ) to build this program!如下:

[root@rtest ~]# cd /opt/[root@rtest opt]# lltotal 256drwxr-xr-x 3 root root 4096 Apr 22 09:54 ORCLfmap-rw-r--r-- 1 root root 251438 May 6 10:12 rlwrap-0.37.tar.gz[root@rtest opt]# tar -zxvf rlwrap-0.37.tar.gz [root@rtest opt]# cd rlwrap-0.37[root@rtest rlwrap-0.37]# lltotal 408-rw-rw-r-- 1 oracle dba 35029 Apr 30 2010 aclocal.m4-rw-r--r-- 1 oracle dba 638 Aug 15 2006 AUTHORS-rw-r--r-- 1 oracle dba 4267 May 5 2010 BUGS-rw-r--r-- 1 oracle dba 105 Aug 10 2003 ChangeLogdrwxrwxr-x 2 oracle dba 4096 May 5 2010 completions-rw-rw-r-- 1 oracle dba 7042 Apr 30 2010 config.h.in-rwxr-xr-x 1 oracle dba 222847 Apr 30 2010 configure-rw-r--r-- 1 oracle dba 11521 Apr 30 2010 configure.ac-rw-r--r-- 1 oracle dba 17992 Aug 8 2006 COPYINGdrwxrwxr-x 2 oracle dba 4096 May 5 2010 docdrwxrwxr-x 2 oracle dba 4096 May 5 2010 filters-rw-r--r-- 1 oracle dba 2019 Nov 23 2009 INSTALL-rw-r--r-- 1 oracle dba 1272 Jan 23 2010 Makefile.am-rw-rw-r-- 1 oracle dba 28316 Apr 30 2010 Makefile.in-rw-r--r-- 1 oracle dba 16788 Apr 30 2010 NEWS-rw-r--r-- 1 oracle dba 1394 Oct 24 2007 PLEA-rw-r--r-- 1 oracle dba 3070 Jan 8 2010 READMEdrwxrwxr-x 2 oracle dba 4096 May 5 2010 srcdrwxrwxr-x 2 oracle dba 4096 May 5 2010 test-rw-r--r-- 1 oracle dba 310 Apr 16 2010 TODOdrwxrwxr-x 2 oracle dba 4096 May 5 2010 tools[root@rtest rlwrap-0.37]# [root@rtest rlwrap-0.37]# ./configurechecking build system type... i686-pc-linux-gnuchecking host system type... i686-pc-linux-gnuchecking for a BSD-compatible install... /usr/bin/install -cchecking whether build environment is sane... yeschecking for a thread-safe mkdir -p... /bin/mkdir -pchecking for gawk... gawkchecking whether make sets $(MAKE)... yeschecking whether make sets $(MAKE)... (cached) yeschecking whether build environment is sane... yeschecking for style of include used by make... GNUchecking for gcc... gccchecking for C compiler default output file name... a.outchecking whether the C compiler works... yeschecking whether we are cross compiling... nochecking for suffix of executables... checking for suffix of object files... ochecking whether we are using the GNU C compiler... yeschecking whether gcc accepts -g... yeschecking for gcc option to accept ISO C89... none neededchecking dependency style of gcc... gcc3checking how to run the C preprocessor... gcc -Echecking for grep that handles long lines and -e... /bin/grepchecking for egrep... /bin/grep -Echecking for ANSI C header files... yeschecking for sys/types.h... yeschecking for sys/stat.h... yeschecking for stdlib.h... yeschecking for string.h... yeschecking for memory.h... yeschecking for strings.h... yeschecking for inttypes.h... yeschecking for stdint.h... yeschecking for unistd.h... yeschecking minix/config.h usability... nochecking minix/config.h presence... nochecking for minix/config.h... nochecking whether it is safe to define __EXTENSIONS__... yeschecking for gcc... (cached) gccchecking whether we are using the GNU C compiler... (cached) yeschecking whether gcc accepts -g... (cached) yeschecking for gcc option to accept ISO C89... (cached) none neededchecking dependency style of gcc... (cached) gcc3checking how to run the C preprocessor... gcc -Echecking for perl... /usr/bin/perlchecking for strip... stripchecking for ANSI C header files... (cached) yeschecking for sys/wait.h that is POSIX.1 compatible... yeschecking errno.h usability... yeschecking errno.h presence... yeschecking for errno.h... yeschecking fcntl.h usability... yeschecking fcntl.h presence... yeschecking for fcntl.h... yeschecking libutil.h usability... nochecking libutil.h presence... nochecking for libutil.h... nochecking for stdlib.h... (cached) yeschecking for string.h... (cached) yeschecking sched.h usability... yeschecking sched.h presence... yeschecking for sched.h... yeschecking sys/ioctl.h usability... yeschecking sys/ioctl.h presence... yeschecking for sys/ioctl.h... yeschecking for sys/wait.h... (cached) yeschecking sys/resource.h usability... yeschecking sys/resource.h presence... yeschecking for sys/resource.h... yeschecking stddef.h usability... yeschecking stddef.h presence... yeschecking for stddef.h... yeschecking termios.h usability... yeschecking termios.h presence... yeschecking for termios.h... yeschecking for unistd.h... (cached) yeschecking for stdint.h... (cached) yeschecking time.h usability... yeschecking time.h presence... yeschecking for time.h... yeschecking getopt.h usability... yeschecking getopt.h presence... yeschecking for getopt.h... yeschecking regex.h usability... yeschecking regex.h presence... yeschecking for regex.h... yeschecking curses.h usability... nochecking curses.h presence... nochecking for curses.h... nochecking termcap.h usability... nochecking termcap.h presence... nochecking for termcap.h... nochecking for term.h... nochecking for ncurses/term.h... nochecking argument type of tputs putc function... charchecking whether your getopt() correctly understands double colons in option string... yeschecking for an ANSI C-conforming const... yeschecking for pid_t... yeschecking whether time.h and sys/time.h may both be included... yeschecking whether gcc needs -traditional... nochecking return type of signal handlers... voidchecking for getopt_long... yeschecking for getopt_long... (cached) yeschecking for isastream... yeschecking for mkstemp... yeschecking for pselect... yeschecking for putenv... yeschecking for readlink... yeschecking for sched_yield... yeschecking for setenv... yeschecking for setitimer... yeschecking for setsid... yeschecking for setrlimit... yeschecking for sigaction... yeschecking for snprintf... yeschecking for strlcpy... nochecking for strlcat... nochecking for strnlen... yeschecking for system... yeschecking for openpty in -lutil... yeschecking for openpty... yeschecking for getpty... nochecking for grantpt... yeschecking for unlockpt... yeschecking for getpt... yeschecking for pty/tty type... checking pty.h usability... yeschecking pty.h presence... yeschecking for pty.h... yesOPENPTYconfigure: checking for pty ranges...checking for tgetent... nochecking for tgetent in -lcurses... nochecking for tgetent in -lncurses... nochecking for tgetent in -ltermcap... noconfigure: WARNING: No termcap nor curses library foundchecking for readline in -lreadline... noconfigure: error:
You need the GNU readline library(ftp://ftp.gnu.org/gnu/readline/ ) to buildthis program!

[root@rtest rlwrap-0.37]#
##############################################################################################################1.安装readline
[root@rtest ~]# mount /dev/cdrom /media/mount: block device /dev/cdrom is write-protected, mounting read-only[root@rtest ~]# cd /media/Server/[root@rtest Server]# rpm -Uvh readline-readline-5.1-3.el5.i386.rpm readline-devel-5.1-3.el5.i386.rpm [root@rtest Server]# rpm -Uvh readline-5.1-3.el5.i386.rpm warning: readline-5.1-3.el5.i386.rpm: Header V3 DSA signature: NOKEY, key ID 1e5e0159Preparing... ########################################### [100%] package readline-5.1-3.el5.i386 is already installed[root@rtest Server]# rpm -Uvh readline-devel-5.1-3.el5.i386.rpm warning: readline-devel-5.1-3.el5.i386.rpm: Header V3 DSA signature: NOKEY, key ID 1e5e0159error: Failed dependencies: libtermcap-devel is needed by readline-devel-5.1-3.el5.i386[root@rtest Server]# rpm -Uvh libtermcap-devel-2.0.8-46.1.i386.rpm warning: libtermcap-devel-2.0.8-46.1.i386.rpm: Header V3 DSA signature: NOKEY, key ID 1e5e0159Preparing... ########################################### [100%] 1:libtermcap-devel ########################################### [100%][root@rtest Server]# rpm -Uvh readline-devel-5.1-3.el5.i386.rpm warning: readline-devel-5.1-3.el5.i386.rpm: Header V3 DSA signature: NOKEY, key ID 1e5e0159Preparing... ########################################### [100%] 1:readline-devel ########################################### [100%]
2.安装rlwrap
[root@rtest Server]# cd /opt/rlwrap-0.37[root@rtest rlwrap-0.37]# lltotal 480-rw-rw-r-- 1 oracle dba 35029 Apr 30 2010 aclocal.m4-rw-r--r-- 1 oracle dba 638 Aug 15 2006 AUTHORS-rw-r--r-- 1 oracle dba 4267 May 5 2010 BUGS-rw-r--r-- 1 oracle dba 105 Aug 10 2003 ChangeLogdrwxrwxr-x 2 oracle dba 4096 May 5 2010 completions-rw-rw-r-- 1 oracle dba 7042 Apr 30 2010 config.h.in-rw-r--r-- 1 root root 67255 May 6 10:16 config.log-rwxr-xr-x 1 oracle dba 222847 Apr 30 2010 configure-rw-r--r-- 1 oracle dba 11521 Apr 30 2010 configure.ac-rw-r--r-- 1 oracle dba 17992 Aug 8 2006 COPYINGdrwxrwxr-x 2 oracle dba 4096 May 5 2010 docdrwxrwxr-x 2 oracle dba 4096 May 5 2010 filters-rw-r--r-- 1 oracle dba 2019 Nov 23 2009 INSTALL-rw-r--r-- 1 oracle dba 1272 Jan 23 2010 Makefile.am-rw-rw-r-- 1 oracle dba 28316 Apr 30 2010 Makefile.in-rw-r--r-- 1 oracle dba 16788 Apr 30 2010 NEWS-rw-r--r-- 1 oracle dba 1394 Oct 24 2007 PLEA-rw-r--r-- 1 oracle dba 3070 Jan 8 2010 READMEdrwxrwxr-x 2 oracle dba 4096 May 5 2010 srcdrwxrwxr-x 2 oracle dba 4096 May 5 2010 test-rw-r--r-- 1 oracle dba 310 Apr 16 2010 TODOdrwxrwxr-x 2 oracle dba 4096 May 5 2010 tools
[root@rtest rlwrap-0.37]# ./configure checking build system type... i686-pc-linux-gnuchecking host system type... i686-pc-linux-gnuchecking for a BSD-compatible install... /usr/bin/install -cchecking whether build environment is sane... yeschecking for a thread-safe mkdir -p... /bin/mkdir -pchecking for gawk... gawkchecking whether make sets $(MAKE)... yeschecking whether make sets $(MAKE)... (cached) yeschecking whether build environment is sane... yeschecking for style of include used by make... GNUchecking for gcc... gccchecking for C compiler default output file name... a.outchecking whether the C compiler works... yeschecking whether we are cross compiling... nochecking for suffix of executables... checking for suffix of object files... ochecking whether we are using the GNU C compiler... yeschecking whether gcc accepts -g... yeschecking for gcc option to accept ISO C89... none neededchecking dependency style of gcc... gcc3checking how to run the C preprocessor... gcc -Echecking for grep that handles long lines and -e... /bin/grepchecking for egrep... /bin/grep -Echecking for ANSI C header files... yeschecking for sys/types.h... yeschecking for sys/stat.h... yeschecking for stdlib.h... yeschecking for string.h... yeschecking for memory.h... yeschecking for strings.h... yeschecking for inttypes.h... yeschecking for stdint.h... yeschecking for unistd.h... yeschecking minix/config.h usability... nochecking minix/config.h presence... nochecking for minix/config.h... nochecking whether it is safe to define __EXTENSIONS__... yeschecking for gcc... (cached) gccchecking whether we are using the GNU C compiler... (cached) yeschecking whether gcc accepts -g... (cached) yeschecking for gcc option to accept ISO C89... (cached) none neededchecking dependency style of gcc... (cached) gcc3checking how to run the C preprocessor... gcc -Echecking for perl... /usr/bin/perlchecking for strip... stripchecking for ANSI C header files... (cached) yeschecking for sys/wait.h that is POSIX.1 compatible... yeschecking errno.h usability... yeschecking errno.h presence... yeschecking for errno.h... yeschecking fcntl.h usability... yeschecking fcntl.h presence... yeschecking for fcntl.h... yeschecking libutil.h usability... nochecking libutil.h presence... nochecking for libutil.h... nochecking for stdlib.h... (cached) yeschecking for string.h... (cached) yeschecking sched.h usability... yeschecking sched.h presence... yeschecking for sched.h... yeschecking sys/ioctl.h usability... yeschecking sys/ioctl.h presence... yeschecking for sys/ioctl.h... yeschecking for sys/wait.h... (cached) yeschecking sys/resource.h usability... yeschecking sys/resource.h presence... yeschecking for sys/resource.h... yeschecking stddef.h usability... yeschecking stddef.h presence... yeschecking for stddef.h... yeschecking termios.h usability... yeschecking termios.h presence... yeschecking for termios.h... yeschecking for unistd.h... (cached) yeschecking for stdint.h... (cached) yeschecking time.h usability... yeschecking time.h presence... yeschecking for time.h... yeschecking getopt.h usability... yeschecking getopt.h presence... yeschecking for getopt.h... yeschecking regex.h usability... yeschecking regex.h presence... yeschecking for regex.h... yeschecking curses.h usability... nochecking curses.h presence... nochecking for curses.h... nochecking termcap.h usability... yeschecking termcap.h presence... yeschecking for termcap.h... yeschecking for term.h... nochecking for ncurses/term.h... nochecking argument type of tputs putc function... intchecking whether your getopt() correctly understands double colons in option string... yeschecking for an ANSI C-conforming const... yeschecking for pid_t... yeschecking whether time.h and sys/time.h may both be included... yeschecking whether gcc needs -traditional... nochecking return type of signal handlers... voidchecking for getopt_long... yeschecking for getopt_long... (cached) yeschecking for isastream... yeschecking for mkstemp... yeschecking for pselect... yeschecking for putenv... yeschecking for readlink... yeschecking for sched_yield... yeschecking for setenv... yeschecking for setitimer... yeschecking for setsid... yeschecking for setrlimit... yeschecking for sigaction... yeschecking for snprintf... yeschecking for strlcpy... nochecking for strlcat... nochecking for strnlen... yeschecking for system... yeschecking for openpty in -lutil... yeschecking for openpty... yeschecking for getpty... nochecking for grantpt... yeschecking for unlockpt... yeschecking for getpt... yeschecking for pty/tty type... checking pty.h usability... yeschecking pty.h presence... yeschecking for pty.h... yesOPENPTYconfigure: checking for pty ranges...checking for tgetent... nochecking for tgetent in -lcurses... nochecking for tgetent in -lncurses... nochecking for tgetent in -ltermcap... yeschecking for readline in -lreadline... yeschecking whether your readline headers know about rl_set_screen_size... yeschecking whether your readline library knows about rl_set_screen_size... checking for rl_set_screen_size... yeschecking whether your readline knows about rl_variable_value... yeschecking whether your readline knows about rl_readline_version... yesWill rlwrap find command's working directory under /proc/<commands pid>/cwd? let's see...checking for /proc/8714/cwd/configure.ac... yes

configure: creating ./config.statusconfig.status: creating Makefileconfig.status: creating filters/Makefileconfig.status: creating doc/Makefileconfig.status: creating src/Makefileconfig.status: creating doc/rlwrap.manconfig.status: creating config.hconfig.status: executing depfiles commands
Now do: make (or gmake) to build rlwrap make check for instructions how to test it make install to install it
[root@rtest rlwrap-0.37]#

[root@rtest rlwrap-0.37]# makemake all-recursivemake[1]: Entering directory `/opt/rlwrap-0.37'Making all in docmake[2]: Entering directory `/opt/rlwrap-0.37/doc'sed -e 's#@DATADIR@#/usr/local/share#' rlwrap.man > rlwrap.1make[2]: Leaving directory `/opt/rlwrap-0.37/doc'Making all in srcmake[2]: Entering directory `/opt/rlwrap-0.37/src'gcc -DHAVE_CONFIG_H -I. -I.. -DDATADIR="/usr/local/share" -g -O2 -MT main.o -MD -MP -MF .deps/main.Tpo -c -o main.o main.cmv -f .deps/main.Tpo .deps/main.Pogcc -DHAVE_CONFIG_H -I. -I.. -DDATADIR="/usr/local/share" -g -O2 -MT signals.o -MD -MP -MF .deps/signals.Tpo -c -o signals.o signals.cmv -f .deps/signals.Tpo .deps/signals.Pogcc -DHAVE_CONFIG_H -I. -I.. -DDATADIR="/usr/local/share" -g -O2 -MT readline.o -MD -MP -MF .deps/readline.Tpo -c -o readline.o readline.cmv -f .deps/readline.Tpo .deps/readline.Pogcc -DHAVE_CONFIG_H -I. -I.. -DDATADIR="/usr/local/share" -g -O2 -MT pty.o -MD -MP -MF .deps/pty.Tpo -c -o pty.o pty.cmv -f .deps/pty.Tpo .deps/pty.Pogcc -DHAVE_CONFIG_H -I. -I.. -DDATADIR="/usr/local/share" -g -O2 -MT completion.o -MD -MP -MF .deps/completion.Tpo -c -o completion.o completion.cmv -f .deps/completion.Tpo .deps/completion.Pogcc -DHAVE_CONFIG_H -I. -I.. -DDATADIR="/usr/local/share" -g -O2 -MT term.o -MD -MP -MF .deps/term.Tpo -c -o term.o term.cmv -f .deps/term.Tpo .deps/term.Pogcc -DHAVE_CONFIG_H -I. -I.. -DDATADIR="/usr/local/share" -g -O2 -MT ptytty.o -MD -MP -MF .deps/ptytty.Tpo -c -o ptytty.o ptytty.cmv -f .deps/ptytty.Tpo .deps/ptytty.Pogcc -DHAVE_CONFIG_H -I. -I.. -DDATADIR="/usr/local/share" -g -O2 -MT utils.o -MD -MP -MF .deps/utils.Tpo -c -o utils.o utils.cmv -f .deps/utils.Tpo .deps/utils.Pogcc -DHAVE_CONFIG_H -I. -I.. -DDATADIR="/usr/local/share" -g -O2 -MT string_utils.o -MD -MP -MF .deps/string_utils.Tpo -c -o string_utils.o string_utils.cstring_utils.c: In function 鈥榗olourless_strlen鈥
string_utils.c:626: warning: assignment discards qualifiers from pointer target typemv -f .deps/string_utils.Tpo .deps/string_utils.Pogcc -DHAVE_CONFIG_H -I. -I.. -DDATADIR="/usr/local/share" -g -O2 -MT malloc_debug.o -MD -MP -MF .deps/malloc_debug.Tpo -c -o malloc_debug.o malloc_debug.cmv -f .deps/malloc_debug.Tpo .deps/malloc_debug.Pogcc -DHAVE_CONFIG_H -I. -I.. -DDATADIR="/usr/local/share" -g -O2 -MT filter.o -MD -MP -MF .deps/filter.Tpo -c -o filter.o filter.cmv -f .deps/filter.Tpo .deps/filter.Pogcc -DDATADIR="/usr/local/share" -g -O2 -o rlwrap main.o signals.o readline.o pty.o completion.o term.o ptytty.o utils.o string_utils.o malloc_debug.o filter.o -lutil -lreadline -ltermcapmake[2]: Leaving directory `/opt/rlwrap-0.37/src'Making all in filtersmake[2]: Entering directory `/opt/rlwrap-0.37/filters'make[2]: Nothing to be done for `all'.make[2]: Leaving directory `/opt/rlwrap-0.37/filters'make[2]: Entering directory `/opt/rlwrap-0.37'make[2]: Nothing to be done for `all-am'.make[2]: Leaving directory `/opt/rlwrap-0.37'make[1]: Leaving directory `/opt/rlwrap-0.37'[root@rtest rlwrap-0.37]#

[root@rtest rlwrap-0.37]# make installMaking install in docmake[1]: Entering directory `/opt/rlwrap-0.37/doc'make[2]: Entering directory `/opt/rlwrap-0.37/doc'make[2]: Nothing to be done for `install-exec-am'.test -z "/usr/local/share/man/man1" || /bin/mkdir -p "/usr/local/share/man/man1" /usr/bin/install -c -m 644 rlwrap.1 '/usr/local/share/man/man1'make[2]: Leaving directory `/opt/rlwrap-0.37/doc'make[1]: Leaving directory `/opt/rlwrap-0.37/doc'Making install in srcmake[1]: Entering directory `/opt/rlwrap-0.37/src'make[2]: Entering directory `/opt/rlwrap-0.37/src'test -z "/usr/local/bin" || /bin/mkdir -p "/usr/local/bin" /usr/bin/install -c rlwrap '/usr/local/bin'make[2]: Nothing to be done for `install-data-am'.make[2]: Leaving directory `/opt/rlwrap-0.37/src'make[1]: Leaving directory `/opt/rlwrap-0.37/src'Making install in filtersmake[1]: Entering directory `/opt/rlwrap-0.37/filters'make[2]: Entering directory `/opt/rlwrap-0.37/filters'make[2]: Nothing to be done for `install-exec-am'.test -z "/usr/local/share/man/man3" || /bin/mkdir -p "/usr/local/share/man/man3" /usr/bin/install -c -m 644 RlwrapFilter.3pm '/usr/local/share/man/man3'make[2]: Leaving directory `/opt/rlwrap-0.37/filters'make[1]: Leaving directory `/opt/rlwrap-0.37/filters'make[1]: Entering directory `/opt/rlwrap-0.37'make[2]: Entering directory `/opt/rlwrap-0.37'make[2]: Nothing to be done for `install-exec-am'.test -z "/usr/local/share/rlwrap" || /bin/mkdir -p "/usr/local/share/rlwrap"/bin/mkdir -p '/usr/local/share/rlwrap/filters' /usr/bin/install -c -m 644 filters/README filters/RlwrapFilter.pm filters/RlwrapFilter.3pm filters/count_in_prompt filters/pipeto filters/logger filters/null filters/unbackspace filters/pipeline filters/ftp_filter filters/history_format filters/simple_macro filters/template filters/scrub_prompt filters/paint_prompt filters/censor_passwords filters/listing '/usr/local/share/rlwrap/filters'/bin/mkdir -p '/usr/local/share/rlwrap/completions' /usr/bin/install -c -m 644 completions/testclient completions/coqtop '/usr/local/share/rlwrap/completions'make install-data-hookmake[3]: Entering directory `/opt/rlwrap-0.37'chmod a+x /usr/local/share/rlwrap/filters/* make[3]: Leaving directory `/opt/rlwrap-0.37'make[2]: Leaving directory `/opt/rlwrap-0.37'make[1]: Leaving directory `/opt/rlwrap-0.37'[root@rtest rlwrap-0.37]#

[root@rtest rlwrap-0.37]# vi /home/oracle/.bash_profile# .bash_profile
# Get the aliases and functionsif [ -f ~/.bashrc ]; then . ~/.bashrcfi
# User specific environment and startup programs
export ORACLE_BASE=/u01/app/oracleexport ORACLE_HOME=$ORACLE_BASE/product/10.2.0/db_1export ORACLE_SID=TEST0422export LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/libexport PATH=$ORACLE_HOME/bin:$PATH
PATH=$PATH:$HOME/bin
export PATH
stty erase ^H
alias sqlplus='rlwrap sqlplus'alias rman='rlwrap rman'
~~~"/home/oracle/.bash_profile" 25L, 455C written
保存退出,使文件立即生效。
[root@rtest rlwrap-0.37]# su - oracle
[oracle@rtest ~]$ . .bash_profile
3.使用rlwrap[oracle@rtest ~]$ sqlplus "/as sysdba"
SQL*Plus: Release 10.2.0.2.0 - Production on Tue May 6 10:31:02 2014
Copyright (c) 1982, 2005, Oracle. All Rights Reserved.

Connected to:Oracle Database 10g Enterprise Edition Release 10.2.0.2.0 - ProductionWith the Partitioning, OLAP and Data Mining options
SYS@TEST0422>select * from scott.emp;
即现在就可以使用上下键来调用命令了。#################################################################################################################

相关热词搜索: 乱码 上下 问题