Update doc.go
Fix undefined identifiers in example
This commit is contained in:
committed by
GitHub
parent
655313b801
commit
8efdbc9345
@@ -121,7 +121,7 @@ database/sql. The second is to use a pointer to a pointer.
|
|||||||
|
|
||||||
var foo pgtype.Varchar
|
var foo pgtype.Varchar
|
||||||
var bar *string
|
var bar *string
|
||||||
err := conn.QueryRow("select foo, bar from widgets where id=$1", 42).Scan(&a, &b)
|
err := conn.QueryRow("select foo, bar from widgets where id=$1", 42).Scan(&foo, &bar)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user