converting argument $1 type: uint64 values with high bit set are not supported
dvilaverde opened this issue · 1 comments
dvilaverde commented
When attempting a query that requires an uint64
, the driver fails with this error:
sql: converting argument $1 type: uint64 values with high bit set are not supported
Example:
conn, err := sql.Open("mysql", "root@127.0.0.1:3306/test")
defer conn.Close()
stmt, err := conn.Prepare("select a, b from tableA where uint64 = ?")
defer stmt.Close()
var val uint64 = math.MaxUint64
result, err := stmt.Query(val)
I don't see a way to use the https://pkg.go.dev/database/sql/driver#NamedValueChecker to allow for uint64
handling, or any custom Value types for that matter.
dvilaverde commented
I've added PR #887 to address this issue.