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

oracle²»¿É¸üеÄÊÔͼ

¹Ø¼ü´Ê£ºwith read only
×÷ÓãºÓÃÓÚÖ¸¶¨Ëù´´½¨µÄÊÔͼ²»¿ÉÒÔͨ¹ý±¾ÊÓͼ¸üбí
Ö´ÐÐÒ»ÏÂSQL£¬´´½¨±íT£¬ºÍÁ½¸öÊÔͼV1£¬V2£º
CREATE TABLE T(ID INTEGER);
CREATE VIEW V1 AS SELECT * from T;
CREATE VIEW V2 AS SELECT * from T WITH READ ONLY;
Ö´ÐÐSQL:
INSERT INTO V1 VALUES(1);
--------------------
1 row created
Ö´ÐÐSQL:
INSERT INTO V2 VALUES(1);
--------------------
Ìáʾ´íÎó
µ¥¶ÀµÄSELECTÓï¾ä²»ÄÜʹÓÃWITH READ ONLY
SELECT * from T WITH READ ONLY;
½«²»ÄÜÔËÐС£


Ïà¹ØÎĵµ£º

oracle ±í¿Õ¼ä²Ù×÷

oracle±í¿Õ¼ä²Ù×÷Ïê½â
  1
  2
  3×÷Õߣº   À´Ô´£º    ¸üÐÂÈÕÆÚ£º2006-01-04 
  5
  6 
  7½¨Á¢±í¿Õ¼ä
  8
  9CREATE TABLESPACE data01
 10DATAFILE '/ora ......

jdbcÁ¬½ÓOracle

      ËäȻѧϰJavaºÜ¾ÃÁË£¬×Ô¼ºÒ²Á¬½Ó¹ýһЩÊý¾Ý¿â£¬±ÈÈçmysqlÖ®ÀàµÄ£¬Èç½ñÄØ£¬Ò²Ñ§Ï°ÁËÒ»¶Îʱ¼äµÄOracle£¬È»¶øÄØ£¬½ñÌìÊÇÎÒµÚÒ»´ÎÁ¬½ÓOracle£¬ºÙºÙ£¬Ó¦¸Ã»¹²»ËãÌ«³Ù°É¡£
    ½ñÌìÄØ£¬Óе㱿׾£¬´ó¼ÒĪЦ£¡
    ÎÒÕâÊÇÒ»¸ö²éѯÀý×Ó
    Ê×ÏÈ£¬Ô ......

oracle¸´Ï°£¨Ò»£© Ö®OracleÌåϵ½á¹¹

      ѧϰOracle DBAÒ²°ë¸ö¶àѧÆÚÁË£¬½ñÌìÃÍÈ»²Å·¢ÏÖ£¬Ô­À´ÎÒµÄÊ黹ÊǺÜеģ¬ÉϿβÙ×÷ʱºòÒ²Ö»ÊÇÖªµÀ´ó¸ÅÔõô×ö£¬µ«ÊÇÒªÕæµÄÈ«²¿×Ô¼º×ö£¬¶ø²»È¥·­Ê黹ÊÇÓÐÒ»¶¨µÄÄѶȵģ¬ËùÒÔÄØ£¬½ñÌ쿪ʼ½«DBA´ÓÍ·¸´Ï°Ò»±é£¬Í¬Ê±ÔÙ²Ù×÷Ò»±é¡£
      µÚÒ»Õ£¬Ñ§µÄÊÇOracleµÄÌåϵ½á¹¹£ ......

Oracle Òì³£

OracleÒì³£·ÖΪ3ÖÖ:
(1)Ô¤¶¨ÒåÒì³£:no_data_foundµÈ,ÊÇOracleϵͳ¶¨ÒåµÄÒì³£.
declare
  s_test varchar2
begin
  select id into s_test from test; --´Ëʱtest±íÎÞÊý¾Ý
exception
  when no_data_found then
    raise_application_error(-20001, 'ûÓÐÊý¾Ý');
end;
(2)×Ô¶ ......

Oracle ÓÅ»¯²ßÂÔ(¶þ) »ù±íµÄÑ¡Ôñ

»ù´¡±í(Driving Table)ÊÇÖ¸±»×îÏÈ·ÃÎʵıí(ͨ³£ÒÔÈ«±íɨÃèµÄ·½Ê½±»·ÃÎÊ). ¸ù¾ÝÓÅ»¯Æ÷µÄ²»Í¬, SQLÓï¾äÖлù´¡±íµÄÑ¡ÔñÊDz»Ò»ÑùµÄ.
Èç¹ûÄãʹÓõÄÊÇCBO (COST BASED OPTIMIZER),ÓÅ»¯Æ÷»á¼ì²éSQLÓï¾äÖеÄÿ¸ö±íµÄÎïÀí´óС,Ë÷ÒýµÄ״̬,È»ºóÑ¡Óû¨·Ñ×îµÍµÄÖ´Ðз¾¶.
Èç¹ûÄãÓÃRBO (RULE BASED OPTIMIZER) , ²¢ÇÒËùÓеÄÁ¬½ÓÌõ¼þ¶ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ