sqlc
sqlc copied to clipboard
sqlc ignores parameters following a HAVING clause
Version
1.27.0
What happened?
parameters following HAVING clause are ignored. parameters should be included in generated functions.
Relevant log output
No response
Database schema
CREATE TABLE tab(a TEXT, b TEXT, c TEXT);
SQL queries
-- name: WhereQueryWorksParameterinFunction :many
SELECT a, b, c
FROM tab
WHERE a LIKE (?);
-- name: HavingQueryFailsNoParametersInFunction :many
SELECT a, b, c
FROM tab
GROUP BY b,c
HAVING
a LIKE (?);
Configuration
version: "2"
sql:
- engine: "sqlite"
queries: "query.sql"
schema: "schema.sql"
gen:
go:
package: "db"
out: "db"
Playground URL
No response
What operating system are you using?
Linux
What database engines are you using?
SQLite
What type of code are you generating?
Go