Open josharian opened 4 months ago
I don't think that you can have a such a field in a struct !
type Table Struct { 🤷 string , ... }
I don't know what framework frontend technology your are using , but json/xml common unMarshalers won't parse your field correctly . I know this won't help.
But if it is a must , I suggest you to create custom go code to adapt the SQLC model structs => your response structs/json/xml/whatever_format .
I don't think that you can have a such a field in a struct !
AS emoji
in the query changes the name to Emoji
.
Version
1.26.0
What happened?
In query.sql:
Generated in query.sql.go:
Observe the missing
1;
at the end. Looks like somebody is counting bytes instead of runes?Yes, this happened in real code. It was pretty confusing to debug.
Appears to be happen with some dbs and not others? Didn't dig much.
Relevant log output
No response
Database schema
No response
SQL queries
No response
Configuration
Playground URL
https://play.sqlc.dev/p/984f440606d6a2084f363f711e283a31b031901ea70d613a250636784d5cad33
What operating system are you using?
Linux, macOS
What database engines are you using?
SQLite
What type of code are you generating?
Go