I know, after all that stuff about how great Ubuntu is. Look, I just haven’t got round to installing Oracle yet. All these annoying little things like going to work keep getting in the way. Look It’s on the list OK ?

Anyway, back to SQLDeveloper.

Take table information as an example. By default SQLDeveloper will show constraint information for a table, but it won’t display the relationship between columns in the child and parent tables of a Foreign Key relationship.

Standard SQLDeveloper Table view

Getting this information from the data dictionary can be done with the following query :-

Simple enough, but it would be nice to see this for every table without having to type in and run this query every time.
To add this query as a permanent tab in SQLDeveloper, all you need to do is create an XML file containing the text of the query.

2 thoughts on “Adding your own tabs in SQLDeveloper”

Nice example but there is a small problem in the SQL.
I have included a new line
AND fkcols.position = pkcols.position
so that it will match up the lines when there multiple parts to the FK.
New SQL is below.

you get the prize for spotting the deliberate mistake ( he said, desperately trying to retain an air of infallibility).
Incidentally, looking at this again, I’ve also noticed that I’ve got cons.owner=fkcons.owner in the predicate twice. Doh !
I tested your code suggestion and it works fine, so I’ll make the appropriate changes to this post.