Manage Learn to apply best practices and optimize your operations.

Viewing all databases in the catalog

This tip describes how to view all databases in the catalog.

Tired of writing your own code to find all of the databases on a server? Why not use the catalog?

Well, you say, the catalog would be great; except that you can't be guaranteed that they're all there, because databases can be hidden from the catalog.

Ah, but they're all there, just hidden from the views! Make a copy of any one of the 'Database' views and remove
'...& !(DBListInCatalog = "0")'
from the 'View Selection Formula'.

Don't forget to set security on the view to be available only to admins and LocalDomainServers. While you're at it, why not add a column that displays whether or not the database is in the catalog? Set the column property 'Display values as icon'. The formula for that is:

@If(DBListInCatalog = "0";81;82)


This was last published in March 2003

Start the conversation

Send me notifications when other members comment.

By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Please create a username to comment.

-ADS BY GOOGLE

SearchWindowsServer

Search400

  • iSeries tutorials

    Search400.com's tutorials provide in-depth information on the iSeries. Our iSeries tutorials address areas you need to know about...

  • V6R1 upgrade planning checklist

    When upgrading to V6R1, make sure your software will be supported, your programs will function and the correct PTFs have been ...

  • Connecting multiple iSeries systems through DDM

    Working with databases over multiple iSeries systems can be simple when remotely connecting logical partitions with distributed ...

SearchDataCenter

SearchExchange

SearchContentManagement

Close