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

query execlastid for pgx/v5 is silently ignored #3338

Open
mishak87 opened this issue Apr 15, 2024 · 0 comments
Open

query execlastid for pgx/v5 is silently ignored #3338

mishak87 opened this issue Apr 15, 2024 · 0 comments
Labels
bug Something isn't working triage New issues that hasn't been reviewed

Comments

@mishak87
Copy link

Version

1.26.0

What happened?

I was expecting an error or warning when I used query type unsupported by a database.
sqlc generate outputs query string and struct but not the function. All other functions are generated.
But playground returns 500 maybe cli is hiding some errors?
1.25.0 playground behaves as 1.26.0 cli (not returning 500 and not generating function)

Relevant log output

No response

Database schema

CREATE TABLE authors (
  id   BIGSERIAL PRIMARY KEY,
  name text      NOT NULL,
  bio  text
);

SQL queries

-- name: InsertAuthor :execlastid
INSERT INTO authors (name, bio) VALUES (@name, @bio);

Configuration

{
  "version": "2",
  "sql": [{
    "schema": "schema.sql",
    "queries": "query.sql",
    "engine": "postgresql",
    "gen": {
      "go": {
      	"sql_package": "pgx/v5",
        "out": "db"
      }
    }
  }]
}

Playground URL

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

What operating system are you using?

Linux

What database engines are you using?

PostgreSQL

What type of code are you generating?

Go

@mishak87 mishak87 added bug Something isn't working triage New issues that hasn't been reviewed labels Apr 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working triage New issues that hasn't been reviewed
Projects
None yet
Development

No branches or pull requests

1 participant