欢迎来到天天文库
浏览记录
ID:15582182
大小:69.50 KB
页数:24页
时间:2018-08-04
《oracle数据库命令大全速查》由会员上传分享,免费在线阅读,更多相关内容在行业资料-天天文库。
1、Oracle数据库命令大全速查Oracle数据库命令速查Oracle数据库命令速查1.日志管理1.1.强制日志切换(forcinglogswitches)sql>altersystemswitchlogfile;1.2.强制执行检查点(forcingcheckpoints)sql>altersystemcheckpoint;1.3.增加一个重做日志组(addingonlineredologgroups)sql>alterdatabaseaddlogfile[group4]sql>('/disk3/log4a.rdo','/disk4/log4b.rdo')
2、size1m;1.4.增加一个重做日志文件(addingonlineredologmembers)sql>alterdatabaseaddlogfilemembersql>'/disk3/log1b.rdo'togroup1,sql>'/disk4/log2b.rdo'togroup2;1.5.改变重做日志文件名(changesthenameoftheonlineredologfile)sql>alterdatabaserenamefile'c:/oracle/oradata/oradb/redo01.log'sql>to'c:/oracle/oradat
3、a/redo01.log';1.6.删除重做日志组(droponlineredologgroups)sql>alterdatabasedroplogfilegroup3;1.7.删除重做日志文件(droponlineredologmembers)sql>alterdatabasedroplogfilemember'c:/oracle/oradata/redo01.log';1.8.清空重做日志文件(clearingonlineredologfiles)sql>alterdatabaseclear[unarchived]logfile'c:/oracle/l
4、og2a.rdo';1.9.使用logminer分析重做日志文件(usinglogmineranalyzingredologfiles)a.intheinit.oraspecifyutl_file_dir=''b.sql>executedbms_logmnr_d.build('oradb.ora','c:oracleoradblog');c.sql>executedbms_logmnr_add_logfile('c:oracleoradataoradbredo01.log',sql>dbms_logmnr.new);d.sql>execute
5、dbms_logmnr.add_logfile('c:oracleoradataoradbredo02.log',sql>dbms_logmnr.addfile);e.sql>executedbms_logmnr.start_logmnr(dictfilename=>'c:oracleoradblogoradb.ora');f.sql>select*fromv$logmnr_contents(v$logmnr_dictionary,v$logmnr_parameterssql>v$logmnr_logs);g.sql>executedbms
6、_logmnr.end_logmnr;2.表空间管理2.1.创造表空间(createtablespaces)sql>createtablespacets_namedatafile'c:oracleoradatafile1.dbf'size100m,sql>'c:oracleoradatafile2.dbf'size100mminimumextent550k[logging/nologging]sql>defaultstorage(initial500knext500kmaxextents500pctinccease0)sql>[online/o
7、ffline][permanent/temporary][extent_management_clause]2.2.创建本地管理的表空间(locallymanagedtablespace)sql>createtablespaceuser_datadatafile'c:oracleoradatauser_data01.dbf'sql>size500mextentmanagementlocaluniformsize10m;2.3.创建临时表空间(temporarytablespace)sql>createtemporarytablespacetempte
8、mpfile'c:oracleoradatatemp01.d
此文档下载收益归作者所有