Home » RDBMS Server » Server Utilities » How to export using datapump excluding mutiple table in windows (oracle 10g win xp sp2)
How to export using datapump excluding mutiple table in windows [message #630976] Wed, 07 January 2015 05:19 Go to next message
jgjeetu
Messages: 363
Registered: July 2013
Location: www.Orafaq.com/Forum
Senior Member

Following code is working well, but when i try to pass multiple table names as parameter it gives me error, please tell me how to pass argument for multiple tables in following code.

working code:-
expdp scott/tiger schemas=scott exclude=table:"IN('emp')" directory=DATA_PUMP_DIR dumpfile=test1.dmp logfile=test1.log


i tried following codes for passing multiple arguments but these are giving syntax error:-

expdp scott/tiger schemas=scott exclude=table:"IN('emp','dept')" directory=DATA_PUMP_DIR dumpfile=test1.dmp logfile=test1.log


expdp scott/tiger schemas=scott exclude=table:"IN(\'emp\',\'dept\')" directory=DATA_PUMP_DIR dumpfile=test1.dmp logfile=test1.log


please provide me the solution.

[Updated on: Wed, 07 January 2015 05:25]

Report message to a moderator

Re: How to export using datapump excluding mutiple table in windows [message #630979 is a reply to message #630976] Wed, 07 January 2015 05:38 Go to previous messageGo to next message
gazzag
Messages: 1082
Registered: November 2010
Location: Bristol, UK
Senior Member
TABLES=<table_name1>,<table_name2>,<table_name3>...
Re: How to export using datapump excluding mutiple table in windows [message #630982 is a reply to message #630976] Wed, 07 January 2015 06:53 Go to previous messageGo to next message
Michel Cadot
Messages: 66437
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator

These work for me:
expdp scott/tiger schemas=scott exclude="table:\"IN(\'emp\',\'dept\')\"" directory=DATA_PUMP_DIR dumpfile=test1.dmp logfile=test1.log
expdp scott/tiger schemas=scott exclude="table:\"IN('emp','dept')\"" directory=DATA_PUMP_DIR dumpfile=test1.dmp logfile=test1.log


Re: How to export using datapump excluding mutiple table in windows [message #631018 is a reply to message #630982] Wed, 07 January 2015 23:42 Go to previous messageGo to next message
jgjeetu
Messages: 363
Registered: July 2013
Location: www.Orafaq.com/Forum
Senior Member

thanks @michel, meanwhile i got one more solution , it is quite similar to yours though i.e

expdp user/pwd schemas=user directory=DATA_PUMP_DIR dumpfile=unr080115.dmp logfile=unr080115.log EXCLUDE=TABLE:\"IN \(\'prt_data_upd_dtl_201401\' , \'prt_data_upd_dtl_201402\',\'prt_data_upd_dtl\'\)\" 
Re: How to export using datapump excluding mutiple table in windows [message #631019 is a reply to message #631018] Wed, 07 January 2015 23:45 Go to previous messageGo to next message
BlackSwan
Messages: 26538
Registered: January 2009
Location: SoCal
Senior Member
if you place all command line arguments within a simple text control file, you never have to worry about "escaping" any character at all; EVER.
Re: How to export using datapump excluding mutiple table in windows [message #631036 is a reply to message #631019] Thu, 08 January 2015 02:39 Go to previous message
gazzag
Messages: 1082
Registered: November 2010
Location: Bristol, UK
Senior Member
parameter file Smile
Previous Topic: Import user Without Data
Next Topic: SQL LOADER ORA-01722
Goto Forum:
  


Current Time: Sun Jun 16 06:24:57 CDT 2019