常用的oracle 命令,總是忘,呵呵


          1
          導(dǎo)出:
          EXP.EXE cits_cc/cits_cc@cits direct=y buffer=327680 file=D:\cits.dmp owner=(cits_cc,cits_stat)

          導(dǎo)入:
          IMP.EXE cits_cc/cits_cc@cits file=D:\cits.dmp fromuser=(cits_cc,cits_stat) touser=(cits_cc,cits_stat)

          2
          連接數(shù)據(jù)庫
          sqlpuls /nolog
          connect / as sysdba

          3 查看實例
          select * from v$instance

          4 啟動數(shù)據(jù)庫

          ?startup nomount 啟動實例但不加載數(shù)據(jù)
          ?startup mount?? 啟動實例加載數(shù)據(jù),但不大開數(shù)據(jù)庫
          ?startup???????? 啟動實例,加載數(shù)據(jù),打開數(shù)據(jù)庫
          ?
          ?alter database mount 為實例加載數(shù)據(jù)
          ?alter database open? 從加載狀態(tài)進(jìn)入打開狀態(tài)

          ?startup force 強(qiáng)行啟動數(shù)據(jù)庫

          5 受限狀態(tài) 只有dba 或同時具有create sesson 和restricted session 可以訪問數(shù)據(jù)庫
          ?在受限狀態(tài)下一般的用戶(create session)不能訪問,但是dba 可以進(jìn)行數(shù)據(jù)庫的維護(hù),數(shù)據(jù)的導(dǎo)入導(dǎo)出
          ?startup restrict 啟動進(jìn)入受限狀態(tài)
          ?alter system disable restricted session 恢復(fù)正常狀態(tài)
          ?alter system enable restricted session? 進(jìn)入受限狀態(tài)

          6 只讀數(shù)據(jù)庫
          ? alter database open read only
          ? alter database open read write

          7 關(guān)閉數(shù)據(jù)庫
          ?shutdonw normal???????? 正常關(guān)閉
          ?shutdown immediate????? 立即關(guān)閉
          ?shutdown transactional? 事務(wù)型關(guān)閉
          ?shutdown abort????????? 立即中止

          8 靜默狀態(tài)(只有dba 可以訪問)
          ?alter system? quiesce restricted 進(jìn)入靜默狀態(tài)
          ?alter system unquiesce?????????? 退出靜默狀態(tài)
          ?select active_status from v$instance 查詢靜默狀態(tài)

          9 掛起狀態(tài)(暫停所有io操作)
          ?alter system suspend 掛起
          ?alter system resume? 恢復(fù)
          ?select database_status from v$instance 查詢狀態(tài)

          9 創(chuàng)建數(shù)據(jù)庫 dbca

          posted on 2006-07-13 14:00 康文 閱讀(394) 評論(1)  編輯  收藏 所屬分類: 數(shù)據(jù)庫

          評論

          # re: 常用的oracle 命令,總是忘,呵呵 2006-11-03 19:16 miao

          xiela  回復(fù)  更多評論   

          <2006年11月>
          2930311234
          567891011
          12131415161718
          19202122232425
          262728293012
          3456789

          導(dǎo)航

          統(tǒng)計

          常用鏈接

          留言簿(1)

          隨筆分類

          隨筆檔案

          文章檔案

          搜索

          最新評論

          閱讀排行榜

          評論排行榜

          主站蜘蛛池模板: 工布江达县| 安丘市| 易门县| 文水县| 沈丘县| 剑河县| 西充县| 盐津县| 五家渠市| 刚察县| 洛宁县| 水富县| 衡山县| 建瓯市| 辽阳县| 瑞丽市| 金湖县| 河池市| 海伦市| 阿坝县| 辽阳县| 苍梧县| 碌曲县| 秀山| 长海县| 丹江口市| 黔南| 仁布县| 嵩明县| 贺兰县| 民丰县| 和田县| 麟游县| 增城市| 武冈市| 五常市| 卓尼县| 英德市| 栾城县| 大理市| 中牟县|