sqlplus的基本操作

显示当前用户:

1
show user

查看当前用户下的表:

1
select * from tab;

查看表结构:

1
desc 表名;

设置行宽:

1
set linesize 140

设置页面显示的行数:

1
set pagesize 100

永久设置行宽和页面显示的行数:

1
2
C:\app\Administrator\product\11.2.0\client_1\sqlplus\admin\glogin.sql 
C:\app\Administrator\product\11.2.0\dbhome_1\sqlplus\admin\glogin.sql

设置列宽:

1
2
3
4
a 代表一个字符
9 代表一位数字
col ename for a10
col sal for 9999

命令行删除字符

ctrl +BACKSPACE键

image-20220511192602044