oracleË÷ÒýµÄ¼à¿Ø
×î½üµÄÑо¿·¢ÏÖ Oracle Êý¾Ý¿âËùʹÓõÄË÷Òý´ÓÀ´Ã»Óдﵽ¹ý¿ÉÓÃË÷ÒýÊýµÄ1/4£¬
»òÕßÆäÓ÷¨ÓëÆ俪ʼÉè¼ÆµÄÒâͼ²»Ïàͬ¡£Î´ÓõÄË÷ÒýÀ˷ѿռ䣬¶øÇÒ»¹»á½µµÍ DML
µÄËٶȣ¬ÓÈÆäÊÇ UPDATE ºÍ INSERT Óï¾ä;¿ØÊý¾Ý¿âË÷ÒýµÄʹÓã¬ÊÍ·ÅÄÇЩδ±»Ê¹ÓÃ
µÄË÷Òý£¬´Ó¶ø½Úʡά»¤Ë÷ÒýµÄ¿ªÏú£¬ÓÅ»¯sqlÐÔÄÜ
ÔÚ Oracle9i ֮ǰ£¬¼à¿ØË÷ÒýʹÓõÄΨһ·½·¨ÊÇÖ´ÐÐËûÃǵijÌÐò¿â»ºÖеÄËùÓÐSQL£¬
È»ºóÊÖ¹¤¼ÇÏÂËùÓб»Ê¹ÓõÄË÷Òý¡£
oracle9iÖÐÈçºÎÈ·¶¨Ë÷ÒýµÄʹÓÃÇé¿ö
¡¡ÔÚoracle9iÖУ¬Çé¿ö»á¼òµ¥µÄ¶à£¬ÒòΪÓÐÒ»¸öеÄ×ÖµäÊÓͼV$SQL_PLAN´æ´¢ÁËʵ¼Ê¼Æ»®£¬
ÕâЩ¼Æ»®ÓÃÓÚÖ´Ðй²ÏíSQLÇøÖеÃÓï¾ä¡£V$SQL_PLANÊÓͼºÜÀàËÆÓë¼Æ»®±í£¬µ«V$SQL_PLAN
ʹÓÃADDRESSºÍHASH_VALUEÁÐ À´Ê¶±ðÓï¾ä£¬ ¶ø¼Æ»®±íʹÓÃÓû§ÌṩµÃSTATEMENT_IDÀ´Ê¶
±ðÓï¾ä¡£ÏÂÃæµÄSQLÏÔʾÁËÔÚÒ»¸öoracle9iÊý¾Ý¿âÖУ¬ÓɳöÏÖÔÚ¹²ÏíSQLÇøÖÐÓï¾äʹÓõÄËù
ÓÐË÷Òý
¡¡select object_owner, object_name, options, count(*)
¡¡¡¡from¡¡ v$sql_plan
¡¡where¡¡operation='INDEX'
¡¡¡¡and¡¡¡¡object_owner!='SYS'
¡¡¡¡group¡¡by¡¡object_owner, object_name, operation, options
¡¡¡¡order¡¡by count(*) desc;
¡¡¡¡
¡¡¡¡ËùÓлùÓÚ¹²ÏíSQLÇøÖеÄÐÅÏ¢À´Ê¶±ðË÷ÒýʹÓÃÇé¿öµÄ·½·¨£¬ ¶¼¿ÉÄÜ»áÊÕ¼¯µ½²»ÍêÕûµÄÐÅÏ¢¡£¹²ÏíSQLÇøÊÇ
Ò»¸ö¶¯Ì¬½á¹¹£¬³ý·ÇÄܶÔËü½øÐÐ×㹻Ƶ·±µÄ²ÉÑù£¬ ·ñÔòÔÚÓйØË÷ÒýʹÓõÄÇé¿öµÄÐÅÏ¢±»ÊÕ¼¯Ö®Ç°£¬SQLÓï
¾ä¿ÉÄܾÍÒѾ(ÒòΪÀÏ»¯)±»ÒƳö»º´æÁË¡£
Oracle9iÌṩһ¸ö¼òµ¥µÄ·½·¨À´´ò¿ªºÍ¹Ø±ÕË÷ÒýʹÓøú×Ù£¬ÄǾÍÊÇMONITORING USAGE ×Ӿ䣺
¡¡¡¡alter index cust_name_idx monitoring usage;
¡¡¡¡alter index cust_name_idx nomonitoring usage;
¡¡¡¡Õâ¸öÃüÁîʹÓÃV$OBJECT_USAGE ÊÓͼºÍ USAGE ×Ö¶ÎÀ´ÅжÏË÷ÒýÊÇ·ñ±»·ÃÎʹý¡£Äã¿ÉÄÜÆÚÍû USAGE ×Ö¶ÎÊÇÒ»¸öÊý×ÖÖµ£¬
ÕâÑùÄã¾Í¿ÉÒÔÖªµÀË÷Òý±»Ê¹ÓõĴÎÊý£¬µ«²»ÐÒµÄÊÇ£¬ËüµÄȡֵֻΪYES »òNO¡£µ«²»¹ÜÔõÑù£¬Èç¹ûÄã½ÓÊÖÒ»¸öÒÔÇ°¿ª·¢
µÄÊý¾Ý¿â£¬¶øÇÒÀÏÊý¾Ý¿âÔÚûÓп¼Âǵ½ SQL ·ÃÎʱíµÄÇé¿öÏ´´½¨ÁËË÷Òý£¬ÄÇôÕâ¸ö¹¤¾ß¶ÔÄãÊǺÜÓÐÓõġ£INDEX MONITORING
ÌØÐԵĿªÏú·Ç³£Ð¡£¬¶ø¶Ô¶¨Î»ºÍ¶ªÆ
Ïà¹ØÎĵµ£º
Oracleµ÷ÓÅ×ÛÊö
ÔÚ¹ýÈ¥µÄÊ®ÄêÖУ¬ Oracle ÒѾ³ÉΪÊÀ½çÉÏ×îרҵµÄÊý¾Ý¿âÖ®Ò»¡£¶ÔÓÚ IT ר¼ÒÀ´Ëµ£¬¾ÍÊÇҪȷ±£ÀûÓà Oracle µÄÇ¿´óÌØÐÔÀ´Ìá¸ßËûÃǹ«Ë¾µÄÉú²úÁ¦¡£×îÓÐЧµÄ·½·¨Ö®Ò»ÊÇͨ¹ý Oracle µ÷ÓÅ¡£ËüÓдóÁ¿µÄµ÷Õû²ÎÊýºÍ¼¼ÊõÀ´¸Ä½øÄãµÄ Oracle Êý¾Ý¿âµÄÐÔÄÜ¡£
Oracle µ÷ÓÅÊÇÒ»¸ö¸´ÔÓµÄÖ÷Ìâ¡£¹ØÓÚµ÷ÓÅ¿ ......
ORACLE SQLÐÔÄÜÓÅ»¯
ÎÒÒª½²µÄÌâÄ¿ÊÇOracle SQLÐÔÄÜÓÅ»¯£¬Ö»ÊÇOracleÐÔÄÜÓÅ»¯ÖеÄÒ»Ïî¡£OracleµÄÐÔÄÜÓÅ»¯°üº¬ºÜ¶à·½Ã棬±ÈÈçµ÷ÕûÎïÀí´æÈ¡£¬µ÷ÕûÂß¼´æÈ¡£¬µ÷ÕûÄÚ´æʹÓ㬼õÉÙÍøÂçÁ÷Á¿µÈ¡£ÕâÀïÑ¡ÔñSQLÐÔÄÜÓÅ»¯ÊÇÒòΪÕⲿ·ÖÄÚÈÝÎÒÃDzâÊÔÈËÔ±×îÈÝÒ×½Ó´¥µ½£¬ÁíÍ⿪·¢ÈËԱдSQL½Å±¾Ê±ÓÐʱºÜËæÒ⣬²»Öª²»¾õ¾Í»áÔì³É³ÌÐòÐÔÄÜÉϵÄÏ ......
OracleÖпÉÒÔµ÷ÓÃJavaµÄ´úÂ룬һ°ãͨ¹ýÁ½ÖÖ·½Ê½½øÐе÷Óã¬Ò»¸öÊÇÖ±½Ó½«Java´úÂëдÔÚOracleÄÚ²¿£¬ÁíÍâÒ»ÖÖÊǽ«±àÒëºÃµÄclassÎļþÔØÈëµ½OracleÖС£
-A-
1¡¢ÔÚSQLPlusÖд´½¨OracleÖеÄJavaÀàÓë·½·¨£¨·½·¨±ØÐëÊǾ²Ì¬¹«Óз½·¨£©
create or replace and compile java source named hello as
public class Hello {
pu ......
º¯ÊýË÷ÒýµÄ¸ÅÄ
»ùÓÚº¯ÊýµÄË÷ÒýÒ²ÊÇ8iÒÔÀ´µÄвúÎËüÓÐË÷Òý¼ÆËãÁеÄÄÜÁ¦£¬ËüÒ×ÓÚʹÓò¢ÇÒÌṩ¼ÆËãºÃµÄÖµ£¬ÔÚ²»ÐÞ¸ÄÓ¦ÓóÌÐòµÄÂß¼ÉÏÌá¸ßÁ˲éѯÐÔÄÜ¡£Ê¹ÓûùÓÚº¯ÊýµÄË÷ÒýÓм¸¸öÏȾöÌõ¼þ£º
(1)
±ØÐëÓµÓÐQUERY REWRITE£¨±¾Ä£Ê½Ï£©»òGLOBAL QUERY REWRITE£¨ÆäËûģʽÏ£©È¨ÏÞ¡£
(2)
±ØÐëʹÓûùÓڳɱ¾µÄÓÅ»¯Æ÷£¬»ùÓÚ¹æÔ ......
×ܵÄÀ´ËµwindowsÏÂÔØ°²×°oracleÈí¼þ±ÈlinuxÏÂÒª¼òµ¥µÄ¶à¡£
Ò».°²×°oracle ·þÎñ¶Ë
1.oracle·þÎñÆ÷µÄÏÂÔØÍøÖ·ÈçÏ£º
http://www.oracle.com/technology/software/products/database/index.html
È»ºóÎÒÑ¡ÔñÁËÏÂÃæÕâ¸ö°²×°°ü£º
Oracle Database 10g Release 2 ( ......