Switch Oracle user su-oracle----------------------------Restart the database sqlplus sys/as sysdbashutdown immediatestartup;-------------- --------------Export a single table exp pls/[email protected] file=/home/oracle/boz.dmp Tables=edu_version_set_area; Import a single table Imp pls/[ Email protected] file=rms_resourcebody.dmp tables=edu_version_set_area;exp tms/[email protected] file=/home/oracle/ Boz.dmp Tables=edu_version_set_area; Export entire library su-oraclesqlplus/as sysdbacreate or replace directory Dumpdir as '/home/oracle/pls '; exit CD/HOME/ORACLE/PLSEXPDP Pls/yjt_pls dumpfile=zzpls2013.dmp directory=dumpdir logfile=zzpls2013.log schemas=pls Import the entire library before importing the user Su- Oraclesqlplus System/sys_98921drop User PLS Cascade;commit;exit if promptedUnable to delete the currently connected userSelect username,sid,serial# from v$session where username like ' pls '; alter system kill session ' sid,serial# '; Import Entire library CD/HOME/ORACLE/PLSIMPDP system/sys_8968888 dumpfile=zzpls20130911.dmp directory=dumpdir LOGFILE= Zzpls20130911.log schemas=pls constraint table DBA_CONSTRAINTSC (check constraint on a table) P (primary key) U (unique key) R (refere Ntial integrity) V (with CHECK option, in a view) O (with Read only, on a view) Oracle view constraints for a table select * from Dba_constrain TS where owner= ' PLS ' and table_name= ' share_knowledg_structure ';
Oracle basic usage and common commands