Home » SQL & PL/SQL » SQL & PL/SQL » Error While Fetching Data Through Database Link In Oracle
Error While Fetching Data Through Database Link In Oracle [message #632002] Fri, 23 January 2015 03:24 Go to next message
qanita786
Messages: 229
Registered: May 2007
Location: PAKISTAN
Senior Member
connect account/a@main

create public database link local connect to account identified by a using 'main'

Database link created.

then i connect to New Database


connect account/a@new then i apply following command

select account_no from chart@local;

Error Generated

ERROR at line 1:
ORA-02019: connection description for remote database not found

kindly guide me where i am wrong
Re: Error While Fetching Data Through Database Link In Oracle [message #632005 is a reply to message #632002] Fri, 23 January 2015 03:28 Go to previous messageGo to next message
John Watson
Messages: 8919
Registered: January 2010
Location: Global Village
Senior Member
You have created the link in the wrong database.
Re: Error While Fetching Data Through Database Link In Oracle [message #632006 is a reply to message #632002] Fri, 23 January 2015 03:28 Go to previous messageGo to next message
Littlefoot
Messages: 21805
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
My guess is that 'main' doesn't exist in TNSNAMES.ORA located on a database server.
Re: Error While Fetching Data Through Database Link In Oracle [message #632007 is a reply to message #632006] Fri, 23 January 2015 03:32 Go to previous messageGo to next message
qanita786
Messages: 229
Registered: May 2007
Location: PAKISTAN
Senior Member
Sir main is available
Re: Error While Fetching Data Through Database Link In Oracle [message #632008 is a reply to message #632007] Fri, 23 January 2015 03:35 Go to previous messageGo to next message
Michel Cadot
Messages: 68618
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator

John Watson wrote on Fri, 23 January 2015 10:28
You have created the link in the wrong database.


Re: Error While Fetching Data Through Database Link In Oracle [message #632009 is a reply to message #632008] Fri, 23 January 2015 03:41 Go to previous messageGo to next message
qanita786
Messages: 229
Registered: May 2007
Location: PAKISTAN
Senior Member
Sir i have two database Names ORCL & ORCL1

main = ORCL
NEW = ORCL1

where to create database link
Re: Error While Fetching Data Through Database Link In Oracle [message #632011 is a reply to message #632009] Fri, 23 January 2015 04:00 Go to previous messageGo to next message
John Watson
Messages: 8919
Registered: January 2010
Location: Global Village
Senior Member
Sorry. I don't do spoon feeding
Re: Error While Fetching Data Through Database Link In Oracle [message #632016 is a reply to message #632006] Fri, 23 January 2015 06:29 Go to previous messageGo to next message
EdStevens
Messages: 1376
Registered: September 2013
Senior Member
Littlefoot wrote on Fri, 23 January 2015 03:28
My guess is that 'main' doesn't exist in TNSNAMES.ORA located on a database server.


That would have resulted in a different error.
Re: Error While Fetching Data Through Database Link In Oracle [message #632017 is a reply to message #632002] Fri, 23 January 2015 06:32 Go to previous message
EdStevens
Messages: 1376
Registered: September 2013
Senior Member
you created the db link in database 'main'.

So why do you think database 'new' should have any knowledge of it? Why are you connecteing to database 'new' and trying to reference an object (a database link) that you defined in some other database?

Previous Topic: Special character issues
Next Topic: How to find first prior number from current date
Goto Forum:
  


Current Time: Tue Mar 19 05:24:58 CDT 2024