Get Table Information

It is advantageous for the DBA to be able to make ad hoc inquiries about database elements such as tables, columns, indexes, and rows. Users always seem to be asking about table structure, existing indexes, and the like. It is very handy to have a command-line program that will allow these types of questions to be answered from the UNIX command line.

The section above on running isql from the command line contains a C-Shell alias called info that pipes information to isql. The same could be done with a standard shell script if you are not a csh user. The csh alias is:

alias info   "echo 'info \!:*;'   | $INFORMIXDIR/bin/isql your_database"

This alias is invoked in several ways, depending upon the information that the DBA wants ...

Get Informix DBA Survival Guide, Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.