We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
1.27.0
Hello,
I have one view with "pg_statio_all_tables" table and I can't generate code for this view. I don't know how I can continue with this view and sqlc.
Thank you
# sqlc generate # package db # ../project/codelists/000010_view_columns.up.sql:1:1: relation "pg_statio_all_tables" does not exist
CREATE VIEW "codelists"."view_columns" AS SELECT c.table_schema, c.table_name, c.column_name AS id, split_part(pgd.description, '@'::text, 1) AS name, split_part(pgd.description, '@'::text, 2)::boolean AS required, split_part(pgd.description, '@'::text, 3)::boolean AS hidden, split_part(pgd.description, '@'::text, 4)::boolean AS editable, split_part(pgd.description, '@'::text, 5) AS codelist FROM pg_statio_all_tables st JOIN pg_description pgd ON pgd.objoid = st.relid RIGHT JOIN information_schema.columns c ON pgd.objsubid = c.ordinal_position::integer AND c.table_schema::name = st.schemaname AND c.table_name::name = st.relname WHERE c.table_schema::name = 'codelists'::name;
-- name: GetColumns :many SELECT id, name, required, hidden, editable, codelist FROM codelists.view_columns WHERE table_name = @table_name AND table_schema = @table_schema;
version: "2" sql: - engine: "postgresql" queries: "db/queries" schema: ["../project/codelists", "../project/stock", "../project/iam", "../project/clients", "../project/contracts"] gen: go: package: "db" sql_package: "pgx/v5" out: "db" emit_json_tags: true overrides: - go_type: import: "github.com/rs/xid" type: "ID" package: "xid" db_type: "public.xid"
No response
Linux, macOS
PostgreSQL
Go
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Version
1.27.0
What happened?
Hello,
I have one view with "pg_statio_all_tables" table and I can't generate code for this view. I don't know how I can continue with this view and sqlc.
Thank you
Relevant log output
Database schema
SQL queries
Configuration
Playground URL
No response
What operating system are you using?
Linux, macOS
What database engines are you using?
PostgreSQL
What type of code are you generating?
Go
The text was updated successfully, but these errors were encountered: