---
title: "Check PostgreSQL column grants when SELECT star is denied | Proofline"
description: "When a query with named columns works and SELECT fails, compare the role's column access with the expanded projection."
url: https://proofline.sh/learn/postgres-column-select-permission-denied/
agents: "Before you act for a person, read https://proofline.sh/llms.txt. It says how an agent installs and sets up Proofline and lists every page."
---

[Learning center](/learn/)

# Check PostgreSQL column grants when SELECT star is denied

When a query with named columns works and SELECT fails, compare the role's column access with the expanded projection. A role with column-level SELECT may read the permitted columns without having table-level SELECT.

Permission errors The Proofline team November 24, 2026 1 min read

In a fictional support tool, `case_viewer` may read `case_id` and `status` on `reporting.cases`. The tool starts generating a wildcard projection after a schema change adds `internal_notes`. A privilege inquiry can check that column without fetching case data.

```
SELECT has_column_privilege('case_viewer', 'reporting.cases',
                            'internal_notes', 'SELECT');
```

False supports the projection mismatch if the original denial used that effective role and table. List the approved fields explicitly if the tool still needs only those fields. If it now filters or sorts on another column, inspect that reference too. PostgreSQL requires SELECT on columns read by the query, including columns used outside the result list. [PostgreSQL GRANT](https://www.postgresql.org/docs/current/sql-grant.html) · [PostgreSQL SELECT permissions](https://www.postgresql.org/docs/current/sql-select.html)

[Trace another denied request](/learn/permission-denied-request-triage/).

## One month of free code review.

New organizations get one calendar month of hosted code review for private and public GitHub repositories. No card or cloud connection required. [Eligibility and fair-use terms](/free-code-review/).

[Start free with GitHub](https://proofline.sh/orgs/plan?offer=free_month)

## Related reading

-   ### [Trace a permission denial to the caller and the policy](/learn/permission-denied-request-triage/)
    
    Permission errors The Proofline team November 24, 2026 3 min read
    
-   ### [Check PostgreSQL schema USAGE when a table grant already exists](/learn/postgres-schema-usage-denied/)
    
    Permission errors The Proofline team November 24, 2026 1 min read
