Home » SQL & PL/SQL » SQL & PL/SQL » problem in metadata.get_ddl
problem in metadata.get_ddl [message #294949] Mon, 21 January 2008 00:23 Go to next message
tanmoy1048
Messages: 133
Registered: June 2007
Senior Member
hi,
I am using oracle 10.2.0.2 in solris machine.
in two database.... A and B.
in A,
SELECT dbms_metadata.get_ddl('TABLE','TEST_ERROR3','PROD') from DUAL;
in B,
I have a dblink named test_A and I got the error while executing,
SELECT dbms_metadata.get_ddl('TABLE','TEST_ERROR3','PROD') from DUAL@testA;
and the error is,

ORA-31603: object "TEST_ERROR3" of type TABLE not found in schema "PROD"
ORA-06512: at "SYS.DBMS_METADATA", line 1546
ORA-06512: at "SYS.DBMS_METADATA", line 1583
ORA-06512: at "SYS.DBMS_METADATA", line 1901
ORA-06512: at "SYS.DBMS_METADATA", line 2792
ORA-06512: at "SYS.DBMS_METADATA", line 4333
ORA-06512: at line 1

and 1 more thing... I am not trying it from PROD . I did it from another user having DBA role.
Re: problem in metadata.get_ddl [message #294958 is a reply to message #294949] Mon, 21 January 2008 00:48 Go to previous messageGo to next message
Arju
Messages: 1554
Registered: June 2007
Location: Dhaka,Bangladesh. Mobile:...
Senior Member

I tested it. It works fine. No problem , You are wrong in somewhere.
Re: problem in metadata.get_ddl [message #294960 is a reply to message #294949] Mon, 21 January 2008 00:50 Go to previous messageGo to next message
Michel Cadot
Messages: 64153
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
Grant it select privilege on table and retry.

What is the definition of the db link?

Regards
Michel

[Updated on: Mon, 21 January 2008 00:51]

Report message to a moderator

Re: problem in metadata.get_ddl [message #294974 is a reply to message #294949] Mon, 21 January 2008 01:15 Go to previous messageGo to next message
tanmoy1048
Messages: 133
Registered: June 2007
Senior Member
the user is a DBA. and I am using the db link of streams. Actually its working without the object 'TEST_ERROR3'.
Re: problem in metadata.get_ddl [message #294975 is a reply to message #294974] Mon, 21 January 2008 01:16 Go to previous messageGo to next message
Michel Cadot
Messages: 64153
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
Quote:
Actually its working without the object 'TEST_ERROR3'.

Question

Regards
Michel
Re: problem in metadata.get_ddl [message #294981 is a reply to message #294949] Mon, 21 January 2008 01:28 Go to previous messageGo to next message
rajavu1
Messages: 1574
Registered: May 2005
Location: Bangalore , India
Senior Member

And are you very much sure that there is Table 'TEST_ERROR3' in thge schema specified under DBlink 'TESTA'

 select * from TEST_ERROR3@TESTA 


is working for you ?

Thumbs Up
Rajuvan.
Re: problem in metadata.get_ddl [message #295018 is a reply to message #294981] Mon, 21 January 2008 02:52 Go to previous message
tanmoy1048
Messages: 133
Registered: June 2007
Senior Member
yap...it works. but the solution???

[Updated on: Mon, 21 January 2008 02:53]

Report message to a moderator

Previous Topic: sequence
Next Topic: to write sql query
Goto Forum:
  


Current Time: Sun Dec 11 06:18:34 CST 2016

Total time taken to generate the page: 0.08068 seconds