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
I'm encountering an issue where SQLC fails to generate code for a query involving the api_key column in my users table. Here's the context:
api_key
users
SQL Query File (user.sql):
user.sql
-- name: CreateUser :one INSERT INTO users(id, created_at, updated_at, name, api_key) VALUES($1, $2, $3, $4, encode(sha256(random()::text::bytea), 'hex') ) RETURNING *; -- name: GetUserByApiKey :one SELECT * FROM users WHERE api_key = $1;
Issue Encountered:
When running sqlc generate, I get the following error:
sqlc generate
sql/queries/user.sql:9:27: column "api_key" does not exist
What I've Tried:
\d+ users
character varying(64)
The text was updated successfully, but these errors were encountered:
Hey, not sure that I will be able to help you, but can you also share your schema file?
Sorry, something went wrong.
These are my schema files
No branches or pull requests
I'm encountering an issue where SQLC fails to generate code for a query involving the
api_key
column in myusers
table. Here's the context:SQL Query File (
user.sql
):Issue Encountered:
When running
sqlc generate
, I get the following error:What I've Tried:
api_key
column exists in the database using\d+ users
.api_key
is present as acharacter varying(64)
column.The text was updated successfully, but these errors were encountered: