oracle, stored procedure, cursor
CREATE OR REPLACE PROCEDURE kevin_proc(x varchar) IS
a VARCHAR(20);
b VARCHAR(20);
CURSOR mycur(rn NUMBER) IS SELECT * from t_kevin_test WHERE ROWNUM<rn;
BEGIN
OPEN mycur(10);
LOOP FETCH mycur INTO a,b;
EXIT WHEN mycur%NOTFOUND;
Dbms_Output.put_line('a: '||a);
Dbms_Output.put_line('b: '||b);
END LOOP;
CLOSE mycur;
begin
dbms_output.put_line (x);
end;
END;
Ïà¹ØÎĵµ£º
<!--
/* Font Definitions */
@font-face
{font-family:Wingdings;
panose-1:5 0 0 0 0 0 0 0 0 0;
mso-font-charset:2;
mso-generic-font-family:auto;
mso-font-pitch:variable;
mso-font-signature:0 268435456 0 0 -2147483648 0;}
@font-face
{font-family:ËÎÌå;
panose-1:2 1 6 0 3 1 1 1 ......
˵µ½HWM,ÎÒÃÇÊ×ÏÈÒª¼òÒªµÄ̸̸ORACLEµÄÂß¼´æ´¢¹ÜÀí.ÎÒÃÇÖªµÀ,ORACLEÔÚÂß¼´æ´¢ÉÏ·Ö4¸öÁ£¶È:±í¿Õ¼ä,¶Î,ÇøºÍ¿é.
(1)¿é:ÊÇÁ£¶È×îСµÄ´æ´¢µ¥Î»,ÏÖÔÚ±ê×¼µÄ¿é´óСÊÇ8K,ORACLEÿһ´ÎI/O²Ù×÷Ò²ÊÇ°´¿éÀ´²Ù×÷µÄ,Ò²¾ÍÊÇ˵µ±ORACLE´ÓÊý¾ÝÎļþ¶ÁÊý¾Ýʱ,ÊǶÁÈ¡¶àÉÙ¸ö¿é,¶ø²»ÊǶàÉÙÐÐ.
(2)Çø:ÓÉһϵÁÐÏàÁڵĿé¶ø×é³É,ÕâÒ²ÊÇORACLE¿Õ¼ ......
oracle²»Óð²×°¿Í»§¶ËÒ²¿ÉÒÔÓÃplsqlÔ¶³ÌÁ¬½Ó(ת£©
oracle²»Óð²×°¿Í»§¶ËÒ²¿ÉÒÔÓÃplsqlÔ¶³ÌÁ¬½Ó pl sqlÔ¶³ÌÁ¬½Ó
2008-01-14 14:33
oracle²»Óð²×°¿Í»§¶ËÒ²¿ÉÒÔÓÃplsqlÔ¶³ÌÁ¬½Ó
ÿ´ÎÎÊÈ˼ң¬plsql ¿É²»¿ÉÒÔÖ±½ÓÔ¶³ÌÁ¬½Ó·þÎñÆ÷£¬ËûÃǶ¼ËµÒª°²×°¿Í»§¶Ë£¬¼ÇµÃÒÔÇ°Ó ......
oracleÆô¶¯ÎÊÌâ
Ò»£ºÊý¾Ý¿âûÓÐÆô¶¯
#sqlplus /nolog
sql>connect /as sysdba
sql>startup
¶þ£º¼àÌý³öÎÊÌâ
µÇ¼DB·þÎñÆ÷
ʹÓÃlsnrctl start/stop¿ªÆô/¹Ø±Õ¼àÌý
ʹÓÃlsnrctl status²é¿´×´Ì¬
ÀíӦΪ£º
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=ERPAP)(PORT=1521)))
STATUS of the ......