oracleÖÐdumpº¯Êý
ÎÊÌ⣺
1. oracleÖÐnumber£¬char/varchar£¬dateµÈÊý¾ÝÀàÐÍÊÇÔõô´æ´¢µÄ£¿×Ö½ÚÁ÷ÊÇʲôÑùµÄ£¿
2. ¸÷ÖÖÊý¾ÝÀàÐÍÕ¼ÓõÄ×Ö½Ú³¤¶ÈÊǶà´ó£¿
SELECT dump(1), DUMP(123456), DUMP(-123456), DUMP(1234567890123456) -- ÕûÊý
--SELECT DUMP(123456.789), DUMP(-123456.789), dump(1.234567890123456789E15), dump(123456789012345678901234567890123456789) -- ¸¡µãÊý
SELECT DUMP('a'), DUMP('abcdefghijklmn'), DUMP(CAST('abc' AS CHAR(20))), DUMP(CAST('abcÄã' AS VARCHAR(20)))
--SELECT sysdate, DUMP(SYSDATE)
from dual;
½áÂÛ£º
1. numberÀàÐ͵Ä×Ö½ÚÁ÷ÊDz»¶¨³¤µÄ£¬²¢ÇÒÕý¸ºÊý»áÓò»Í¬µÄ±ê־루ÕýÊý£ºÊý×Ö1 >= 193£¬¸ºÊý£ºÊý×Ö1 <= 62£¬²î¶îÇ¡ºÃÊÇÖ¸Êý´óС£©
2. charÊǶ¨³¤µÄ£¬³¤¶È²»×ã×î´ó³¤¶È»áÌî³äβ¿Õ¸ñ£¬varcharÊDz»¶¨³¤µÄ£¨¼´¸ø¶à³¤´æ¶à³¤£©
3. dateÀàÐͶ¨³¤£¬Õ¼8¸ö×Ö½Ú
-- ¸½Â¼Îª³£¼ûÊý¾ÝÀàÐ͵Ĵ洢·½Ê½ËµÃ÷£¬¿É²Î¼ûoracle¹Ù·½Îĵµ£¬»ò¸÷ÖÖ¼¼Êõblog
http://blog.oracle.com.cn/index.php/12012/action_viewspace_itemid_4684.html£¨¸½Â¼µÄÀ´Ô´£©
http://zhouwf0726.itpub.net/post/9689/196733
±ÊÕßÔÚ×öʵÑé¹ý³Ì£¨oracle9i2°æ±¾£©ÖУ¬·¢ÏÖʵ¼ÊDateÀàÐÍÓ븽¼ÖеIJ»Ò»Ñù£¬¹À¼Æ¸½Â¼ÖÐÊǶÔoracle8ÒÔÇ°°æ±¾µÄ˵Ã÷¡£
Date(³¤¶È 7 ÀàÐÍ 12)
col dump_date form a35col real_date form a35
select dump(last_ddl_time) dump_date, to_char(last_ddl_time,'yyyy-mm-dd hh24:mi:ss') real_date
from user_objects
where rownum=1;
DUMP_DATE REAL_DATE
----------------------------------- ---------------------
Typ=12 Len=7: 120,102,4,13,16,48,53 2002-04-13 15:47:52ÊÀ¼Í 120 - 100 = 20 ÊÀ¼ÍºÍÄê·Ý¼Ó100ºó´æ´¢
Äê·Ý 102 - 100 = 2
ÔÂ·Ý 4 Ô·ݺÍÈÕÆÚ°´ÔÖµ´æ´¢
ÈÕÆÚ 13
Сʱ 16 - 1 = 15 ʱ¼ä¾ù¼Ó1ºó´æ´¢
·ÖÖÓ 48 - 1 = 47
Ãë 53 - 1 = 52
--------------------------------------------------------------------------------
Number(ÀàÐÍ 2)
<[³¤¶È]>£¬·ûºÅλ/Ö¸Êý Êý×Ö1£¬Êý×Ö2£¬Êý×Ö3£¬......£¬Êý×Ö20
ÕýÊý£ºÖ¸Êý=Êý×Ö1 - 193 (×î¸ßλΪ1ÊÇ´ú±íÕýÊý)
¸ºÊý£ºÖ¸Êý=62 - µÚÒ»×Ö½Ú
Êý×Ö1ÊÇ×î¸ßÓÐЧλ
ÕýÊý£º¼Ó1´æ´¢
¸ºÊý£º±»
Ïà¹ØÎĵµ£º
²éѯ£º
select distinct(empno) , name , age from t_person t where (t.age between 21 and 25 or name like '%Íõ%') and
empno like '32%';
¸üУº
update t_person set name = 'ww' where empno = '321654';
update t_person set(empno,name,age) = (select empno,name,age f ......
Oracle Flashback ¼¼Êõ×ܽá
Flashback ¼¼ÊõÊÇÒÔUndo segmentÖеÄÄÚÈÝΪ»ù´¡µÄ£¬ Òò´ËÊÜÏÞÓÚUNDO_RETENTON²ÎÊý¡£ÒªÊ¹ÓÃflashback µÄÌØÐÔ£¬±ØÐëÆôÓÃ×Ô¶¯³·Ïú¹ÜÀí±í¿Õ¼ä¡£
ÔÚOracle 10gÖУ¬ Flash back¼Ò×å·ÖΪÒÔϳÉÔ±£º Flashback Database£¬ Flashback Drop£¬Flashback Query(·ÖFlashback Query,Flashback Version Query ......
ÒªÕÒOracle 9i for LinuxͦÂé·³µÄ£¬¸É´à×Ô¼ºÁô¸ö¼Ç¼±È½Ï·½±ã¡£
Oracle9i Database Release 2 Enterprise/Standard/Personal Edition for Windows NT/2000/XP
http://download.oracle.com/otn/nt/oracle9i/9201/92010NT_Disk1.zip
http://download.oracle.com/otn/nt/oracle9i/9201/92010NT_Disk2.zip
http://downlo ......
OracleÌṩÁ½ÖÖÑéÖ¤·½Ê½£¬Ò»ÖÖÊÇOSÑéÖ¤£¬ÁíÒ»ÖÖÃÜÂëÎļþÑéÖ¤·½Ê½£¬Èç¹ûÊǵÚÒ»ÖÖ·½Ê½ÓÃÒÔÏ·½·¨ÐÞ¸ÄÃÜÂ룺
¡¡¡¡sqlplus / as sysdba
¡¡¡¡alter user sys identified by ÐÂÃÜÂë;
¡¡¡¡alter user system identified by ÐÂÃÜÂë;
¡¡¡¡Èç¹ûÊǵڶþÖÖ·½·¨ÓÃÒÔÏ·½·¨ÐÞ¸ÄÃÜÂ룺
¡¡¡¡orapwd file=pwdxxx.ora password=ÄãÉ趨µÄÐ ......