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

Oracle×Ó²éѯ

×Ó²éѯ
 µ¥ÐÐ×Ó²éѯ(single-row subqueries)
    Ê¹ÓõÄÔËËã·ûºÅ(=,>,<,>=,<=,<>)
  ¶àÐÐ×Ó²éѯ(multiple-row subqueries)
    Ê¹ÓõÄÔËËã·ûºÅ(in,not in,exists,not exits,all,any)
   Ïà¹Ø×Ó²éѯ(correlated subqueries)
    ¸ñʽ select ÁÐÃû,(select Óï¾ä) from ±íÃû
   ±êÁ¿×Ó²éѯ(scalar subqueries)
    ×Ó²éѯÊÇ·µ»Øµ¥Ðе¥ÁÐ,¸ñʽͬÉÏ
   ¶àÁÐ×Ó²éѯ(multiple-column subqueries)
   ÔÚDDLÓï¾äÖÐʹÓÃ×Ó²éѯ
   ÔÚDMLÓï¾äÖÐʹÓÃ×Ó²éѯ
--------
µ¥ÐÐ×Ó²éѯ
 --ÏÔʾ¹¤×Ê×î¸ßµÄ¹ÍÔ±ÐÅÏ¢
 Select ename,deptno,sal from emp
 Where sal=(select max(sal) from emp);
--------
¶àÐÐ×Ó²éѯ
 --ÏÔʾÓ벿ÃűàºÅΪ20µÄ¸ÚλÏàͬµÄ¹ÍÔ±ÐÅÏ¢
 Select ename,deptno,sal,job from emp
 Where job in (select distinct job from emp where deptno=20);
 --ÏÔʾ²»Ó벿ÃűàºÅΪ20µÄ¸ÚλÏàͬµÄ¹ÍÔ±ÐÅÏ¢
 Select ename,deptno,sal,job from emp where job not in (select distinct job from emp where deptno=20);
 --ÏÔʾ¸ßÓÚ²¿ÃűàºÅΪ20µÄËùÓйÍÔ±µÄ¹¤×ʵĹÍÔ±ÐÅÏ¢
 select ename,deptno,sal ,job from emp
 where sal>all(select sal from emp where deptno=20);
 --ÏÔʾ¸ßÓÚ²¿ÃűàºÅΪ20µÄÈκιÍÔ±µÄ¹¤×ʵĹÍÔ±ÐÅÏ¢
 select ename,deptno,sal ,job from emp
 where sal>any(select sal from emp where deptno=20); 
---------
Ïà¹Ø×Ó²éѯ
 --ÏÔʾÿ¸ö²¿ÃŵÄ×î¸ß¹¤×ʵĹÍÔ±ÐÅÏ¢
 select deptno,(select max(sal) from emp b where b.deptno=a.deptno) maxsal
 from emp a order by deptno;
 --Ôö¼Ódistinct
 select distinct deptno,(select max(sal) from emp b where b.deptno=a.deptno) maxsal
 from emp a order by deptno;
 --ÏÔʾ¹¤×÷ÔÚNEW YORKµÄ¹ÍÔ±ÐÅÏ¢
 select ename,deptno,sal,job from emp
 where exists (select 'x' from dept where dept.deptno=emp.deptno and dept.loc='NEW YORK');
---------
±êÁ¿×Ó²éѯ
 --·µ»Øµ¥Ðе¥ÁÐ
 Select count(*) from emp;
 Select sum(sal)


Ïà¹ØÎĵµ£º

jdbc sqlserver oracle Çý¶¯ÎÊÌ⼯½õ

ojdbc14.jarÓëclasses12.jarÓÐʲôÇø±ð??
×î½üÓÃclasses12.jar£¬hibernate3.1ÀÏÊdzöÎÊÌ⣿
ÎÒµÄoracle9.2.0.10!
ÔÚÍøÉÏÕÒ£¬·¢ÏÖÓÐÈËÓÃojdbc14.jar¿ª·¢£¬Ã»ÓÐÓùýÄØ£¿¿´oracleµÄreadme.txtҲûÓп´Ê²Ã´ÄØ£¿
ÄÇλ´ó¸çÖªµÀ˵һÏ£¡Ê®·Ö¸Ðл£¡
------------------------------------------------------------------------- ......

¹ØÓÚoracleѧϰ,¶ÔÕÒ×ÊÁϽ׶εÄÓÐÒâÒå

ƽʱ½Ó´¥mysql½Ï¶à£¬ÒòΪmysqlÔÚÒ»°ãµÄСÏîÄ¿Öй»ÓÃÁË ¿ªÔ´¶øÇÒÃâ·Ñ¡£
ºÜ¶à¹«Ë¾ÐèÒªoracleά»¤µÄ£¬¿ª·¢oracleÉõÖÁÊǶþ´Î¿ª·¢ÔÚ¹úÄÚÒ²±È½ÏÉٵģ¬Óм׹ÇÎĹ«Ë¾£¬Ë­¸ÒºÍËûÃÇÇÀ·¹Íë°¡ ¹þ¹þ ²»¹ýÈ˼ҵÄÊÕ·ÑÂù¹óµÄ£¬ÄãÈç¹ûÓÐˮƽ£¬³Ôµã²Ð¸þµÄ»ú»áÂù¶à¡£ oracleµÄÅàѵÐÅÏ¢±í´ïÁËÊг¡ÐèÇó¡£
£¨ÎÒÔÚѧУ»·¾³µÄ²ÂÏ룬רҵÈËÊ¿À´ÅÄש ......

Oracle ÊÓͼ

Oracle ÊÓͼ
    ÊÓͼ: Äã¿ÉÒÔͨ¹ý´´½¨±íµÄÊÓͼÀ´±íÏÖÊý¾ÝµÄÂß¼­×Ó¼¯»òÊý¾ÝµÄ×éºÏ.ÊÓͼÊÇ»ùÓÚ±í»òÕßÁíÒ»¸ö
          ÊÓͼµÄÂß¼­±í,Ò»¸öÊÓͼ²¢²»°üº¬Ëü×Ô¼ºµÄÊý¾Ý,ËüÏóÒ»¸ö´°¿Ú,ͨ¹ý¸Ã´°¿Ú¿ÉÒԲ鿴»ò¸Ä±ä
         ......

Oracle Date Function ½²½âºÍÊÂÀý

http://blog.csdn.net/mustbelove/archive/2007/04/17/1567836.aspx(ת)
1 year=1*12 months
1 day=24
hours=24*(1*60mins)=24*60*(1*60 seconds)
1 week =7 days
×¢Ò⣺
ºÚÉ«×ÖÌåÊÇ oracle

8i£¬9i¶¼¿ÉÒÔʹÓõĺ¯Êý£¬
À¶É«×ÖÌåÊÇ Oracle
9i
ÐÂ
ÔöµÄ²¿·Ö¡£
 
Çë´ó¼ÒÔÚʹÓÃʱ£¬×¢Òâ°æ±¾ÏÞÖÆ¡£
add_mon ......

Oracle ´¥·¢Æ÷Óï·¨¼°ÊµÀý

Oracle´¥·¢Æ÷Óï·¨(Ò»)
Ò» Oracle´¥·¢Æ÷Óï·¨
´¥·¢Æ÷ÊÇÌض¨Ê¼þ³öÏÖµÄʱºò£¬×Ô¶¯Ö´ÐеĴúÂë¿é¡£ÀàËÆÓÚ´æ´¢¹ý³Ì£¬´¥·¢Æ÷Óë´æ´¢¹ý³ÌµÄÇø±ðÔÚÓÚ:´æ´¢¹ý³ÌÊÇÓÉÓû§»òÓ¦ÓóÌÐòÏÔʽµ÷ÓõÄ,¶ø´¥·¢Æ÷ÊDz»Äܱ»Ö±½Óµ÷Óõġ£
¹¦ÄÜ£º
1¡¢ ÔÊÐí/ÏÞÖƶԱíµÄÐÞ¸Ä
2¡¢ ×Ô¶¯Éú³ÉÅÉÉúÁУ¬±ÈÈç×ÔÔö×Ö¶Î
3¡¢ Ç¿ÖÆÊý¾ÝÒ»ÖÂÐÔ
4¡¢ ÌṩÉó¼Æº ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ