oracle½â³öËÀËøµÄ°ì·¨
1£ºÒÔÒ»¸öDBAÉí·ÖµÄÓû§µÇ½£¬´ò¿ªÒ»¸öÃüÁî´°¿Ú¡£Ö´ÐÐÃüÁî
SELECT /*+ rule */ s.username,
decode(l.type,'TM','TABLE LOCK',
'TX','ROW LOCK',
NULL) LOCK_LEVEL,
o.owner,o.object_name,o.object_type,
s.sid,s.serial#,s.terminal,s.machine,s.program,s.osuser
from v$session s,v$lock l,dba_objects o
WHERE l.sid = s.sid
AND l.id1 = o.object_id(+)
AND s.username is NOT Null
2£º²éѯËøסµÄ±í¡£
3£ºÔÚtoolsϵÄsessionÖÐkillËø±íµÄ»á»°¡£
Ïà¹ØÎĵµ£º
Êý¾ÝÀàÐÍ
²ÎÊý
ÃèÊö
char(n)
n=1 to 2000×Ö½Ú
¶¨³¤×Ö·û´®£¬n×Ö½Ú³¤£¬Èç¹û²»Ö¸¶¨³¤¶È£¬È±Ê¡Îª1¸ö×Ö½Ú³¤£¨Ò»¸öºº×ÖΪ2×Ö½Ú£©
varchar2(n)
n=1 to 4000×Ö½Ú
¿É±ä³¤µÄ×Ö·û´®£¬¾ßÌ嶨ÒåʱָÃ÷×î´ó³¤¶Èn£¬
ÕâÖÖÊý¾ÝÀàÐÍ¿ÉÒÔ·ÅÊý×Ö¡¢×ÖĸÒÔ¼°ASCIIÂë×Ö·û¼¯(»òÕßEBCDICµÈÊý¾Ý¿âϵͳ½ÓÊܵÄ×Ö·û¼¯±ê×¼)ÖеÄËùÓзûºÅ¡£
Èç¹ ......
ORACLEÏÂɾ³ýµ±Ç°Óû§ÏÂËùÓжÔÏóµÄSQL
Sql´úÂë
--ɾ³ýij¸öÓû§ÏµĶÔÏó
set heading off;
set feedback off;
spool c:\dropobj.sql;
prompt --Drop constraint
select 'alter t ......
À´Ô´£¨http://www.javaeye.com/topic/190221£©
Ò»¡¢ ³£ÓÃÈÕÆÚÊý¾Ý¸ñʽ
1.Y»òYY»òYYY ÄêµÄ×îºóһ룬Á½Î»»òÈýλ
SQL> Select to_char(sysdate,'Y') from dual;
TO_CHAR(SYSDATE,'Y')
--------------------
7
SQL> Select to_char(sysdate,'YY') from dual;
TO_CHAR(SYSDATE,'YY')
---------------------
07 ......
1.´´½¨ÁÙʱ±í¿Õ¼ä
CREATE TEMPORARY TABLESPACE Test_temp
TEMPFILE 'E:\Test\TEST_temp.dbf'
SIZE 32M
AUTOEXTEND ON
NEXT 32M MAXSIZE 2048M
EXTENT MANAGEMENT LOCAL;
2.´´½¨Óû§±í¿Õ¼ä
create tablespace TEST
datafile 'E:\TEST\TEST.dbf'
size 100M
autoextend on maxsize   ......