Skip to content

fix: do not paginate columns when listing materialized views - #1115

Open
hsusul wants to merge 1 commit into
supabase:masterfrom
hsusul:fix/matview-list-column-pagination
Open

fix: do not paginate columns when listing materialized views#1115
hsusul wants to merge 1 commit into
supabase:masterfrom
hsusul:fix/matview-list-column-pagination

Conversation

@hsusul

@hsusul hsusul commented Aug 24, 2026

Copy link
Copy Markdown

What kind of change does this PR introduce?

Bug fix.

Why?

GET /materialized-views?include_columns=true&limit=N forwarded limit/offset into COLUMNS_SQL. That paginates every column in the database, not columns of the selected matviews, so a limited list can return empty or truncated columns arrays.

Tables, views, and foreign tables already paginate only the relation CTE.

Fixes #1113.

How?

Stop passing limit/offset into the columns CTE in generateEnrichedMaterializedViewsSql.

Checklist

  • Bug fix
  • Tests added
  • Docs
  • Breaking change

limit/offset apply to the matview CTE only, matching tables/views/foreign tables.
@hsusul
hsusul requested review from a team, avallete and soedirgo as code owners August 24, 2026 16:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Listing materialized views with include_columns and limit drops columns

1 participant