# Information Schema

> For the complete documentation index, see [llms.txt](https://docs.redpanda.com/llms.txt). Component-specific: [cloud-data-platform-full.txt](https://docs.redpanda.com/cloud-data-platform-full.txt)

---
title: Information Schema
latest-operator-version: v26.1.4
latest-console-tag: v3.7.3
latest-connect-version: 4.93.0
latest-redpanda-tag: v26.1.9
docname: sql/information-schema
page-component-name: cloud-data-platform
page-version: master
page-component-version: master
page-component-title: Cloud
page-relative-src-path: sql/information-schema.adoc
page-edit-url: https://github.com/redpanda-data/cloud-docs/edit/main/modules/reference/pages/sql/information-schema.adoc
description: Information schema views in Redpanda SQL expose database object metadata and grants through SQL-standard views.
page-topic-type: reference
page-git-created-date: "2026-05-26"
page-git-modified-date: "2026-05-26"
---

<!-- Source: https://docs.redpanda.com/cloud-data-platform/reference/sql/information-schema.md -->

The `information_schema` namespace provides SQL-standard views over database object metadata. Use these views to inspect catalogs, tables, schemas, columns, and privilege grants without querying the underlying PostgreSQL system catalogs directly.

## [](#available-views)Available views

Standard views follow the SQL specification, with semantics consistent with [PostgreSQL’s `information_schema`](https://www.postgresql.org/docs/current/information-schema.html). Redpanda SQL also adds one extension view for per-relation EXTERNAL SOURCE grants.

| View | Description |
| --- | --- |
| information_schema.character_sets | Character sets available in the current database. |
| information_schema.columns | Columns of tables and views visible to the current role. |
| information_schema.key_column_usage | Columns constrained as keys (primary keys, unique constraints, foreign keys). |
| information_schema.referential_constraints | Foreign-key constraints visible to the current role. |
| information_schema.role_external_relation_grants | Per-relation EXTERNAL SOURCE grants. Redpanda SQL extension that captures grants whose stored relation pattern is anything other than \* (catalog-level grants surface in information_schema.role_table_grants instead). |
| information_schema.role_table_grants | Privileges granted on tables and table-like objects to the current role. |
| information_schema.role_usage_grants | USAGE privileges granted to the current role. |
| information_schema.table_constraints | Table constraints (primary key, unique, foreign key, check) visible to the current role. |
| information_schema.tables | Tables and views visible to the current role. |

## [](#information_schema-role_external_relation_grants)information_schema.role_external_relation_grants

Per-relation EXTERNAL SOURCE grants. Rows whose stored relation pattern is anything other than `*`. Catalog-level EXTERNAL SOURCE grants (stored pattern `\*`) surface in `information_schema.role_table_grants`, like foreign-table grants in PostgreSQL.

When you `GRANT …​ ON EXTERNAL SOURCE catalog_name ⇒ 'pattern'`, the pattern is stored verbatim. Redpanda SQL does not normalize or canonicalize it. Patterns are either a fully-qualified relation name like `ns1.ns2.my_table` or a name with a trailing wildcard like `ns1.public_tables*`. See [GRANT](https://docs.redpanda.com/cloud-data-platform/reference/sql/sql-statements/grant/) for the full grant syntax and [Manage access to Redpanda SQL](https://docs.redpanda.com/cloud-data-platform/sql/manage/manage-access/) for the access model.

Visibility mirrors `information_schema.role_table_grants`. A regular role sees rows where it is the grantee. A superuser sees grants for every non-superuser.

Use this view to find the exact stored relation pattern when you need to [revoke](https://docs.redpanda.com/cloud-data-platform/reference/sql/sql-statements/revoke/) a grant. `REVOKE` requires the pattern argument to match a stored grant exactly. Revoking a pattern that was never granted returns an error, so query this view first to see what’s currently registered.

| Column | Type | Nullable | Description |
| --- | --- | --- | --- |
| grantor | text | No | Role that granted the privilege. |
| grantee | text | No | Role that holds the privilege. |
| database_name | text | No | Database the grant applies to. |
| schema_name | text | No | Schema the grant applies to. |
| source_name | text | No | External source (catalog or storage) the grant applies to. |
| relation_pattern | text | No | Relation-name pattern the grant matches. Wildcards (\*) are allowed in the pattern. |
| privilege_type | text | No | Privilege granted, such as SELECT. |
| is_grantable | text | No | YES if the grantee can grant this privilege to other roles; NO otherwise. |

```sql
SELECT grantee, source_name, relation_pattern, privilege_type
FROM information_schema.role_external_relation_grants
WHERE grantee = 'analyst';
```

## [](#suggested-reading)Suggested reading

-   [GRANT](https://docs.redpanda.com/cloud-data-platform/reference/sql/sql-statements/grant/)

-   [REVOKE](https://docs.redpanda.com/cloud-data-platform/reference/sql/sql-statements/revoke/)

-   [Manage access to Redpanda SQL](https://docs.redpanda.com/cloud-data-platform/sql/manage/manage-access/)