Oracleѧϰ±Ê¼Çժ¼10
<1>Âß¼±¸·Ý
²»ÓÃÈ¥¿½±´Êý¾Ý¿âµÄÎïÀíÎļþ
±¸·ÝÂß¼ÉϵĽṹ
ÍⲿµÄ¹¤¾ß:µ¼³öºÍµ¼ÈëµÄ¹¤¾ß
DOSϵÄÃüÁî cmdÏÂÖ´ÐÐ
µ¼³öexp exportËõдÐÎʽ
²é¿´°ïÖú exp help=y
ʹÓòÎÊýÎļþµ¼³ö
exp parfile=c:\abc.par
>>>abc.parµÄÄÚÈÝ
a)scottÓû§Á¬½Óµ¼³ö×Ô¼ºµÄËùÓжÔÏó
userid=scott/tiger --Á¬½ÓµÄÓû§scott
file=c:\a1.dmp --µ¼³öµÄÎļþµÄÃû×Öa1.dmp
--µ¼³öÁËscottÓû§µÄËùÓжÔÏó
b)ÓÃsystemÁ¬½ÓÀ´µ¼³öscottϵÄËùÓжÔÏó
exp parfile=c:\sys.par
>>>>sys.parµÄÄÚÈÝ
userid=system/manager
file=c:\b1.dmp
owner=(scott) --µ¼³öscottÓû§µÄËùÓжÔÏó
µ¼³ö¶à¸öÓû§µÄÊý¾Ý
½¨Á¢Ò»¸ö²âÊÔÓû§ test
grant connect,resource
to test identified by t123;
alter user test
default tablespace users
temporary tablespace temp;
create table student(
stu_id number(4) primary key,
stu_name varchar2(20),
stu_score number(2)
);
insert into student values (1000,
'Mike',95);
insert into student values (1001,
'John',90);
µ¼³öscottºÍtestϵÄËùÓжÔÏó????
>>>userid=system/manager
file=c:\st.dmp
owner=(scott,test)
µ¼³öscottϵÄemp,dept±í????
>>>userid=system/manager
Ïà¹ØÎĵµ£º
ÓкܶàÓ¦ÓÃÏîÄ¿, ¸ÕÆð²½µÄʱºòÓÃMYSQLÊý¾Ý¿â»ù±¾ÉÏÄÜʵÏÖ¸÷ÖÖ¹¦ÄÜÐèÇó£¬Ëæ×ÅÓ¦ÓÃÓû§µÄÔö¶à£¬Êý¾ÝÁ¿µÄÔö¼Ó£¬MYSQL½¥½¥µØ³öÏÖ²»¿°ÖظºµÄÇé¿ö£ºÁ¬½ÓºÜÂýÉõÖÁå´»ú£¬ÓÚÊǾÍÓаÑÊý¾Ý´ÓMYSQLǨµ½ORACLEµÄÐèÇó£¬Ó¦ÓóÌÐòÒ²ÒªÏàÓ¦×öһЩÐ޸ġ£±¾ÈË×ܽá³öÒÔϼ¸µã×¢ÒâÊÂÏϣÍû¶Ô´ó¼ÒÓÐËù°ïÖú¡£
1£® ×Ô¶¯Ôö³¤µÄÊý¾ ......
OracleÊý¾Ý¿âÓÐÈýÖÖ±ê×¼µÄ±¸·Ý·½·¨£¬ËüÃÇ·Ö±ðÊǵ¼³ö£¯µ¼È루EXP/IMP£©¡¢Èȱ¸·ÝºÍÀ䱸·Ý¡£µ¼³ö±¸¼þÊÇÒ»ÖÖÂß¼±¸·Ý£¬À䱸·ÝºÍÈȱ¸·ÝÊÇÎïÀí±¸·Ý¡£
Ò»¡¢ µ¼³ö£¯µ¼È루Export£¯Import£©
ÀûÓÃExport¿É½«Êý¾Ý´ÓÊý¾Ý¿âÖÐÌáÈ¡³öÀ´£¬ÀûÓÃImportÔò¿É½«ÌáÈ¡³öÀ´µÄÊý¾ÝËͻص½OracleÊý¾Ý¿âÖÐÈ¥¡£
£±¡¢ ¼òµ¥µ¼³öÊý¾Ý£¨Export£©ºÍµ¼ ......
1¡¢¶à¹¤Áª»úÖØ×÷ÈÕÖ¾Îļþ
¡¡¡¡Ã¿¸öÊý¾Ý¿âʵÀý¶¼ÓÐÆä×Ô¼ºµÄÁª»úÖØ×÷ÈÕÖ¾×飬ÔÚ²Ù×÷Êý¾Ý¿âʱ£¬OracleÊ×ÏȽ«Êý¾Ý¿âµÄÈ«²¿¸Ä±ä±£´æÔÚÖØ×÷ÈÕÖ¾»º³åÇøÖУ¬ËæºóÈÕÖ¾¼Ç¼Æ÷½ø³Ì£¨LGWR£©½«Êý¾Ý´Óϵͳ¹²ÓÃÇøSGA£¨System Global Area£©µÄÖØ×÷ÈÕÖ¾»º³åÇøдÈëÁª»úÖØ×÷ÈÕÖ¾Îļþ£¬ÔÚ´ÅÅ̱ÀÀ£»òʵÀýʧ°Üʱ£¬¿ÉÒÔͨ¹ýÓëÖ®Ïà¹ØµÄÁª»úÖØ×÷ÈÕÖ¾ ......
C:\Documents and Settings\Administrator>sqlplus/nolog
SQL> CONNECT/AS SYSDBA
SQL> SHUTDOWN NORMAL/IMMEDIATE
SQL> STARTUP MOUNT
SQL> ARCHIVE LOG LIST
SQL> ALTER DATA ......
ÓÃ;: <1>Ä£¿é»¯
<Àý×Ó> --¹«Ë¾µÄÔ±¹¤µÄ¹ÜÀí
1.Ôö¼ÓÒ»¸öÔ±¹¤
2.Ô±¹¤ÀëÖ°
Óô洢¹ý³ÌºÍº¯ÊýÀ´ÊµÏÖ
1.Ôö¼ÓÒ»¸öÔ±¹¤
create sequence seq1 start with 7935;
create or replace function insert ......