Home » RDBMS Server » Server Utilities » import/ export
import/ export [message #529333] Mon, 31 October 2011 03:50 Go to next message
monster88
Messages: 8
Registered: October 2011
Junior Member
hi,

i exported (exp utility) 2 schema (LG, LGAPP)

LGAPP contain just synonyms as they are base on tables from LG tables/ views.

There are update (DML) on LG tables. That's why backup are required.

If anything goes wrong, how can i import the synonyms in LGAPP?

Do i need to drop all synonyms before i import?
Re: import/ export [message #529335 is a reply to message #529333] Mon, 31 October 2011 03:53 Go to previous messageGo to next message
Michel Cadot
Messages: 66851
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
Quote:
If anything goes wrong, how can i import the synonyms in LGAPP?

Import the whole schema.

Quote:
Do i need to drop all synonyms before i import?

No, you can use the IGNORE=Y option.

Regards
Michel
Re: import/ export [message #529337 is a reply to message #529335] Mon, 31 October 2011 03:57 Go to previous messageGo to next message
monster88
Messages: 8
Registered: October 2011
Junior Member
Quote:


Import the whole schema.



erm, do i need to first drop the schema then?

if yes, then:


imp xxxx@xxxx file=c:\exportLGAPP\exportLGAPP.dmp log=c:\exportLGAPP\exportLGAPP_import.log fromuser=LGAPP touser=LGAPP 



no ignore=y is use in the imp code.

[Updated on: Mon, 31 October 2011 04:00]

Report message to a moderator

Re: import/ export [message #529339 is a reply to message #529337] Mon, 31 October 2011 04:00 Go to previous messageGo to next message
Littlefoot
Messages: 21530
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
No.
Re: import/ export [message #529340 is a reply to message #529337] Mon, 31 October 2011 04:04 Go to previous messageGo to next message
monster88
Messages: 8
Registered: October 2011
Junior Member
can i say that if using the ignore=y, while importing, oracle is re- compiling the dependency object associated with it?
Re: import/ export [message #529341 is a reply to message #529339] Mon, 31 October 2011 04:05 Go to previous messageGo to next message
monster88
Messages: 8
Registered: October 2011
Junior Member
Quote:

No.




sorry, you no is no to what?
Re: import/ export [message #529344 is a reply to message #529341] Mon, 31 October 2011 04:11 Go to previous messageGo to next message
Littlefoot
Messages: 21530
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
"No" as "no, you don't have to drop that user (schema)" (it seems that we were writing a message at the same time).
Re: import/ export [message #529346 is a reply to message #529340] Mon, 31 October 2011 04:28 Go to previous messageGo to next message
monster88
Messages: 8
Registered: October 2011
Junior Member
Quote:
can i say that if using the ignore=y, while importing, oracle is re- compiling the dependency object associated with LGAPP synonyms?


Re: import/ export [message #529354 is a reply to message #529346] Mon, 31 October 2011 05:19 Go to previous messageGo to next message
Littlefoot
Messages: 21530
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
I don't think so. "IGNORE=Y" means that import will ignore import errors (if any) and continue importing data/objects. For example, if a table already exists and you try to import data into it, if you don't use IGNORE=Y, import would fail while executing the CREATE TABLE statement. If you, however, use it, import would know that it shouldn't care if the table already exists, and continue importing data into an already existing table.

Therefore, as far as I can tell, this parameter won't recompile anything.

On the other hand, there's the COMPILE parameter which is (by default) set to "Y" (so you don't have to specify it explicitly), and it orders import to compile procedures, functions and packages as they are created.
Re: import/ export [message #529360 is a reply to message #529354] Mon, 31 October 2011 05:31 Go to previous messageGo to next message
monster88
Messages: 8
Registered: October 2011
Junior Member
Quote:

COMPILE parameter which is (by default) set to "Y"


ic ic.

guess

imp xxxx@xxxx file=c:\exportLGAPP\exportLGAPP.dmp log=c:\exportLGAPP\exportLGAPP_import.log fromuser=LGAPP touser=LGAPP ignore=y



is sufficient? is actually from the same database. So not so sure the fromuser + touser is necessary or just fromuser is sufficient.

I am doing it as a dba role by the way.

I was thinking the fromuser + touser is more for one db to another db.

[Updated on: Mon, 31 October 2011 05:41]

Report message to a moderator

Re: import/ export [message #529364 is a reply to message #529360] Mon, 31 October 2011 06:39 Go to previous messageGo to next message
Michel Cadot
Messages: 66851
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
It is OK.

Regards
Michel
Re: import/ export [message #529365 is a reply to message #529360] Mon, 31 October 2011 06:41 Go to previous messageGo to next message
monster88
Messages: 8
Registered: October 2011
Junior Member
. exporting cluster definitions 
EXP-00056: ORACLE error 932 encountered 
ORA-00932: inconsistent datatypes: expected BLOB, CLOB got CHAR 
EXP-00056: ORACLE error 932 encountered 
ORA-00932: inconsistent datatypes: expected BLOB, CLOB got CHAR 
EXP-00000: Export terminated unsuccessfully 
EXP-00000: Export terminated unsuccessfully 



anyway time to move away from the old export/import utility.....

i uses the expdp no problem.
Re: import/ export [message #529373 is a reply to message #529365] Mon, 31 October 2011 07:07 Go to previous messageGo to next message
Michel Cadot
Messages: 66851
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
Without knowing what you did it is hard to tell what you did wrong.

By the way, all your posts are about import and the message said: "Export terminated unsuccessfully".

Regards
Michel
Re: import/ export [message #529438 is a reply to message #529373] Mon, 31 October 2011 22:32 Go to previous message
monster88
Messages: 8
Registered: October 2011
Junior Member
Quote:

By the way, all your posts are about import and the message said: "Export terminated unsuccessfully".




sorry, i was worry on the importing part...until i bum into the export error, then did a google search and realise that expdp/impdp is recommded to solve error.

the exp/imdp, lead me to more question though...lol . But so far i got the job done. will read more about it.

Previous Topic: exporting consumes lot, even after removing lots of tables
Next Topic: using NULLIF statement for two conditions.
Goto Forum:
  


Current Time: Wed Feb 19 13:29:15 CST 2020