Ò׽ؽØÍ¼Èí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

Oracle Êý¾ÝÉú³É Ë÷Òý

1.½¨±í
CREATE TABLE qq(
       qq_num integer
);
2.²åÈëÊý¾Ý
²åÈëÊý¾ÝµÄ·½·¨ÓкܶàÖÖ£¬µ«ÊÇÒª²åÈë3ÒÚÊý¾Ý£¬±ØÐëÒªÓиßЧµÄËã·¨¡£ÔÚ²åÈëÊý¾ÝʱÎÒÓÃÁË×µÄ°ì·¨£¬²ÉÓÃPL/SQLÀûÓÃÁ÷³Ì¿ØÖƵÄLOOPÓï¾ä²åÈ롣ͬʱÎÒÒ²¿´ÁËÍøÉϵIJåÈëЧÂʵÄÓÅ»¯£¬ÔõÑùÀûÓýÏÉÙµÄʱ¼äÉú³É½Ï¶àµÄ²âÊÔÊý¾Ý¡£¸øÎÒÓ¡ÏóÉî¿ÌµÄÊÇÀûÓÃÖÖ×Ó±íÀ´Éú³É½Ï¶àµÄÊý¾Ý¡£
ÕâÑù×öµÄºÃ´¦ÊDZ¾ÉíÊý¾Ý¾ÍÔÚ±¾µØ´ÅÅÌ£¬¼õÉÙÁË´æÈ¡µÄI/O²Ù×÷£¬Êý¾ÝÉú³É½Ï¿ì¡£
ÎÒ²ÉÓÃ×µÄ°ì·¨ÀûÓÃ8СʱÉú³ÉÁË2ÒÚ¶àÌõÊý¾Ý¼Ç¼¡£
3.Ë÷ÒýµÄ½¨Á¢
ÓÉÓÚÒÑ´æÔڵļǼÓÐ2ÒÚÌõ£¬²ÉÓÃCREATE INDEX qq_num_index ON qq(qq_num);ºÄ·Ñʱ¼ä½ü1Сʱ¡£
Ë÷ÒýµÄºÃ´¦:²éѯЧÂÊÌá¸ß£¬Ë÷ÒýÏà¹ØµÄ“Ìî³äÒò×Ó”¡£
count£¨£©º¯ÊýʼÖÕ²»×ßË÷Òý£¬¶¼ÊÇÈ«ÅÌɨÃ裬»¹Î´ÕÒµ½½â¾ö°ì·¨¡£Ò²¾ÍÊÇÒÔÏÂPL/SQLÖ´ÐеÄʱ¼äÔÚ½¨Á¢Ë÷ÒýǰºóÊÇÒ»ÑùµÄ¡£
DECLARE
count_num NUMBER;
BEGIN
dbms_output.put_line('Óï¾äÖ´ÐпªÊ¼Ê±¼ä:'||systimestamp);
SELECT COUNT(qq_num) INTO count_num from qq WHERE qq_num IS NOT NULL;
dbms_output.put_line('½á¹û:'||count_num);
dbms_output.put_line('Óï¾äÖ´ÐнáÊøÊ±¼ä:'||systimestamp);
END;
/
µ«Êǽ¨Á¢Ë÷Òýºó£¬SELECT MAX£¨qq_num£© ºÍÆäËûÏà¹ØµÄÓï¾äµÄÖ´ÐÐʱ¼äÁ¢¼´¼õÉÙÁ˺ܶࡣ
ÒÔÏÂÊÇ´úÂ룺
DECLARE
count_num NUMBER;
BEGIN
dbms_output.put_line('Óï¾äÖ´ÐпªÊ¼Ê±¼ä:'||systimestamp);
SELECT MAX(qq_num) INTO count_num from qq;
dbms_output.put_line('½á¹û:'||count_num);
dbms_output.put_line('Óï¾äÖ´ÐнáÊøÊ±¼ä:'||systimestamp);
END;
/
½¨Á¢Ë÷Òýǰ£ºÖ´ÐÐʱ¼äΪ1·Ö7Ãë,Ë÷Òýºó0.2ÃëÄÚÍê³É¡£
½¨Á¢Ë÷ÒýÊÇÒÔ´æ´¢¿Õ¼äΪ´ú¼Û»»È¡Ê±¼äЧÂʵÄÌá¸ß¡£
Õâµ±ÖÐÓÐautotrace¿ÉÒÔ×Ô¶¯ÏÔʾSQLÓï¾äµÄÖ´Ðмƻ®£¬ÕâÖֲ鿴±ØÐëÔÚSQL *PLUSÏÂ.
¿ªÆôautotraceµÄ²½ÖèÈçÏÂ:
--DBA³õ´Î±ØÐëÖ´ÐÐ
CREATE ROLE plustrace;--ÐèÒªÓµÓÐȨÏÞ
GRANT SELECT ON v_$sesstat TO plustrace;--ÐèÒªÓÐGRANTȨÏÞ
GRANT SELECT ON v_$mystat TO plustrace;
GRANT SELECT ON v_$statname TO plustrace;
--¿ªÆô×Ô¶¯¸ú×Ù
SET AUTOTRACE ON;


Ïà¹ØÎĵµ£º

Oracle±£´æ´ó¶ÔÏóBLOB

×î½üÔÚʹÓÃOracle×öÎļþÉÏ´«£¬ÒªÇó½«ÎļþÊý¾Ý±£´æµ½Êý¾Ý¿âÖС£OracleÌṩÁËBlobÓÃÀ´´æ´¢¶þ½øÖÆ´ó¶ÔÏóÊý¾Ý£¬¿ÉÊÇËüºÍJava.sqlÀïÃæµÄBlob²»¼æÈÝ£¬¾­³£µ¼ÖÂBlob×Ö¶ÎÎÞ·¨Ëø¶¨»òÕß²Ù×÷ʧ°Ü¡£ÓÉÓÚÒÔǰûÓÐ×ö¹ýÕâÑùµÄÀý×Ó£¬ËùÒÔ»¨Á˲»ÉÙʱ¼ä²Å½â¾ö¡£
ÎÒʹÓõÄÊÇstruts2.1.8+spring2.5+hibernate3.2£¬ÏÂÃæÊÇÏà¹Ø´úÂ룺
springÅäÖÃ ......

ORACLE°ó¶¨±äÁ¿µÄʹÓà ժ³­×ÔһƬÌû×Ó

±¾ÎÄÀ´×Ôhttp://www.cnblogs.com/rootq/articles/1177562.html
Oracle Êý¾Ý¿âµÄ°ó¶¨±äÁ¿ÌØÐÔ¼°Ó¦ÓÃ
¹Ø¼ü´Ê:
°ó¶¨±äÁ¿(binding variable),¹²Ïí³Ø(shared buffer pool), SGA(system global area);
ÔÚ¿ª·¢Ò»¸öÊý¾Ý¿âϵͳǰ,ÓÐË­¶ÔOracle ϵͳÁ˽âºÜ¶à,ÓÈÆäÊÇËüµÄÌØÐÔ,ºÃÏóºÜÉÙ°É;¶Ô³õѧÕßÀ´½²,Õâ¸üÊDz»¿ÉÄܵÄÊÂÇé;½ö½ö¼òµ ......

Using Oracle Trace Analyzer (trcanlzr.sql)


Using Oracle Trace Analyzer (trcanlzr.sql)
Dave Moore:  Author of Oracle Utilities
Oracle has provided another utility initially designed for performance tuning Oracle Applications.  Trace Analyzer is provided in the form of a PL/SQL package (TRCA$ ).  The Trace Analyzer utility i ......

oracle 10.2.0.4ÏÂÔØµØÖ·


ÏÂÔØ·½·¨£ºÔÚÏÂÃæµÄÁ¬½ÓÉϵã»÷ÓÒ¼ü£¬Ñ¡ÔñʹÓÃѸÀ×ÏÂÔØ¡£Ê¹ÓñðµÄÏÂÔØ¹¤¾ßÎÞ·¨ÏÂÔØ¡£
oracle 10.2.0.4 ²¹¶¡ÏÂÔØ£¨ÊÊÓÃÓÚËùÓвÙ×÷ϵͳ£©:
ftp://updates.oracle.com/6810189/p6810189_10204_AIX5L.zip
ftp://updates.oracle.com/6810189/p6810189_10204_HPUX-IA64.zip
ftp://updates.oracle.com/6810189/p6810189_10204 ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØÍ¼ | ¸ÓICP±¸09004571ºÅ