标签:
进入oracle
su - oracle
创建监听
lsnrctl start
连接数据库
sqlplus / as sysdba
启动
startup
连接用户
conn scott/tiger scott为用户 tiger为密码
基础语句:
选择
select * from emp;
定义别名:
select ename as name from emp;
消除空行:
select distinct deptno from emp;
between and的使用 select sal from emp where sal between 1000 and 1500;
in 的使用 select sal from emp where sal in (1000,1100,1200);
is null的使用 select sal from emp where comm is null;
like的使用: select ename from emp where ename like ‘s%‘; %为一个或多个字符 _代表一个字符
标签:
原文地址:http://www.cnblogs.com/wangqianqiannb/p/4162254.html