select open change scope Open full search

PG.CENTER connects PostgreSQL documentation, reference, and ecosystem knowledge. Maintained by Pigsty.

SQLSTATE / CLASS HV · FOREIGN DATA WRAPPER ERROR (SQL/MED)

fdw_no_schemas

SQLSTATE
HV00P
Condition name
fdw_no_schemas
Class
Foreign Data Wrapper Error (SQL/MED)
Source macro
ERRCODE_FDW_NO_SCHEMAS
Evidence
Source path confirmed
Analysis & operational context

English SQLSTATE atlas: authored explanations and source/runtime evidence are separate from the manual definitions. View source ↗

<h1>HV00P — fdw_no_schemas</h1>

At a glance

HV00P is raised by the core IMPORT FOREIGN SCHEMA command when the selected FDW has no ImportForeignSchema callback. It means the wrapper does not support that import mechanism, not that a remote schema is empty.

Meaning and message

foreigncmds.c:1527-1530 reports ERROR: foreign-data wrapper "%s" does not support IMPORT FOREIGN SCHEMA when fdw_routine->ImportForeignSchema is NULL. The wrapper name is dynamic; no remote schema query has necessarily run.

Diagnosis

Confirm the FDW named by the SERVER clause and inspect its handler's ImportForeignSchema callback. Distinguish this unsupported capability from HV00Q, where postgres_fdw supports import but cannot find the requested remote schema.

Response

Use explicit CREATE FOREIGN TABLE definitions, choose a wrapper that implements schema import, or add the supported wrapper callback. Reissuing the same IMPORT FOREIGN SCHEMA command against the same handler will produce the same capability error.

Messages and diagnostics

The confirmed severity is ERROR, with no detail or hint in this call group. Preserve fdwname, server identity, and the handler extension version.

Versions

The HV00P condition definition is present in the locked 9.1.0 snapshot and later, but that does not date IMPORT FOREIGN SCHEMA to 9.1. The command and its ImportForeignSchema callback are present in the fixed PostgreSQL 9.5.0 source snapshot; the current 18.6 branch is the source-backed message path described above. No pre-9 definition observation is available.

Sources

  • errcodes.txt — definition, SHA-256 6e8de346643ba84aa3c9c6a73360acfc7b2dfb89162c06c08ce9bf5bcd5bbcba.
  • foreigncmds.c — callback check and message.
  • fdwapi.hImportForeignSchema callback definition; SHA-256 572ba892e6435ca92d3b3bc84dde5bbd3160cc3a082693daab8daa835c4d2cd7.
  • foreigncmds.c in the REL9_5_0 snapshot — command and callback feature boundary; SHA-256 d2ab3a8883ed1e27c38a0a7ff83f0fc9d493c488d7e30f56eef7d1ae449f9a16.
  • Structured evidence — source path and bounded runtime scope.

Source evidence

Evidence belongs to the frozen source and runtime versions listed here. It is not a runtime verification of the selected manual version.

HV00P is fdw_no_schemas in SQL/MED Class HV.

Method: Read the fixed definition row and macro.

src.errcodes.18.6

The core IMPORT FOREIGN SCHEMA command emits HV00P when the selected FDW handler has no ImportForeignSchema callback.

Method: Read the callback-null branch and handler definition.

src.foreigncmds.18.6 src.fdwapi.18.6

The IMPORT FOREIGN SCHEMA command and its ImportForeignSchema handler callback are present in the fixed PostgreSQL 9.5.0 source snapshot; the 9.1.0 directory observation for HV00P is a condition-definition boundary, not evidence that this command existed in 9.1.

Method: Read the fixed REL9_5_0 foreigncmds.c command path and callback invocation.

Limits: This establishes presence in the REL9_5_0 source snapshot; it does not claim the exact development commit or behavior of every wrapper before or after that snapshot.

src.foreigncmds.9.5.0

Message templates

ERROR · src/backend/commands/foreigncmds.c:1527-1530

Primary

foreign-data wrapper "%s" does not support IMPORT FOREIGN SCHEMA

Reproduction & repair cases

No reproduction case is attached to this condition.

Recorded runtime evidence

No runtime observation is attached to this entry.

Version history 1
  1. PG 9.0 → 9.1added

Definition snapshot: english-manuals:bfaa243ec1a875d084421648dee… · English manual source