> For the complete documentation index, see [llms.txt](https://docs.postgresql.tw/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.postgresql.tw/internals/catalogs/catalog-pg-foreign-data-wrapper.md).

# 52.23. pg\_foreign\_data\_wrapper \#

The catalog `pg_foreign_data_wrapper` stores foreign-data wrapper definitions. A foreign-data wrapper is the mechanism by which external data, residing on foreign servers, is accessed.

**Table 52.23. `pg_foreign_data_wrapper` Columns**

| <p>Column Type</p><p>Description</p>                                                                                                                                                                                                                                                                                                                                                                            |
| --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| <p><code>oid</code> <code>oid</code></p><p>Row identifier</p>                                                                                                                                                                                                                                                                                                                                                   |
| <p><code>fdwname</code> <code>name</code></p><p>Name of the foreign-data wrapper</p>                                                                                                                                                                                                                                                                                                                            |
| <p><code>fdwowner</code> <code>oid</code> (references <a href="/pages/nyEMOe5gQKgypFQTDbjS"><code>pg\_authid</code></a>.<code>oid</code>)</p><p>Owner of the foreign-data wrapper</p>                                                                                                                                                                                                                           |
| <p><code>fdwhandler</code> <code>oid</code> (references <a href="/pages/8TiLY9QeJalZY0OBAANF"><code>pg\_proc</code></a>.<code>oid</code>)</p><p>References a handler function that is responsible for supplying execution routines for the foreign-data wrapper. Zero if no handler is provided</p>                                                                                                             |
| <p><code>fdwvalidator</code> <code>oid</code> (references <a href="/pages/8TiLY9QeJalZY0OBAANF"><code>pg\_proc</code></a>.<code>oid</code>)</p><p>References a validator function that is responsible for checking the validity of the options given to the foreign-data wrapper, as well as options for foreign servers and user mappings using the foreign-data wrapper. Zero if no validator is provided</p> |
| <p><code>fdwacl</code> <code>aclitem\[]</code></p><p>Access privileges; see <a href="/pages/VX212noXJkZ6WiwCHQE7">Section 5.8</a> for details</p>                                                                                                                                                                                                                                                               |
| <p><code>fdwoptions</code> <code>text\[]</code></p><p>Foreign-data wrapper specific options, as “keyword=value” strings</p>                                                                                                                                                                                                                                                                                     |

<br>

***

原文：[PostgreSQL 18.6 Documentation](https://www.postgresql.org/docs/18/catalog-pg-foreign-data-wrapper.html)（英文原文，待翻譯）


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.postgresql.tw/internals/catalogs/catalog-pg-foreign-data-wrapper.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
