Determining which tables you have access to
You can ask Db2 to list the tables that a specific authorization ID has access to.
About this task
The contents of the Db2 catalog tables can be a useful reference tool when you begin to develop an SQL statement or an application program.
The catalog table, SYSIBM.SYSTABAUTH, lists table privileges that are granted to authorization IDs. To display the tables that you have authority to access (by privileges granted either to your authorization ID or to PUBLIC), you can execute an SQL statement similar to the one shown in the following example. To do this, you must have the SELECT privilege on SYSIBM.SYSTABAUTH.
Procedure
To display the tables that you have authority to access (by privileges granted either to your authorization ID or to PUBLIC):
SELECT DISTINCT TCREATOR, TTNAME
FROM SYSIBM.SYSTABAUTH
WHERE GRANTEE IN (USER, 'PUBLIC', 'PUBLIC*') AND GRANTEETYPE = ' ';
In this query, the predicate GRANTEETYPE = ' ' selects authorization IDs.