pg_ident_file_mappings — PostgreSQL system view

The PostgreSQL pg_ident_file_mappings system view: full column reference (names, types, descriptions), catalog relationships and version support.

Summary

The view pg_ident_file_mappings provides a summary of the contents of the client user name mapping configuration file, pg_ident.conf. A row appears in this view for each non-empty, non-comment line in the file, with annotations indicating whether the map could be applied successfully.

(Description quoted from the official PostgreSQL documentation.)

Columns

The pg_ident_file_mappings system view exposes the following columns (names, types and descriptions are taken verbatim from the PostgreSQL documentation):

  • map_number int4
    Number of this map, in priority order, if valid, otherwise NULL
  • file_name text
    Name of the file containing this map
  • line_number int4
    Line number of this map in file_name
  • map_name text
    Name of the map
  • sys_name text
    Detected user name of the client
  • pg_username text
    Requested PostgreSQL user name
  • error text
    If not NULL, an error message indicating why this line could not be processed

Version applicability

Present in PostgreSQL 17, 18, 19 (verified against each release’s documentation). This is a long-standing system object that also exists in earlier PostgreSQL releases.

Related & references

Reference: PostgreSQL documentation — pg_ident_file_mappings.