ORACLE ÓαêµÄʹÓÃ
declare cursor myCursor is select * from ±íÃû;
myRow myCursor%rowtype;
begin
open myCursor;
loop
fetch myCursor into myRow;
exit when myCursor%notfound;
--ÒªÖ´ÐеÄSQLÓï¾ä
end loop;
end;
Ïà¹ØÎĵµ£º
oracle±í¿Õ¼ä²Ù×÷Ïê½â
1
2
3×÷Õߣº À´Ô´£º ¸üÐÂÈÕÆÚ£º2006-01-04
5
6
7½¨Á¢±í¿Õ¼ä
8
9CREATE TABLESPACE data01
10DATAFILE '/ora ......
ORACLE±¸·Ý²ßÂÔ(ORACLE BACKUP STRATEGY)
2007Äê11ÔÂ02ÈÕ ÐÇÆÚÎå 16:03
¸ÅÒª
1¡¢Á˽âʲôÊDZ¸·Ý
2¡¢Á˽ⱸ·ÝµÄÖØÒªÐÔ
3¡¢Àí½âÊý¾Ý¿âµÄÁ½ÖÖÔËÐз½Ê½
4¡¢Àí½â²»Í¬µÄ±¸·Ý·½Ê½¼°ÆäÇø±ð
5¡¢Á˽âÕýÈ·µÄ±¸·Ý²ßÂÔ¼°ÆäºÃ´¦
Ò»¡¢Á˽ⱸ·ÝµÄÖØÒªÐÔ
¿ÉÒÔ˵£¬´Ó¼ÆËã»úϵͳ³öÊÀµÄÄÇÌìÆ𣬾ÍÓÐÁ˱¸·ÝÕâ¸ö¸ÅÄ ......
alter system kill session '²é³öµÄsid,²é³öµÄserial#';
ͨ過數據×ÖµäV$SESSION與V$LOCK來瞭½âÕýÔڵȴý鎖資Ô´µÄÓÃ戶
select a.username,a.sid,a.serial#,b.id1 from v$session a ,v$lock b
Where a.lockwait ......
²éѯ¼°É¾³ýÖظ´¼Ç¼µÄSQLÓï¾ä
1¡¢²éÕÒ±íÖжàÓàµÄÖظ´¼Ç¼£¬Öظ´¼Ç¼ÊǸù¾Ýµ¥¸ö×ֶΣ¨peopleId£©À´ÅжÏ
select * from people
where peopleId in (select peopleId from people group by peopleId having count(peopleId) > 1)
2¡¢É¾³ý±íÖжàÓàµÄÖظ´¼Ç¼£¬Öظ´¼Ç¼ÊÇ ......
SELECT * from ALL_SOURCE
where TYPE='PROCEDURE' AND TEXT LIKE
'%0997500%';
--²éѯALL_SOURCEÖУ¬£¨½Å±¾´úÂ룩ÄÚÈÝÓë0997500Ä£ºýÆ¥ÅäµÄÀàÐÍΪPROCEDURE£¨´æ´¢¹ý³Ì£©µÄÐÅÏ¢¡£
¸ù¾ÝGROUP
BY TYPE
¸ÃALL_SOURCEÖÐÖ»ÓÐÒÔÏÂ5ÖÖÀàÐÍ
1 FUNCTION
2 JAVA
SOURCE
3 PACKAGE
4 P ......