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

ORACLEÊÓͼ


2008Äê06ÔÂ01ÈÕ ÐÇÆÚÈÕ 14:52
OracleµÄÊý¾Ý¿â¶ÔÏó·ÖΪÎåÖÖ£º±í£¬ÊÓͼ£¬ÐòÁУ¬Ë÷ÒýºÍͬÒå´Ê¡£ 
ÊÓͼÊÇ»ùÓÚÒ»¸ö±í»ò¶à¸ö±í»òÊÓͼµÄÂß¼­±í£¬±¾Éí²»°üº¬Êý¾Ý£¬Í¨¹ýËü¿ÉÒÔ¶Ô±íÀïÃæµÄÊý¾Ý½øÐвéѯºÍÐ޸ġ£ÊÓͼ»ùÓڵıí³ÆΪ»ù±í¡£ 
ÊÓͼÊÇ´æ´¢ÔÚÊý¾Ý×ÖµäÀïµÄÒ»ÌõselectÓï¾ä¡£ ͨ¹ý´´½¨ÊÓͼ¿ÉÒÔÌáÈ¡Êý¾ÝµÄÂß¼­Éϵļ¯ºÏ»ò×éºÏ¡£ 
ÊÓͼµÄÓŵ㣺 
1.¶ÔÊý¾Ý¿âµÄ·ÃÎÊ£¬ÒòΪÊÓͼ¿ÉÒÔÓÐÑ¡ÔñÐÔµÄÑ¡È¡Êý¾Ý¿âÀïµÄÒ»²¿·Ö¡£ 
2.Óû§Í¨¹ý¼òµ¥µÄ²éѯ¿ÉÒÔ´Ó¸´ÔÓ²éѯÖеõ½½á¹û¡£ 
3.ά»¤Êý¾ÝµÄ¶ÀÁ¢ÐÔ£¬ÊÔͼ¿É´Ó¶à¸ö±í¼ìË÷Êý¾Ý¡£ 
4.¶ÔÓÚÏàͬµÄÊý¾Ý¿É²úÉú²»Í¬µÄÊÓͼ¡£ 
ÊÓͼ·ÖΪ¼òµ¥ÊÓͼºÍ¸´ÔÓÊÓͼ£º 
¼òµ¥ÊÓͼֻ´Óµ¥±íÀï»ñÈ¡Êý¾Ý 
¸´ÔÓÊÓͼ´Ó¶à±í 
¼òµ¥ÊÓͼ²»°üº¬º¯ÊýºÍÊý¾Ý×é 
¸´ÔÓÊÓͼ°üº¬ 
¼òµ¥ÊÓͼ¿ÉÒÔʵÏÖDML²Ù×÷ 
¸´ÔÓÊÓͼ²»¿ÉÒÔ. 
ÊÓͼµÄ´´½¨£º 
CREATE [OR REPLACE] [FORCE|NOFORCE] VIEW view_name 
[(alias[, alias]...)] 
AS subquery 
[WITH CHECK OPTION [CONSTRAINT constraint]] 
[WITH READ ONLY] 
ÆäÖУº 
OR REPLACE £ºÈôËù´´½¨µÄÊÔͼÒѾ­´æÔÚ£¬ORACLE×Ô¶¯Öؽ¨¸ÃÊÓͼ£» 
FORCE £º²»¹Ü»ù±íÊÇ·ñ´æÔÚORACLE¶¼»á×Ô¶¯´´½¨¸ÃÊÓͼ£» 
NOFORCE £ºÖ»Óлù±í¶¼´æÔÚORACLE²Å»á´´½¨¸ÃÊÓͼ£º 
alias £ºÎªÊÓͼ²úÉúµÄÁж¨ÒåµÄ±ðÃû£» 
subquery £ºÒ»ÌõÍêÕûµÄSELECTÓï¾ä£¬¿ÉÒÔÔÚ¸ÃÓï¾äÖж¨Òå±ðÃû£» 
WITH CHECK OPTION £º 
²åÈë»òÐ޸ĵÄÊý¾ÝÐбØÐëÂú×ãÊÓͼ¶¨ÒåµÄÔ¼Êø£» 
WITH READ ONLY £º 
¸ÃÊÓͼÉϲ»ÄܽøÐÐÈκÎDML²Ù×÷¡£ 
ÀýÈ磺 
CREATE OR REPLACE VIEW dept_sum_vw 
(name,minsal,maxsal,avgsal) 
AS SELECT d.dname,min(e.sal),max(e.sal),avg(e.sal) 
from emp e,dept d 
WHERE e.deptno=d.deptno 
GROUP BY d.dname; 
ÊÓͼµÄ¶¨ÒåÔ­Ôò£º 
1.ÊÓͼµÄ²éѯ¿ÉÒÔʹÓø´ÔÓµÄSELECTÓï·¨£¬°üÀ¨Á¬½Ó/·Ö×é²éѯºÍ×Ó²éѯ£» 
2.ÔÚûÓÐWITH CHECK OPTIONºÍ READ ONLY µÄÇé¿öÏ£¬²éѯÖв»ÄÜʹÓà
ORDER BY ×Ӿ䣻 
3.Èç¹ûûÓÐΪCHECK OPTIONÔ¼ÊøÃüÃû£¬ÏµÍ³»á×Ô¶¯ÎªÖ®ÃüÃû£¬ÐÎʽΪSYS_Cn; 
4.OR REPLACEÑ¡Ïî¿ÉÒÔ²»É¾³ýÔ­ÊÓͼ±ã¿É¸ü¸ÄÆ䶨Òå²¢Öؽ¨£¬»òÖØÐÂÊÚÓè¶ÔÏó 
ȨÏÞ¡£ 
ÊÓͼµÄ²éѯ£º 


Ïà¹ØÎĵµ£º

Oracle°²È«È«½Ó´¥£¨ÉÏ£©

Ëæ׿ÆËã»úµÄÆÕ¼°ÒÔ¼°ÍøÂçµÄ·¢Õ¹£¬Êý¾Ý¿âÒѾ­²»ÔÙ½ö½öÊÇÄÇЩ³ÌÐòÔ±ËùרÓеĻ°Ìâ¡£¶øOracleÊý¾Ý¿â¸üÊÇƾ½èÆäÐÔÄÜ׿Խ£¬²Ù×÷·½±ãÁé»îµÄÌص㣬ÔÚÊý¾Ý¿âµÄÊг¡ÖÐÒѾ­Õ¼¾ÝÁËһϯ֮µØ¡£µ«ÊÇͬÑùËæ×ÅÍøÂç¼¼ÊõµÄ²»¶Ï½ø²½£¬Êý¾ÝÐÅÏ¢µÄ²»¶ÏÔö¼Ó£¬Êý¾Ý°²È«ÒѾ­²»ÔÙÊÇÒÔÇ°µÄ“ÀÏÉú³¤Ì¸”£¬Ò²¸ü²»ÊÇÒÔÇ°Êé±¾ÉÏÄÇЩ“¿ÉÍû² ......

ORACLE to_charº¯ÊýÏê½â

 The following are number examples for the to_char function.
to_char(1210.73, '9999.9')
would return '1210.7'
to_char(1210.73, '9,999.99')
would return '1,210.73'
to_char(1210.73, '$9,999.00')
would return '$1,210.73'
to_char(21, '000099')
would return '000021'
The following is a list ......

Oracle Òƶ¯Êý¾ÝÎļþµÄ²Ù×÷·½·¨


½«±í¿Õ¼äºÍÊý¾ÝÎļþ´ÓÒ»¸öλÖÃÒƶ¯µ½ÁíÒ»¸öλÖõIJÙ×÷·½·¨
Ò»£® OFFLINE
OFFLINE ·ÖΪALTER DATABASE Óë ALTER TABLESPACE OFFLINE£¬
ËûÃǵÄÇø±ð²Î¿´blog£ºhttp://blog.csdn.net/tianlesoftware/archive/2009/11/29/4898800.aspx
°´Êý¾ÝÎļþÀ´£º
1.ÏȽ«ÏàÓ¦µÄÊý¾ÝÎļþ offl ......

oracleÒì¹¹¡¢Í¬¹¹Êý¾Ý¿âÖ®¼äµÄͬ²½×ÊÁÏ£¨²Î¿¼£©

1)SQL ServerÁ´½Ó·þÎñÆ÷ Linked Server·½Ê½£¨SQLServer×÷ΪԴ·þÎñÆ÷£©£º
http://www.cnblogs.com/riccc/archive/2009/07/23/sql-server-linked-server.html
2)Oracle¸ß¼¶¸´ÖÆ£¨oracleÊý¾Ý¿âÖ®¼ä¸´ÖÆ£©£º
http://www.chinaunix.net/bbsjh/8/54.html
ÆäËû¼¼Êõ·½·¨£º
  snapshot  
  Replication   ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ