該系列是向 韓順平 老師學習的筆記
高階許可權賬號:scott pwd sysdba
新建一個 Command Window,也可以 開始,執行 sqlplus
連線命令
–1.0 切換賬號
SQL> show user;
User is “SYS”
–conn 賬號/密碼
SQL> conn system/123456
Connected to Oracle Database 11g Express Edition Release 11.2.0.2.0
Connected as system
SQL> show user;
User is “SYSTEM”
–conn 賬號/密碼 AS 角色
SQL> conn scott/tiger AS SYSDBA
Connected to Oracle Database 11g Express Edition Release 11.2.0.2.0
Connected as scott AS SYSDBA
–2.0 disc
SQL> disc
Not logged on
–3.0 passw[ord]
SQL> passw tiger
–4.0 show user
–5.0 exit
–6.0 clear
其他命令
1)start和@
說明:執行sql指令碼
SQL> start D:Oracle est.sql
2)edit D:Oracle est.sql
3)&符號:獲取使用者輸入
SQL> select * from alert_qt t where t.q_name=`&name`;
4)set pagesize 10;
sys,system,scott等使用者,不同使用者看到的資料物件不一樣.
oracle的2個主要服務:OracleTSNListener,OracleService