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

ORACLE¼¸¸ö¹ýÂËÌõ¼þµÄÖ´ÐÐ˳Ðò

select distinct id
  from table t
 where rownum < 10
 order by t.id desc;
ÉÏÊöÓï¾äµÄ¹ýÂËÌõ¼þÖ´ÐÐ˳Ðò ÏÈwhere --->order by --->distinct
Èç¹ûÓÐgroup byµÄ»° group by ÔÚorder byÇ°ÃæµÄ


Ïà¹ØÎĵµ£º

Oracleɾ³ýÖظ´Êý¾Ý

ÔÚ¶ÔÊý¾Ý¿â½øÐвÙ×÷¹ý³ÌÖÐÎÒÃÇ¿ÉÄÜ»áÓöµ½ÕâÖÖÇé¿ö£¬±íÖеÄÊý¾Ý¿ÉÄÜÖظ´³öÏÖ£¬Ê¹ÎÒÃǶÔÊý¾Ý¿âµÄ²Ù×÷¹ý³ÌÖдøÀ´ºÜ¶àµÄ²»±ã£¬ÄÇôÔõôɾ³ýÕâЩÖظ´Ã»ÓÐÓõÄÊý¾ÝÄØ?
¡¡¡¡Öظ´Êý¾Ýɾ³ý¼¼Êõ¿ÉÒÔÌṩ¸ü´óµÄ±¸·ÝÈÝÁ¿£¬ÊµÏÖ¸ü³¤Ê±¼äµÄÊý¾Ý±£Áô£¬»¹ÄÜʵÏÖ±¸·ÝÊý¾ÝµÄ³ÖÐøÑéÖ¤£¬Ìá¸ßÊý¾Ý»Ö¸´·þÎñˮƽ£¬·½±ãʵÏÖÊý¾ÝÈÝÔֵȡ£ Öظ´µÄÊý¾ ......

oracleÖÐÎÄ×Ö¶ÎÌæ»»»Ø³µ

Q£ºÎҵıíÖÐÓÐÒ»¸ö×Ö¶ÎÊÇvarchar2(4000)   £¬ÆäÖд洢Á˲»ÉÙÖÐÎÄ£¬ÏÖÔÚÓÉÓÚÅÅ°æÐèÒª£¬ÎÒÏëÕÒ³öº¬Óлسµ·ûµÄ¼Ç¼ɾ³ý»Ø³µ·û£¬ÇëÎʸßÊÖSQLÓï·¨Ôõôд£¿
A£ºOracleÖлسµ·ûÊÇchr(10),¿ÉÒÔʹÓú¯Êýreplace(×Ö¶Î,chr(10),'')
È磺 update   x   set   a=replace(a,chr(10),'')¡£
º¯Êý£º
1.CHR
¸ø³öÕûÊ ......

OracleµÄ»ù±¾²Ù×÷£«Oracle×Ö¶ÎÀàÐÍ£¨zz£©

ÔÚOracle¹ØÓÚʱ¼äÊôÐԵĽ¨±í
Example:
create table courses(
cid varchar(20) not null primary key,
cname varchar(20) not null,
ctype integer,
ctime date DEFAULT SYSDATE,
cscore float not null
)
insert into courses values('ss01','java',0,TO_DATE('2009-8-28','yyyy-mm-dd'),94)
insert into course ......

ORACLE¿çÊý¾Ý¿â²Ù×÷£¬DBLINKµÄʹÓÃ


Ç°¼¸Ìì°ïÒ»¸öÅóÓÑŪORACLE¿çÊý¾Ý¿âµÄ²Ù×÷£¬¹²ÏíϾßÌåµÄ²Ù×÷Á÷³Ì£º
Ò»¡¢²»Í¬IPµÄÊý¾Ý¿â£¨DBLINK£©
±¾µØÊý¾Ý¿âip 10.56.7.26
Ô¶³ÌÊý¾Ý¿âip 233.215.219.8
1.ÔÚ10.56.7.26Êý¾Ý¿â°²×°ÎļþÖУ¬ÕÒµ½$ORACLE_HOME/network/admin/tnsnames.oraÎļþ£¬
ĩβÌí¼Ó
MEDIADBLINK =
  (DESCRIPTION =
   &n ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ