|
8 | 8 | *
|
9 | 9 | * Copyright (c) 2000-2009, PostgreSQL Global Development Group
|
10 | 10 | *
|
11 |
| - * $PostgreSQL: pgsql/src/bin/psql/describe.c,v 1.205 2009/04/02 17:38:26 momjian Exp $ |
| 11 | + * $PostgreSQL: pgsql/src/bin/psql/describe.c,v 1.206 2009/04/04 00:41:11 tgl Exp $ |
12 | 12 | */
|
13 | 13 | #include"postgres_fe.h"
|
14 | 14 |
|
@@ -2029,8 +2029,15 @@ listTables(const char *tabtypes, const char *pattern, bool verbose, bool showSys
|
2029 | 2029 |
|
2030 | 2030 | if (!showSystem&& !pattern)
|
2031 | 2031 | appendPQExpBuffer(&buf," AND n.nspname <> 'pg_catalog'\n"
|
2032 |
| -" AND n.nspname <> 'information_schema'\n" |
2033 |
| -" AND n.nspname !~ '^pg_toast'\n"); |
| 2032 | +" AND n.nspname <> 'information_schema'\n"); |
| 2033 | + |
| 2034 | +/* |
| 2035 | + * TOAST objects are suppressed unconditionally. Since we don't provide |
| 2036 | + * any way to select relkind 't' above, we would never show toast tables |
| 2037 | + * in any case; it seems a bit confusing to allow their indexes to be |
| 2038 | + * shown. Use plain \d if you really need to look at a TOAST table/index. |
| 2039 | + */ |
| 2040 | +appendPQExpBuffer(&buf," AND n.nspname !~ '^pg_toast'\n"); |
2034 | 2041 |
|
2035 | 2042 | processSQLNamePattern(pset.db,&buf,pattern, true, false,
|
2036 | 2043 | "n.nspname","c.relname",NULL,
|
|