Before you can use it, you have to source the
db2profile script into your shell.
From the shell command-line, do this:
db2 list db directory
db2 connect to ALIAS(where ALIAS is whatever alias that appeared in the first command)
db2 list tables for all
To list all tables, sorted by number of records:
db2 "SELECT tabschema CONCAT '.' CONCAT tabname AS table_name, card AS rows FROM syscat.tables ORDER BY card"
If you've started it in interactive mode, you can simply type
? for help.