Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ignore table partitions #3786

Open
ptman opened this issue Jan 14, 2025 · 1 comment
Open

Ignore table partitions #3786

ptman opened this issue Jan 14, 2025 · 1 comment

Comments

@ptman
Copy link

ptman commented Jan 14, 2025

What do you want to change?

Let's suppose we have a time-range partitioned table called events. And then monthly partitions.

  • events
  • events_p20250101
  • events_p20250201

sqlc generates structs for the partitions(type Event struct, type EventP20250101 struct, type EventP20250201 struct, ...), even though they're an implementation detail of the schema. How can one make sqlc ignore them?

What database engines need to be changed?

PostgreSQL

What programming language backends need to be changed?

Go

@ptman ptman added the enhancement New feature or request label Jan 14, 2025
@ptman
Copy link
Author

ptman commented Jan 15, 2025

omit_unused_structs can help, but it affects more than just partitioned tables.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant