The default query in schema browser for DB Links, in Used By tab seems to be misleading.
Wasn't sure if the query is by design for a particular reason. I looked at the custom query option but that just adds more steps and at that point I would just run the query from the editor.
the base query is
select owner, name, type, referenced_owner, referenced_name, referenced_type,
dependency_type
from sys.DBA_DEPENDENCIES
where referenced_link_name = :link
and owner <> 'SYS' <-- wasnt sure if maybe that should be own = the schema selected in the schema browser
and name <> 'DUAL'
order by 1,2,3;
thanks
dave
Hi Dave,
What is misleading about it? Did you find a case where it gives incorrect results? Note. There is also a query after that which checks dba_synonyms, and then after that a couple of pl/sql blocks which search view and mview source (assuming you have those options checked)
If you want SYS object to be included in the results, you can uncheck this option.
-John
Hey John,
Na didnt want sys objects but links with the same name return in the dependencies even in different schemas.
I feel like because links are schema specific they should be able to have the same name.
Honestly its not that big a deal but I did almost get on one of my team members for thinking an application had a dependency on a backend support schema.
Thanks
Dave
links with the same name return in the dependencies even in different schemas.
Hm, yeah good point. I'll log that as a bug to be fixed for 17.1.

1 Like