No question at this time
DBA Top 10
1 A. Kavsek 8600
2 M. Cadot 7200
3 B. Vroman 5900
4 T. Boles 4550
5 J. Schnackenberg 3900
6 P. Wisse 3400
7 G. Lambregts 1100
7 . Lauri 1100
7 T. P 1100
10 R. Pattyn 800
About
DBA-Village
The DBA-Village forum
Forum as RSS
as RSS feed
Site Statistics
Ever registered users48374
Total active users1539
Act. users last 24h4
Act. users last hour0
Registered user hits last week171
Registered user hits last month999
Go up

DB-Links, DB_DOMAIN and packages
Next thread: Materialized View unavailable during refresh
Prev thread: Is OJVM patch is mandatory in 12c rac ?? if yes, its need to apply on RAC and oracle home both??

Message Score Author Date
Hi all, I have a peculiar problem here. Situ...... Jan Schnackenberg Jul 13, 2018, 13:20
First question, can you recompile the packages? ...... Michel Cadot Jul 13, 2018, 13:29
Hi Michel, unfortunately not. During import ...... Jan Schnackenberg Jul 13, 2018, 13:39
Jan, I would query the global name in both the ...... Score: 600 PtsScore: 600 PtsScore: 600 PtsScore: 600 PtsScore: 600 Pts Guy Lambregts Jul 13, 2018, 14:28
Thanks Guy! That was the answer! I actually had...... Jan Schnackenberg Jul 13, 2018, 15:07

Follow up by mail Click here


Subject: DB-Links, DB_DOMAIN and packages
Author: Jan Schnackenberg, Germany
Date: Jul 13, 2018, 13:20, 314 days ago
Os info: Linux
Oracle info: 12.1.0.2
Message: Hi all,

I have a peculiar problem here.

Situation: Export/Import migration

Source-DB:
* Has default domain "WORLD"
* Has several database links, all of them called SOMETHING.WORLD for varying SOMETHINGs
* Has lots of packages that access objects by calling these database links WITHOUT specifying the domain
* Everything works.


The new database was created from a DBCA-template generated from the old database. All parameters of the two databases are identical, except for some paths, filenames (controlfiles), the DB_NAME and some size-parameters for memory-structures (SGA, PGA, etc.).


After doing a FULL datapump export and a FULL datapump import, all the packages using DB-links without domainname are invalid.


I have so many questions, but the main two are:
* How could this ever work (in the old database).
* How can I get this to work again (in the new database) without modifying the packages.


Does anyone have any idea?

Regards,
Jan
Goto: Reply - Top of page 
If you think this item violates copyrights, please click here

Subject: Re: DB-Links, DB_DOMAIN and packages
Author: Michel Cadot, France
Date: Jul 13, 2018, 13:29, 314 days ago
Message:
First question, can you recompile the packages?

Regards
Michel
Your rating?: This reply is Good Excellent
Goto: Reply - Top of page 
If you think this item violates copyrights, please click here

Subject: Re: DB-Links, DB_DOMAIN and packages
Author: Jan Schnackenberg, Germany
Date: Jul 13, 2018, 13:39, 314 days ago
Message: Hi Michel,

unfortunately not.

During import it tells me, that it cannot identify the DB-Link. In DBA_ERRORS it just tells me it ignores the statement because it cannot find a table or view (ORA-00942).

If I take one of the SQL statements and execute it manually (without the ".WORLD") it will tell me ORA-02019: Connection Description for Remote Database Not Found. If I append the ".WORLD" to the DB link name, the statement works.

Regards,
Jan
Your rating?: This reply is Good Excellent
Goto: Reply - Top of page 
If you think this item violates copyrights, please click here

Subject: Re: DB-Links, DB_DOMAIN and packages
Author: Guy Lambregts, Belgium
Date: Jul 13, 2018, 14:28, 314 days ago
Score:   Score: 600 PtsScore: 600 PtsScore: 600 PtsScore: 600 PtsScore: 600 Pts
Message: Jan,

I would query the global name in both the source and target database


select * from global_name;


I think that in the original DB you have the .world suffix and in the newly created db not

I think ( not 100% sure though ) that if you run


alter database rename global_name to &global_name.world;


prior to the import of the database links, the links will be created with the .world suffix

Just an idea


Regards
Guy
Your rating?: This reply is Good Excellent
Goto: Reply - Top of page 
If you think this item violates copyrights, please click here

Subject: Re: DB-Links, DB_DOMAIN and packages
Author: Jan Schnackenberg, Germany
Date: Jul 13, 2018, 15:07, 314 days ago
Message: Thanks Guy!

That was the answer! I actually had the same idea just about exactly at the same time of your post. Telepathy?

And yes, your fix would have been perfectly valid.

I could recompile everything afterwards and only had "expected" errors (actually broken packages).

Regards,
Jan
Your rating?: This reply is Good Excellent
Goto: Reply - Top of page 
If you think this item violates copyrights, please click here