Skip to content

Generate builtin postgresql schema #1541

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

Closed
Yamakaky opened this issue Apr 11, 2022 · 1 comment
Closed

Generate builtin postgresql schema #1541

Yamakaky opened this issue Apr 11, 2022 · 1 comment
Labels
📚 postgresql enhancement New feature or request

Comments

@Yamakaky
Copy link

Yamakaky commented Apr 11, 2022

Version

1.12.0

What happened?

For one of my queries, I use the pg_catalog.pg_sequence built-in table, but sqlc says it doesn't exist. My current workaround is to add then delete the following table:

CREATE TABLE if not exists pg_sequence (
  "seqrelid" oid not null,
  "seqmin" bigint not null,
  "seqmax" bigint not null
);

Relevant log output

No response

Database schema

No response

SQL queries

select * from pg_catalog.pg_sequence;

Configuration

No response

Playground URL

https://play.sqlc.dev/p/c12d58abd999f7899f83f72411c87786988a24d13cf6452c53513be7f97e32e2

What operating system are you using?

No response

What database engines are you using?

PostgreSQL

What type of code are you generating?

Go

@Yamakaky Yamakaky added bug Something isn't working triage New issues that hasn't been reviewed labels Apr 11, 2022
@kyleconroy kyleconroy added 📚 postgresql enhancement New feature or request and removed bug Something isn't working triage New issues that hasn't been reviewed labels Jun 5, 2022
@kyleconroy
Copy link
Collaborator

Duplicate of #1171

@kyleconroy kyleconroy marked this as a duplicate of #1171 Sep 22, 2023
@kyleconroy kyleconroy closed this as not planned Won't fix, can't repro, duplicate, stale Sep 22, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
📚 postgresql enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants