oracleÓï¾äËæÐ´
ΪÁËÈ·¶¨±í¿Õ¼äÖаüº¬ÄÇЩÄÚÈÝ£¬ÔËÐУº
select owner,segment_name,segment_type
from dba_segments
where tablespace_name='<name of tablespace>'
²éѯ±í¿Õ¼ä°üº¬¶àÉÙÊý¾ÝÎļþ¡£
select file_name, tablespace_name
from dba_data_files
where tablespace_name ='<name of tablespace>';
½¨Á¢±í¿Õ¼ä
CREATE TABLESPACE data01
DATAFILE '/oracle/oradata/db/DATA01.dbf' SIZE 500M
UNIFORM SIZE 128k; #Ö¸¶¨Çø³ß´çΪ128k,Èç²»Ö¸¶¨£¬Çø³ß´çĬÈÏΪ64k
ÒÆ¶¯±íÖÁÁíÒ»±í¿Õ¼ä
alter table move tablespace room1;
oracleÔÚÓõÄsql
select s.sid, event, wait_time, w.seq#, q.sql_text
from v$session_wait w, v$session s, v$process p, v$sqlarea q
where s.paddr=p.addr and
s.sql_address=q.address
SELECT se.sid, se.username, se.program, sq.sql_text
from v$session se,v$sqlarea sq
WHERE se.sql_address = sq.address
v$session ±íÖбȽϳ£Óõö×Ö¶Î˵Ã÷^_^ Ñ¡×Ôhttp://blog.csdn.net/yzsind/archive/2005/02/27/303910.aspx
1.
sid,serial#
ͨ¹ýsidÎÒÃÇ¿ÉÒÔ²éѯÓëÕâ¸ösessionÏà¹ØµÄ¸÷ÖÖͳ¼ÆÐÅÏ¢,´¦ÀíÐÅÏ¢.
a. select * from
v$sesstat where sid = :sid;
²éѯÓû§Ïà¹ØµÄ¸÷ÖÖͳ¼ÆÐÅÏ¢.
select
a.sid,a.statistic#,b.name,a.value
from v$sesstat a,v$statname b
where
a.statistic# = b.statistic#
and a.sid = :sid;
b.
²éѯÓû§Ïà¹ØµÄ¸÷ÖÖioͳ¼ÆÐÅÏ¢
select * from v$sess_io where sid = :sid;
c.
²éѯÓû§ÏëÔÚÕýÔÚ´ò¿ª×ŵÄÓαê±äÁ¿.
select * from v$open_cursor where sid = :sid;
d.
²éѯÓû§µ±Ç°µÄµÈ´ýÐÅÏ¢. ÒԲ鿴µ±Ç°µÄÓï¾äΪʲôÕâôÂý/Ôڵȴýʲô×ÊÔ´.
select * from v$session_wait where sid =
:sid ;
e. ²éѯÓû§ÔÚÒ»¶Îʱ¼äÄÚËùµÈ´ýµÄ¸÷ÖÖʼþµÄÐÅÏ¢. ÒÔÁ˽âÕâ¸ösession
Ïà¹ØÎĵµ£º
oracle±í¿Õ¼ä²Ù×÷Ïê½â
1
2
3×÷Õߣº À´Ô´£º ¸üÐÂÈÕÆÚ£º2006-01-04
5
6
7½¨Á¢±í¿Õ¼ä
8
9CREATE TABLESPACE data01
10DATAFILE '/ora ......
Êý¾Ý¿âµÄÆô¶¯ÓÐÈýÖÖ£º
1
£º
startup nomount
ÕâÖÖ¹ý³ÌÓÖ³ÆÎª£º·Ç°²×°Æô¶¯
Æô¶¯¹ý³ÌΪ£ºÆô¶¯
oracle
ʵÀý£¬²»¼ÓÔØÊý¾Ý¿â£¬²»´ò¿ªÊý¾Ý¿â¡£ÔÚÕâ¸ö¹ý³ÌÖÐÖ»ÐèÒª
init.ora
³õʼ»¯²ÎÊýÎļþ£¬Öؽ¨¿ØÖÆÎļþ£¬¼´Æô¶¯ ......
×î½üÓÐÒ»ÈÎÎñ£¬ÐèҪʹÓÃOracleÊý¾Ý¿â£¬ÒÔǰ¶Ô´Ë²»Ì«ÊìϤ£¬¾Í´ÓÍøÉϲéÕÒ×ÊÁÏ£¬£¨ËµÊµÔÚµÄÍøÂçÕæÊÇÌ«ºÃÁË£¬Ò²¶à¿÷ÁËÐí¶àµÄÈÈÐĵļ¼ÊõÈËÔ±£¬Ô¸Òâ°Ñ×Ô¼ºµÄ¾ÑéºÍÐĵÃÓë´ó¼Ò·ÖÏí£©²¢×ªÌùÁËÒ»¸öÌû×Ӳο¼£¬²»¹ý´ËÌû×ÓÓÐЩµØ·½Ã»ÓÐ˵Çå³þ£¬È·ÊµÈÃÎÒ·ÑÁ˺ô󾢣¬²Å²âÊԳɹ¦¡£ÏÂÃæÎÒ°ÑÎҵIJ½Öè˵Ã÷һϣº£¨»·¾³£ºWindows XP sp2 + vs ......
Ò»¡¢PL/SQL³öÏÖµÄÄ¿µÄ
¡¡¡¡½á¹¹»¯²éѯÓïÑÔ(Structured Query
Language£¬¼ò³ÆSQL)ÊÇÓÃÀ´·ÃÎʹØÏµÐÍÊý¾Ý¿âÒ»ÖÖͨÓÃÓïÑÔ£¬ËüÊôÓÚµÚËÄ´úÓïÑÔ£¨4GL£©£¬ÆäÖ´ÐÐÌØµãÊǷǹý³Ì»¯£¬¼´²»ÓÃÖ¸Ã÷Ö´ÐеľßÌå·½·¨ºÍ;
¾¶£¬¶øÊǼòµ¥µÄµ÷ÓÃÏàÓ¦Óï¾äÀ´Ö±½ÓÈ¡µÃ½á¹û¼´¿É¡£ÏÔÈ»£¬ÕâÖÖ²»¹Ø×¢ÈκÎʵÏÖϸ½ÚµÄÓïÑÔ¶ÔÓÚ¿ª·¢ÕßÀ´ËµÓÐ׿«´óµÄ ......
ÓкܶàÓ¦ÓÃÏîÄ¿, ¸ÕÆð²½µÄʱºòÓÃMYSQLÊý¾Ý¿â»ù±¾ÉÏÄÜʵÏÖ¸÷ÖÖ¹¦ÄÜÐèÇó£¬Ëæ×ÅÓ¦ÓÃÓû§µÄÔö¶à£¬Êý¾ÝÁ¿µÄÔö¼Ó£¬MYSQL½¥½¥µØ³öÏÖ²»¿°ÖظºµÄÇé¿ö£ºÁ¬½ÓºÜÂýÉõÖÁå´»ú£¬ÓÚÊǾÍÓаÑÊý¾Ý´ÓMYSQLǨµ½ORACLEµÄÐèÇó£¬Ó¦ÓóÌÐòÒ²ÒªÏàÓ¦×öһЩÐ޸ġ£±¾ÈË×ܽá³öÒÔϼ¸µã×¢ÒâÊÂÏϣÍû¶Ô´ó¼ÒÓÐËù°ïÖú¡£
1£® ×Ô¶¯Ôö³¤µÄÊý¾ ......