Open
Description
this is not a bug report nor a feature request, just a question.
when I try to insert []byte(nil)
as NULL
like this, it was treated as 0 length bytea
.
(you can see full source code at https://play.golang.org/p/6WBCgbtJKYS)
for _, b := range [][]byte{
[]byte("hello"),
[]byte("world"),
nil, // this won't be stored as NULL.
} {
_, err := db.Exec(`INSERT INTO foo1 (data) VALUES($1)`, b)
if err != nil {
return err
}
}
Is this handling of []byte(nil)
intentional?
Metadata
Metadata
Assignees
Labels
No labels