We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
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.11.0
Lets say I want to run this request:
create table sometable ( key text not null, value text ); select key, array_agg(value)::text[] from sometable group by key;
sqlc will generate a struct like this:
sqlc
type QueryRow struct { Key text Value []string }
However, some values may be null, which will fail with a scan error. Is there a way to tell sqlc to generate Value []sql.NullString?
null
Value []sql.NullString
No response
create table sometable ( key text not null, value text );
select key, array_agg(value)::text[] from sometable group by key;
The text was updated successfully, but these errors were encountered:
Duplicate of #185
Sorry, something went wrong.
Wow, my bad, I missed that one
No branches or pull requests
Version
1.11.0
What happened?
Lets say I want to run this request:
sqlc
will generate a struct like this:However, some values may be
null
, which will fail with a scan error. Is there a way to tell sqlc to generateValue []sql.NullString
?Relevant log output
No response
Database schema
SQL queries
Configuration
No response
Playground URL
No response
What operating system are you using?
No response
What database engines are you using?
No response
What type of code are you generating?
No response
The text was updated successfully, but these errors were encountered: