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

ÈÝÒ׺öÊÓµÄoracleº¯ÊýÎÊÌâ Êý¾ÝÀàÐÍ

×î½üʼÖÕ±»Êý¾Ý¿âÎÊÌâÀ§ÈÅ£¬³öÓÚÏîÄ¿Ó¦ÓÃÔ­Òò£¬¶¨ÒåÁËһЩoracle×Ô¶¨Ò庯Êý(User Defined function),ÓÃÓÚÔÚʵ¼Ê²éѯSQLÓï¾äÖе÷Óã¬Ä¿µÄÊÇΪÁ˼ò»¯SQLÓï¾äµÄ¸´ÔӶȡ£Êµ¼ÊʹÓÃÖз¢ÏÖ£¬ÕâЩº¯Êý»á³öÏÖÒ»¸öĪÃûÆæÃîµÄÎÊÌ⣬ÏÈÉÏʵÀý:
CREATE OR REPLACE FUNCTION "GETSINGLEUSER" --·µ»ØµÚÒ»¸ö×Ö·û´®
(sStr in nvarchar2)
return nvarchar2
 as
sReturn nvarchar2(50);
begin
if instr(sStr,',') > 0 then
sReturn := SUBSTR(sStr,1,instr(sStr,',') - 1);
else
sReturn := sStr;
end if;
return sReturn;
exception
when others then
return 'error';
end;
ÕâÊÇÆäÖÐÒ»¸öº¯Êý£¬¹¦Äܼܺòµ¥¾ÍÊÇÈ¡,·Ö¸ôµÄ¶à¸ö´®¼¯ÖеĵÚÒ»¸öÔªËØ·µ»Ø£¬µ«ÊÇÔÚʵ¼ÊSQLÓï¾äÖÐʹÓÃÖз¢ÏÖ£¬Èç¹û²éѯ·µ»ØÐÐÊý³¬¹ý100ÐУ¬100ÐкóµÄ¼Ç¼Öк¯ÊýûÓÐÖ´Ðнá¹û£¨¿ÉÅųý´«Èë²ÎÊýÎÊÌ⣩¡£¼ûͼ
Ó¦Óú¯ÊýGETSINGLEUSER ½øÐвéѯij±íijÁÐÊý¾Ýʱ£¬100ÐкóµÄ¼Ç¼Ã÷Ã÷ÊÇÓÐÖµµÄ£¬¶øÇÒÔÚº¯ÊýÌåÖÐÈç¹û³öÏÖÒì³£Ò²»áÓзµ»ØÖµerror,µ«ÊÇʵ¼ÊЧ¹û¾ÍÏñ100ÐеļǼûÓÐÖ´ÐйýÒ»Ñù¡£ÎªÊ²Ã´ÄØ£¿ÆäʵÕâ¸öÎÊÌâµ½ÏÖÔÚÎÒҲûÓÐÍêÈ«¸ãÃ÷°×¡£Ö»ÊÇ×Ô¼º·´¸´²âÊÔʵÑéºó£¬¸Ð¾õÓëÊý¾ÝÀàÐÍÓÐÒ»¶¨¹Øϵ£¬Îҵĺ¯ÊýÈë¿Ú²ÎÊýÉùÃ÷ÀàÐÍΪ:nvarchar2,¶øʵ¼Ê²éѯÖÐÒýÓÃÁеĶ¨ÒåÈçÏÂͼ£¬ÊÇcharÀàÐÍ£º
ËùÒÔÔÚº¯Êýµ÷Óô¦¾Í²ÉÈ¡Á˽«²ÎÊýÇ¿ÖÆת»»ÎªÈë¿ÚÀàÐÍ£º
 
½á¹ûÎÊÌâÏûʧ£¬±¾ÎÄÖ»ÄÜ˵Ã÷¸ÃÎÊÌâµÄ½â¾ö·½·¨£¬µ«È´²»ÄÜÍêȫ˵Ã÷³ÉÒò£¬ÒÔ¼°ÀàËÆΪʲôÊÇ100ÐÐÄصÈÎÊÌâ¡£


Ïà¹ØÎĵµ£º

oracle ±í¿Õ¼ä²Ù×÷

oracle±í¿Õ¼ä²Ù×÷Ïê½â
  1
  2
  3×÷Õߣº   À´Ô´£º    ¸üÐÂÈÕÆÚ£º2006-01-04 
  5
  6 
  7½¨Á¢±í¿Õ¼ä
  8
  9CREATE TABLESPACE data01
 10DATAFILE '/ora ......

¡¾×ª¡¿ÈçºÎ²é¿´oracle sqlÖ´Ðмƻ®

·½·¨Ò»
µÚÒ»²½£ºµÇÈësql/plus Ö´ÐÐÃüÁÎÞÏȺó˳Ðò£©
set   time   on; (˵Ã÷£º´ò¿ªÊ±¼äÏÔʾ£©  
  set   autotrace   on; (˵Ã÷£º´ò¿ª×Ô¶¯·ÖÎöͳ¼Æ£¬²¢ÏÔʾSQLÓï¾äµÄÔËÐнá¹û£©  
  set   autotrace   traceonly; (˵à ......

Jsp Á¬½Ó mySQL¡¢Oracle Êý¾Ý¿â±¸Íü

Jsp Á¬½Ó mySQL¡¢Oracle Êý¾Ý¿â±¸Íü
2009-12-15 16:47
Jsp »·¾³Ä¿Ç°×îÁ÷ÐеÄÊÇ Tomcat5.0¡£Tomcat5.0 ×Ô¼º°üº¬Ò»¸ö Web ·þÎñÆ÷£¬Èç¹ûÊDzâÊÔ£¬¾Íû±ØÒª°Ñ Tomcat Óë IIS »ò Apache ¼¯³ÉÆðÀ´¡£ÔÚ Tomcat ×Ô´øµÄ Web ·þÎñÆ÷Ï¿ÉÒÔ½øÐÐ Jsp ²âÊÔ¡£
    °²×° Tomcat5.0 Ç°ÐèÒª°²×° JDK(Èç¹ûÊÇ Windows server ......

oracleÖеÄto_char()

½éÉÜto_char(Êý×Ö, ‘¸ñʽ’)£¬±È½Ï³£Óõĸñʽ
9   ±íʾÓÐЧλÊý
0   ÓÃ0²¹×ãλÊý
B   Óÿոñ²¹×ãλÊý
Ô­ÊýµÄλÖÃÓÐʵ¼ÊÊý×ÖռλµÄʱºò£¬0ºÍ9µÄЧ¹ûÊÇÒ»ÑùµÄ¡£
0ºÍ9µÄÇø±ðÔÚÓÚ¸ñʽÖеÄÄÇһλÖÃʵ¼ÊÊý×ÖûÓÐվλµÄÇé¿öÏ¡£
select to_char(0.45,'0.99'); ½á¹ûÊÇ0.45
select ......

oracle½¨¶à¸ödblink

ÓÃtg4mssqlÁ´½Óoracle.
¹ý³Ì²»ÔÚÃèÊö£¬googleºÜ¶à¡£
ÎÊÌ⣺
1¡¢mssql expressµÄʱºò£¬Ê§°Ü
½«serverÓÃתÒå×Ö·ûд³ö£¬³É¹¦¡£
HS_FDS_CONNECT_INFO="SERVER=SHAM0415\\SQLEXPRESS;DATABASE=GMT_KJ"
2¡¢½¨¶à¸öµÄʱºò£¬²»ÄܽâÎö¡£ tnsping ÃüÁî×ܲ»Í¨¹ý¡£
ÕÒÁ˺ܶ࣬ͬһ¸öÌû×Ó£¬×ªÁËÎÞÊý´Î¡£¡£
°¦¡£¡£ÖйúµÄ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ