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

oracleÁÐתÐÐÎÊÌâ - Oracle / »ù´¡ºÍ¹ÜÀí

ÏÖÔÚÒ»¸ö±íÖÐÓÐÁ½ÁÐÊý¾Ý
shuliang area
1 025
2 0510
3 0511
4 0512
5 0513
ÒªÇóÊÇ°Ñarea×Ö¶ÎÖеÄֵת»»³É³ÇÊÐÃû³Æ£¬±ÈÈç025ÊÇÄϾ©£¬0510ÊÇÎÞÎý£¬0511ÊÇÕò½­£¬0512ÊÇËÕÖÝ£¬0512ÊÇÄÏͨ
ÏÔʾ³É
ÄϾ© ÎÞÎý Õò½­ ËÕÖÝ ÄÏͨ
1 2 3 4 5

ÇëÎÊsqlÔõôд°¡

SQL code:

select sum(case when area = '025' then shuliang else 0 end) as ÄϾ©
,sum(case when area = '0510' then shuliang else 0 end) as ÎÞÎý
,sum(case when area = '0511' then shuliang else 0 end) as Õò½­
,sum(case when area = '0512' then shuliang else 0 end) as ËÕÖÝ
,sum(case when area = '0513' then shuliang else 0 end) as ÄÏͨ
from ±íÃû;



select 
case when area='025' then shuliang end ÄϾ©,
case when area='0510' then shuliang end ÎÞÎý,
case when area='0511' then shuliang end Õò½­,
case when area='0512' then shuliang end ËÕÖÝ,
case when area='0513' then shuliang end ÄÏͨ
from ±í;

select sum(decode(area, '025', 1, 0)) as ÄϾ©,
  sum(decode(area, '0510', 1, 0)) as ÎÞÎý,
  sum(decode(area, '0511', 1, 0)) as Õò½­,
  sum(decode(area, '0512', 1, 0)) as ËÕÖÝ,
  sum(decode(area, '0513', 1, 0)) as ÄÏͨ
  from t
 group by area



Ïà¹ØÎÊ´ð£º

oracle·þÎñ״̬ÏÔʾ ¡°Í£Ö¹¡±

ÎÒÊÇÓÃÔ¶³Ì×ÀÃæÁ¬²Ù×÷·þÎñÆ÷ÉϵÄÊý¾Ý¿â¡£
ÔÚ´´½¨Ò»¸öÓû§Ö®ºó£¬ÔÙÓÃPLSQLµÇ¼£¬ÔòPLSQLËÀµôÁË¡£
ÎҹصôPLSQLÖ®ºó£¬ÓÃÆäËûÓû§Ò²²»ÄܵǼ¡£

ÎÒ°ÑoracleµÄ·þÎñÍ£Ö¹£¬½á¹û¾ÍÊÇoracleµÄ·þÎñ״̬¾ÍÍ£ÁôÔÚ¡°Í ......

OracleÀëÏß·ÃÎÊ---ÇóÖú - Oracle / »ù´¡ºÍ¹ÜÀí

´ó¼ÒºÃ,ÎÒÏÖÔÚ°Ñoracle·þÎñÆ÷ÉÏÃæµÄԭʼÎļþ,ÏÂÔص½±¾»úÁË.ÎÒÏëÔÚ±¾»ú·ÃÎÊÊý¾Ý¿âÔõôÉèÖð¡.ÊDz»ÊÇÀàËÆ¿ÉÒÔ½¨Á¢Ò»¸öʲôÐéÄâ·þÎñÆ÷À´ÊµÏÖ.Çë´ó¼Ò³ö³öÖ÷Òâ
ÒýÓÃ
    ´ó¼ÒºÃ,ÎÒÏÖÔÚ°Ñoracle·þÎñÆ÷ÉÏÃæ ......

oracle spatial¿Õ¼äº¯Êý³ö´í - Oracle / ¸ß¼¶¼¼Êõ

ÔÚÖ´ÐаüµÄʱºòÒýÓÃoracle spatial¿Õ¼äº¯Êý³ö´í£¬³ö´íÇé¿öÈçÏÂ
Errors in file
/user/oracle/app/oracle/admin/grid/udump/grid1_ora_143768.trc: ORA-29902:
error in executing ODCIIndexStart() routine ORA-0 ......

oracleÓëaix - Oracle / ¸ß¼¶¼¼Êõ

ÔÚϵͳÔËÐеÄʱºò×ÜÊÇÓÐÒ»¿é´ÅÅÌʼÖÕÉÁºìµÆ£¬½øÈëϵͳºó
#topas²é¿´×ÜÊÇÓÐÒ»¿é´ÅÅÌ%BUSYΪ90%ÒÔÉÏ£¬
Êý¾Ý¿â°æ±¾£ºoracle 9.2.0.7 
Êý¾ÝÎļþ¹ÒÔصĽڵ㣺/oradata/pcs/ Âß¼­¾íºÅlv04 
#lslv -l lv04 ......

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

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

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