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
strings slice causes goroutine to panic #51
Comments
hi gorm doesn't support []string because database dialect that you are using don't know how to store it to database. So maybe you need to write a Scanner for slice. |
@jinzhu, would you be willing to show an example of how to make something like the above example work? I'm working on creating an API, and it would be much more succinct to have something like:
As opposed to the current way of doing it:
Any help would be appreciated! |
I meet this issue too. |
Yea, I'm running into this issue as well, and I have seen a bunch of old issues about this as well. |
Ok, I've found the interface definition here: https://golang.org/pkg/database/sql/#Scanner. Hopefully this will do the trick. |
hi, just create a simple model that uses []string and it'll crash with something like this https://gist.github.com/AvianFlu/4688697c15b3587623a2
ie:
The text was updated successfully, but these errors were encountered: