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

¹ØÓÚoracleÖÐSYSTEMµÄÎÊÌâ - Oracle / »ù´¡ºÍ¹ÜÀí

ÏúÊÛ±í½á¹¹ÈçÏÂ
SALES

sale_id NOT NULL NUMBER
prod_id NOT NULL NUMBER
cust_id NOT NULL NUMBER
time_id NOT NULL DATE

ÎÒÒª²éѯ¹ýÈ¥3ÄêµÄÏúÊۼǼ£¬ÈçÏÂSQL
SELECT * 
from SALES
WHERE SYSDATE-3*365>=time_id


ÒÔÉÏsqlÓï¾äÊÇÊé±¾Éϱê¼ÇΪÕýÈ·µÄ´ð°¸£¬µ«ÊÇÎÒ¾õµÃwhereºóÃæµÄÓï¾ä²»¶Ô£¬ÎÒ¾õµÃÓ¦¸Ã¸Ä³Étime_id>=SYSDATE-3*365¡£
ÎҼǵÃÓÐÈËÔø¸æËßÎÒ£¬½ñÌìµÄÈÕÆÚ±È×òÌì´ó£¬×òÌìµÄÈÕÆÚ±ÈÇ°Ìì´ó£¬ÒÔ´ËÀàÍÆ¡£¡£¡£¡£

ÇëÎÊ£¬µ½µ×ÊÇÄĸö¶Ô£¿ лл





ÏÖÔÚ´óÓÚ¹ýÈ¥
select * from sales where time_id>=sysdate-interval '3' year;

SYSDATE-3*365>=time_id --3ÄêÇ°µÄ
time_id>=SYSDATE-3*365--¹ýÈ¥ÈýÄêÒÔÀ´ ÖÁ½ñ
¶¥lzµÄ·½·¨

ÒýÓÃ

SYSDATE-3*365>=time_id --3ÄêÇ°µÄ
time_id>=SYSDATE-3*365--¹ýÈ¥ÈýÄêÒÔÀ´ ÖÁ½ñ
¶¥lzµÄ·½·¨

sorry ÖÁ½ñÖ»ÊDZȽϿ͹Ûʵ¼ÊµÄ˵·¨ Ò²¿ÉÒÔÊÇ2012ѽ ¹þ¹þ

ÒýÓÃ
ÏúÊÛ±í½á¹¹ÈçÏÂ
SALES

sale_id NOT NULL NUMBER
prod_id NOT NULL NUMBER
cust_id NOT NULL NUMBER
time_id NOT NULL DATE

ÎÒÒª²éѯ¹ýÈ¥3ÄêµÄÏúÊۼǼ£¬ÈçÏÂSQL
SELECT *
from SALES
WHERE SYSDATE-¡­¡­

ÊéÉÏÊÇ´íµÄ¡£ÄãÊǶԵġ£


Ïà¹ØÎÊ´ð£º

Çë½ÌsqlÓï¾ä¡£ - Oracle / ¿ª·¢

ÎÒÓÐÒ»¸ö±í£¬½á¹¹ÊÇÕâÑù¡£
  ת³ö µ¥Î» תÈ뵥λ ±ÊÊý ½ð¶î
date(Ö÷) outid(Ö÷) inid(Ö÷) num amt
2009 1 2 1 500 Ϊ 1 µ¥Î» ÔÚ2009Ä ......

Windows 7 ÔõÑù°²×°Oracle - Oracle / »ù´¡ºÍ¹ÜÀí

¸÷λ´ó¸ç£¬°ï¸öæ¡£

ϸöOracle for vista °æ±¾µÄ°²×°ÊÔÊÔ
10GºÍ11GµÄ 
http://www.oracle.com/technology/software/products/database/index.html 
------------------------------------------- ......

oracle 9i ×î½ü·¢Ïֵǽ±¨´í - Oracle / »ù´¡ºÍ¹ÜÀí

ÓÃPL/SQL µÇ½ʱµ¯³ö±¨´í´°¿Ú£¬´íÎóÈçÏ£¡
  ORA-01034:ORACLE not available
  ORA-27101:shared memory realm does not exist
ÇëÎÊ£¬ÓÐûÓÐÈËÓöµ½ÕâÖÖÇé¿ö£¬Ôõô½â¾ö£¿Ð»Ð»£¡

1. Oracle sid ÕýÈ ......

OracleÈÏÖ¤ - Oracle / ÈÏÖ¤Ó뿼ÊÔ

ORACLEÅàѵ(OCA)ÈÏÖ¤½éÉÜ 
Oracle10g Certified Associate (OCA) Oracle ÈÏ֤רԱ¡£
¿¼ÊԳɼ¨Í¨¹ýÄÜ»ñµÃOracle¹«Ë¾ÎªÄú°ä·¢µÄÈ«ÇòÈÏÖ¤µÄÓ¢ÎÄOCAÖ¤Êé¡£OCAÓÉOracle¹«Ë¾³öÌâ¡£
¸ÃÖ¤Êé¿É×÷Ϊ¸÷ÆóÊÂÒµµ¥Î»Êý¾Ý¿ ......

OracleÐÐתÁÐ - Oracle / ¸ß¼¶¼¼Êõ

select distinct '1' t1,'2' t2,'3' t3,'4' t4 from table ²é³öÀ´µÄ½á¹ûΪ
1,2,3,4
ÎÒÏëµÃÒÔÏÂÕâÑùµÄЧ¹û
1
2
3
4
ÇëÎÊÒ»ÏÂÓÐʲô°ì·¨¿ÉÒÔ½â¾ö???
ûÓкõķ½·¨£¬ÓÃunion£¬Ò»ÌõÌõ¼Ç¼ƴ½Ó

SQL code:
wi ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ